I gather pulls are 10ms apart. Some say they clocked it at 8 on a windows box, and some say 2 on a linux box. What I want to do is see how long my code takes and determine if I'm skipping pulls.
I would like to do one of the following.
a)
pull once ever 10ms ( lets say it take 10 ms )
do code ( how long did this take? )
pull
B)
pull once ever 10ms ( lets say it take 10 ms )
do code
pull ( was data ready? if not run debug code )
I need to ensure my code has completed before a pull. I'm guessing this is the only way to check that. Anyone have some advice on how to do this. I use avr studio maybe there is a built in simulator to clock this?
clocking my usb pulls
Re: clocking my usb pulls
Hi ulao,
My typical solution is to use an normally unused port pin that will be set on start of code and reset after completion. With an oscilloscope you can watch this port and e.g. the usb ports.
-> http://forums.obdev.at/viewtopic.php?f=8&t=1352&start=15#p9040
Ciao, Martin
My typical solution is to use an normally unused port pin that will be set on start of code and reset after completion. With an oscilloscope you can watch this port and e.g. the usb ports.
-> http://forums.obdev.at/viewtopic.php?f=8&t=1352&start=15#p9040
Ciao, Martin
Re: clocking my usb pulls
I was looking for a software solution using a watchdog or something.