sending data to usb port

2016-02-04 Thread Hiisi
Hi! Imagine I have some device connected to USB port. Is it possible to send some code directly to that port? Here's what I'm trying: # echo "0" > /dev/bus/usb/004/010 -bash: echo: write error: Invalid argument -- Hiisi. Registered Linux User #487982. Be counted at: https://linuxcounter.net/ -- Sp

Re: sending data to usb port

2016-02-04 Thread Matthew Miller
On Thu, Feb 04, 2016 at 06:45:57PM +0300, Hiisi wrote: > Hi! > Imagine I have some device connected to USB port. Is it possible to send > some code directly to that port? > Here's what I'm trying: > # echo "0" > /dev/bus/usb/004/010 > -bash: echo: write error: Invalid argument Sort of, but not lik

Re: sending data to usb port

2016-02-04 Thread Jack Craig
how about you plug in your USB widget & identify the device node (/dev/sdc1, for example). say your src data is in /tmp/junk # dd if=/tmp/junk of=/devsdc1[any other args you might want to shape the write and some error handing ( i think, it was a long time ago...)] man dd{for more optio

Re: sending data to usb port

2016-02-04 Thread Ted Roche
On Thu, Feb 4, 2016 at 10:45 AM, Hiisi wrote: > Imagine I have some device connected to USB port. Is it possible to send > some code directly to that port? Try: http://stackoverflow.com/questions/3526593/sending-raw-data-through-usb-on-linux -- Ted Roche Ted Roche & Associates, LLC http://www

Re: sending data to usb port

2016-02-04 Thread Hiisi
On 4 February 2016 at 22:43, Ted Roche wrote: > > Try: > > > http://stackoverflow.com/questions/3526593/sending-raw-data-through-usb-on-linux > > Try what? Simple '>' doesn't work :( -- Hiisi. Registered Linux User #487982. Be counted at: https://linuxcounter.net/ -- Spandex is a privilege, not

Re: sending data to usb port

2016-02-04 Thread Hiisi
On 4 February 2016 at 21:17, Jack Craig wrote: > how about > > you plug in your USB widget & identify the device node (/dev/sdc1, for > example). > > say your src data is in /tmp/junk > > # dd if=/tmp/junk of=/devsdc1[any other args you might want to shape > the write and some error handing (

Re: sending data to usb port

2016-02-04 Thread Hiisi
On 4 February 2016 at 18:54, Matthew Miller wrote: > > Sort of, but not like that. I'd recommend using PyUSB: > https://walac.github.io/pyusb/ > > Thanks! Any library like that for C++? -- Hiisi. Registered Linux User #487982. Be counted at: https://linuxcounter.net/ -- Spandex is a privilege,

Re: sending data to usb port

2016-02-04 Thread Matthew Miller
On Thu, Feb 04, 2016 at 11:25:21PM +0300, Hiisi wrote: > > Sort of, but not like that. I'd recommend using PyUSB: > > https://walac.github.io/pyusb/ > Thanks! > Any library like that for C++? Yes. Well, C. http://libusb.info/ -- Matthew Miller Fedora Project Leader -- users mailing list users

Re: sending data to usb port

2016-02-05 Thread Hiisi
On 5 February 2016 at 02:48, Matthew Miller wrote: > > Yes. Well, C. http://libusb.info/ > > Thanks a lot! Stupid gmail webinterface doesn't allow me to change topic. Otherwise I would mark the topic as [solved]. -- Hiisi. Registered Linux User #487982. Be counted at: https://linuxcounter.net/ -

Re: sending data to usb port

2016-02-05 Thread Matthew Miller
On Fri, Feb 05, 2016 at 03:06:19PM +0300, Hiisi wrote: > > Yes. Well, C. http://libusb.info/ > Thanks a lot! > Stupid gmail webinterface doesn't allow me to change topic. Otherwise I > would mark the topic as [solved]. Well, it's a mailing list, so you can't really change the whole thread topic. B

Re: sending data to usb port

2016-02-05 Thread Ian Malone
On 5 February 2016 at 13:24, Matthew Miller wrote: > On Fri, Feb 05, 2016 at 03:06:19PM +0300, Hiisi wrote: >> > Yes. Well, C. http://libusb.info/ >> Thanks a lot! >> Stupid gmail webinterface doesn't allow me to change topic. Otherwise I >> would mark the topic as [solved]. > > Well, it's a maili