Hi Florian!

Interpreters are slow, and sysfs access for GPIO input is also slow.

You can speed up your code by using libpruio 
<http://beagleboard.org/project/libpruio/> for the GPIO access, but you'll 
still have to deal with the real-time issue. The main CPU may get loaded by 
interrupt execution, which results in erroneous results.

But the ARM CPU has hardware support for frequency measurements. All of the 
three PWM subsystems contain a CAP module for that purpose (and a QEP 
module, which can measure the frequency on a single pin). Also the TIMER 
subsystems can measure the frequency (but configuration is more complex). 
This works up to a frequency of 50 MHz.

Check out the example pwm_cap 
<http://users.freebasic-portal.de/tjf/Projekte/libpruio/doc/html/_cha_examples.html#SubSecExaPwmCap>
 
to see how this works.

BR

-- 
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 [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to