Hi Alan!

There is only 1 of this timer, so expect trouble if you try to use it on
both PRU's at the same time..
That said, the following should do what you want (from Mark Yoder's PRU
Cookbook).   One count == 5ns, so you can do some pretty precise timing.

#include <pru_iep.h>

# define TEN_US_DELAY  2001
 CT_IEP.TMR_CNT = 0x0;     // set the timer to 0
 CT_IEP.TMR_GLB_CFG = 0x11;  / set the timer running and also its
multiplier for a 5ns  per tick.


  while ( CT_IEP.TMR_CNT < TEN_US_DELAY);

Bill Bitner

-- 
For more options, visit http://beagleboard.org/discuss
--- 
You received this message because you are subscribed to the Google Groups 
"BeagleBoard" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to beagleboard+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/beagleboard/CAOYP4diYApCjY7O2K-UWhnuHXfhyFxqkwZ9rtD-YzVBg5qzTZA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to