On Tue, Nov 17, 2009 at 06:56:30PM -0500, John Porubek wrote:
> A quick update. I upgraded to Ubuntu 9.10 which includes kernel
> version 2.6.31 and now the eZ430-RF2500 emulator does indeed show up
> as /dev/ttyACMxx, as you described in your documentation. Further,
> XON/XOFF works properly also.
> 
> Thus, I find myself doing more of my development work under Linux.
> >From time to time what I'm working on hangs the processor. Removing
> the emulator from the USB port is inconvenient, and, worse, it doesn't
> always reliably get me back to the "fresh from reset" state. I had
> thought about installing the IAR Kickstart under Wine, but that seemed
> like overkill just to reset the processor and was certainly less than
> elegant. Then you announced your MSPDebug tool, and the timing and
> suitability to to my needs couldn't have been better! This is a
> long-winded way of saying, once again, thank you for making it
> available.
> 
> I compiled your source code with no real problems. BTW, your coding
> style and commenting allowed me to to easily follow your code and
> figure out what it was doing. It is proving to be an invaluable tool.
> And now that it supports the eZ430-F2013 and FET430UIF devices also,
> it's even better.

Glad to have helped :).

> I have only one real problem. I have to run the program by typing
> "sudo ./mspdebug". I tried your suggestion for remounting usbfs,
> putting sudo in front of the umount and mount lines, and substituting
> my group id for "usb-gid". Here's the error message I get when I run
> mspdebug without sudo:
> 
> Trying to open interface 1 on 002
> usbtr_open_interface: warning: can't detach kernel driver: Operation
> not permitted
> usbtr_open_interface: can't claim interface: Operation not permitted
> usbtr_open: no devices could be found
> 
> In your docs you state: "Replace usb-gid with the GID of a group that
> should have permission to use the bus." There's the crux - how do I
> determine which group has permission to use the bus? I fear I'm
> exposing my ignorance here.
> 
> Here's what I get when I run "id username" (username substituted) :
> 
> uid=1000(username) gid=1000(username)
> groups=1000(username),4(adm),20(dialout),24(cdrom),46(plugdev),104(fuse),106(lpadmin),121(admin),122(sambashare)
> 
> Anyways, running mspdebug with sudo certainly isn't a huge
> inconvenience. It just doesn't feel quite right and I'd like to learn
> something along the way. Any light you could shed would be greatly
> appreciated.

Probably easiest just to use GID 1000, which you're already in. Try
this (as root):

    umount /proc/bus/usb
    mount -t usbfs none /proc/bus/usb -o devgid=1000,devmode=0664

If you want to tidy things up later, you might like to make a "usb"
group, add yourself to it and have usbfs mounted with the GID of
the "usb" group.

- Daniel

Reply via email to