From nobody Wed Dec 21 10:29:02 2022 X-Original-To: freebsd-usb@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4NcV6j5Ql5z1GCG7 for ; Wed, 21 Dec 2022 10:29:17 +0000 (UTC) (envelope-from tomek@cedro.info) Received: from mail-qt1-x830.google.com (mail-qt1-x830.google.com [IPv6:2607:f8b0:4864:20::830]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1D4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4NcV6j3J9vz3jpF for ; Wed, 21 Dec 2022 10:29:17 +0000 (UTC) (envelope-from tomek@cedro.info) Authentication-Results: mx1.freebsd.org; none Received: by mail-qt1-x830.google.com with SMTP id a16so13264225qtw.10 for ; Wed, 21 Dec 2022 02:29:17 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cedro.info; s=google; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=Ogx74U5+noGvlqHzKkc9XV/Aljp7CTBkSSBKWB9qRqE=; b=al/tAk722cx2xEIL781EBJ0WIkKXsnRDqgl75xqmK/VU86pOJSRs+Ik2q6pV4PMUH8 xhH/8MpnQ17T6Nc0yZGi7eSOsci4siw8VLedQLkRzC/QvPLQxVl7VEd51oWXKkzjqbpS 6IKq24K2vacue+KXgIs3w1ghT4+lSGcvIQQIclHYjh7OaqFjlX0oyyxRgzLtDw9iko+T VqriOoeYEH6v0q7DBhSBQK77NCDAa+Z1p2so+F+0myjCzaZLFCkE+iECksrjTARhlEjS Q9xeIIAkZE4zZCkXPvn990zsziQbaTIms4syEiKQFYv3Wg0+iCY2enJrv1e8eO+//0ZL mXbw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=Ogx74U5+noGvlqHzKkc9XV/Aljp7CTBkSSBKWB9qRqE=; b=tI0EUVtuj7t5Tni/0GUBoPVYpIKaGEPaszN9nQWMgclM9EhFOqmvwmSBiVbSrkPwwb eWrTwCdA9nUUuAbcZI5DcglobeeRTZ/lyHqBb6EC+fVl3Ep2u0Tvmue0bv5Z1tB5ntPk BKhpDA1pz/rJ50oubaYKCsFkcn5JtNcDC+PhcYAnf2YHwmgZ2ix7b+UpEsF/Ji/rx4YT KEVO58yF6zdRZroi0VaM1Hva0PrIp+BFKaFCNVioDG69qeDU28e7zhhYmuIbS4g04U9u drvJGrns4OJq1olS8FgDu28+rANcDH4SMYbDpya1z9FYsyEFImNIpx4n3vQ48lkUwxht O6HQ== X-Gm-Message-State: AFqh2krqfRthzT6oz6OHkdcZmdFo5I89u8l7vproNfQlsu4am/RYNBPv Rwpl6YGfeiTqaTf+zMgNEsnm3qigv1lfSP2f X-Google-Smtp-Source: AMrXdXtVYVelnPsUfu3Etn3jR/BGGx8Z69xPAFiHjM6bB+JcDQGMzjCjNkcvUTozyJldJPXdIBlBsw== X-Received: by 2002:ac8:4a07:0:b0:3a5:8084:9f60 with SMTP id x7-20020ac84a07000000b003a580849f60mr1272446qtq.64.1671618556777; Wed, 21 Dec 2022 02:29:16 -0800 (PST) Received: from mail-yb1-f180.google.com (mail-yb1-f180.google.com. [209.85.219.180]) by smtp.gmail.com with ESMTPSA id h9-20020ac81389000000b003a530a32f67sm8862206qtj.65.2022.12.21.02.29.16 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 21 Dec 2022 02:29:16 -0800 (PST) Received: by mail-yb1-f180.google.com with SMTP id 192so15986473ybt.6 for ; Wed, 21 Dec 2022 02:29:16 -0800 (PST) X-Received: by 2002:a25:ab0d:0:b0:6f8:4956:d480 with SMTP id u13-20020a25ab0d000000b006f84956d480mr113244ybi.528.1671618555682; Wed, 21 Dec 2022 02:29:15 -0800 (PST) List-Id: FreeBSD List-Archive: https://lists.freebsd.org/archives/freebsd-usb List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-usb@freebsd.org X-BeenThere: freebsd-usb@freebsd.org MIME-Version: 1.0 References: <20221221084423.71de3559@zeta.dino.sk> In-Reply-To: <20221221084423.71de3559@zeta.dino.sk> From: Tomek CEDRO Date: Wed, 21 Dec 2022 11:29:02 +0100 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: USB logic analyzer problem To: Milan Obuch Cc: freebsd-usb@freebsd.org, Hans HPS Petter Selasky Content-Type: text/plain; charset="UTF-8" X-Rspamd-Queue-Id: 4NcV6j3J9vz3jpF X-Spamd-Bar: ---- X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US] X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-ThisMailContainsUnwantedMimeParts: N On Wed, Dec 21, 2022 at 8:44 AM Milan Obuch wrote: > recently I've got two simple USB logic analyzers (one with analog > channel as well), and I am trying to get them working under FreeBSD. > They are > > ugen0.x: at usbus0 > ugen0.y: at usbus0 > > as seen on plugging in USB port (x, y varies on attempts). These should > be handled by sigrok and pulseview (science/sigrok* and > science/pulseview ports). While building and installing ports was > relatively easy, I did not managed them to work correctly. 1. Do you perform firmware update before using the device? If so device may reboot and change descriptors / reenumerate after firmware update, please verify the parameters before and after the update. 2. # usbconfig list; note your device ugenX.Y; # usbconfig -d X.Y dump_all_desc; see device configurations interfaces and serial number. Maybe you will be able to provide serial number to the software as the analyzer id? > At first, I thought problem is access rights, as all devices are > created with mode crw-------, uid root. I did not succeed to change > this, trying devd and/or devfs, even manually chmod. As a simple test, > I started pulseview as root, still, no success - I can see my devices > listed and selectable for data acquisition, but trying to get data > yields 1. # vim /etc/devfs.rules: [localrules=10] add path 'ugen*' mode 0660 group operator add path 'usb/*' mode 0660 group operator add path 'usb' mode 0770 group operator 2. # vim /etc/rc.conf: devfs_system_ruleset="localrules" 3. # pw groupmod operator -m 4. # service devfs restart 5. logout and login your local user to see if access right are correct now. -- CeDeROM, SQ7MHZ, http://www.tomek.cedro.info