Share 'Reading Servo PWM Signals on the Arduino & Wiring'
We are interested in reading the number of microseconds that a digital pin is set to HIGH. Wiring natively lacks a micros() function to tell us this so we need to write an accurate one.
This is the actual implementation of millis() in wiring.c for the Arduino.
unsigned long millis()
// timer 0 increments every 64 cycles, and overflows when it reaches
// 256. we would calculat…
You can share this discussion in two ways…
Share this link:
Send it with your computer's email program: Email this