User Manual
• lastHighPulse : The width of the last detected high pulse in system ticks (units of 0.4 µs). A high pulse
is one that starts with a channel transition from low to high and ends with a channel transition from high to
low.
• lastLowPulse : The width of the last detected low pulse in system ticks (units of 0.4 µs). A low pulse
is one that starts with a channel transition from high to low and ends with a channel transition from low to
high.
• newPulse : The bits of this byte are set whenever a new pulse occurs, which lets you tell when new
data has arrived. The LOW_PULSE bit is set when a low pulse finishes, and the HIGH_PULSE bit is set
when a high pulse finishes. The functions in this section clear the newPulse flags after returning them. Once
set, the flags stay set until they are read. Masking newPulse with the keyword ANY_PULSE with the code
(newPulse&ANY_PULSE) will be non-zero if either new-pulse bit flag is set.
Pololu AVR Library Command Reference © 2001–2015 Pololu Corporation
8. Orangutan Pulse/PWM Inputs Page 31 of 65