Hey all,
I’ve seen two different methods for setting up USB permissions
correctly, and I can’t seem to get either to work. The first way is
udev, the other method is hotplug.
So I tried udev first, and created /etc/udev/rules.d/60-usrp.rules:
USRP without loaded firmware (FX2)
BUS==“usb”, SYSFS{idVendor}==“fffe”, SYSFS{idProduct}==“0002”,
SYSFS{bcdDevice}==“0002”, GROUP=“usrp”, RUN+="/usr/local/bin/usrper
load_standard_bits"
BUS==“usb”, SYSFS{idVendor}==“fffe”, SYSFS{idProduct}==“0002”,
SYSFS{bcdDevice}==“0004”, GROUP=“usrp”, RUN+="/usr/local/bin/usrper
load_standard_bits"
USRP with loaded firmware
BUS==“usb”, SYSFS{idVendor}==“fffe”, SYSFS{idProduct}==“0002”,
SYSFS{bcdDevice}==“0102”, GROUP=“usrp”
BUS==“usb”, SYSFS{idVendor}==“fffe”, SYSFS{idProduct}==“0002”,
SYSFS{bcdDevice}==“0104”, GROUP=“usrp”
So then I reboot, plugin my device, and it seems to set permissions
correctly:
gnychis@cyprus ~/ $ ls -l /dev | grep usrp
crw-rw---- 1 root usrp 442, 5 Feb 12 11:47 usbdev1.6_ep00
So now I try to run an example:
./usrp_wfm_rcv.py
usrp_open_interface:usb_claim_interface: failed interface 0
could not claim interface 0: Operation not permitted
open_nth_cmd_interface: open_cmd_interface failed
I am in the group, and I have logged out and back in since (completely
rebooted for udev…):
usrp:x:1004:gnychis
So the other method was with hotplug, and i made /etc/hotplug/usb/usrp:
#!/bin/sh
chown root:usb “$DEVICE”
chmod ug+rw “$DEVICE”
and usrp.usermap:
usrp 0x0003 0xfffe 0x0002 0 0 0 0 0 0 0
0
I am in fact using the same vendor and product id:
cyprus SDR # lsusb
Bus 001 Device 006: ID fffe:0002
So I rebooted, and i was in the “usb” group, but again… still get the
same error.
Any ideas?
Thanks!
George