[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: usb snooper



On Wednesday 27 November 2019 08:41:38 tomas@tuxteam.de wrote:

> On Wed, Nov 27, 2019 at 08:22:25AM -0500, Gene Heskett wrote:
>
> [...]
>
> > Doesn't look as if it will work with this preempt-rt kernel :(
> >
> > pi@rpi4:~/linuxcnc/configs/sheldon-lathe $ sudo /usr/sbin/tcpdump 
> > -i 7 tcpdump: Can't open USB bus file /sys/kernel/debug/usbmon/1t:
> > No such file or directory
>
> Throwing the error message into a search engine yields some promising
> links:
>
>  
> https://stackoverflow.com/questions/32740413/no-usb-bus-file-even-afte
>r-enabling-usbmon-in-android-kernel
> https://unix.stackexchange.com/questions/546719/no-such-file-or-direct
>ory-sys-kernel-debug-usb-usbmon
>
> So it seems you need the usbmon module loaded (is it?)
no, is now. And watching the 3 choices for more than enough time to see 
several of these "noise events" if that what it is, gets this:
 pi@rpi4:~/linuxcnc/configs/sheldon-lathe $ sudo /usr/sbin/tcpdump  -i 8
tcpdump: verbose output suppressed, use -v or -vv for full protocol 
decode
listening on usbmon1, link-type USB_LINUX_MMAPPED (USB with padded Linux 
header), capture size 262144 bytes
12:07:06.611219 CONTROL SUBMIT to 1:17:0
12:07:06.613656 CONTROL COMPLETE from 1:17:0
12:07:06.613861 CONTROL SUBMIT to 1:16:0
12:07:06.615532 CONTROL COMPLETE from 1:16:0
12:07:06.615886 CONTROL SUBMIT to 1:3:0
12:07:06.616363 CONTROL COMPLETE from 1:3:0
12:07:06.616506 CONTROL SUBMIT to 1:2:0
12:07:06.616766 CONTROL COMPLETE from 1:2:0
12:07:06.616882 CONTROL SUBMIT to 1:1:0
12:07:06.616924 CONTROL COMPLETE from 1:1:0
^C
10 packets captured
10 packets received by filter
0 packets dropped by kernel
pi@rpi4:~/linuxcnc/configs/sheldon-lathe $ sudo /usr/sbin/tcpdump  -i 
9 -v
tcpdump: listening on usbmon2, link-type USB_LINUX_MMAPPED (USB with 
padded Linux header), capture size 262144 bytes
12:09:50.820947 CONTROL SUBMIT to 2:3:0
12:09:50.821114 CONTROL COMPLETE from 2:3:0
12:09:50.821365 CONTROL SUBMIT to 2:2:0
12:09:50.821512 CONTROL COMPLETE from 2:2:0
12:09:50.821699 CONTROL SUBMIT to 2:1:0
12:09:50.821737 CONTROL COMPLETE from 2:1:0
^C
6 packets captured
6 packets received by filter
0 packets dropped by kernel
pi@rpi4:~/linuxcnc/configs/sheldon-lathe $ sudo /usr/sbin/tcpdump  -i 
10 -vv
tcpdump: listening on usbmon3, link-type USB_LINUX_MMAPPED (USB with 
padded Linux header), capture size 262144 bytes
12:10:46.640549 CONTROL SUBMIT to 3:1:0
12:10:46.640597 CONTROL COMPLETE from 3:1:0
^C
2 packets captured
2 packets received by filter
0 packets dropped by kernel
pi@rpi4:~/linuxcnc/configs/sheldon-lathe $
> and 
> the debugfs pseudo file system mounted (again, is it?).

No. Each of the above captures was presented within 2 secs of the 
invocation, followed by silence, so I get the impression I'm barking up 
the wrong tree and should look elsewhere for the cause of the motion 
stutter.  This app, linuxcnc, has an o-scope like facility with very  
limited sampling to aid in signal tracing, limited because it only runs 
once per thread invocation, and since I am useing Mesa fpga based 
interface cards which take over the need for 20 microsecond controls, 
the remaining thread invoc's are at 1ms or even 5ms intervals for the 
jog dials I've installed to replace the manual cranks it had 70 years 
ago. Those signals I can see, but the manual signals, like from the 
arrow keys on the keyboard, are all hidden, not available to be seen by 
this "scope", going thru a bunch of steering stuff before getting to the 
actual joint circuitry as a move a motor command.

The app itself has an 8 digit debug control, but I haven't found a 
definition of which of those 32 bits enables what debugging traces.  We 
have several Docs, the main one being over 800 pages, so I have some 
concentrated reading to do.

Thanks muchly for the help Reco, its appreciated, a lot. I think it 
pretty much rules out local rfi as a source of this problem so I must 
figure out how to look elsewhere.
>
> HTH
> -- tomás


Cheers, Gene Heskett
-- 
"There are four boxes to be used in defense of liberty:
 soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author)
If we desire respect for the law, we must first make the law respectable.
 - Louis D. Brandeis
Genes Web page <http://geneslinuxbox.net:6309/gene>


Reply to: