28 #include <mraa/gpio.h>
35 #define MAX_PERIOD 7968
36 #define TRIGGER_PULSE 10
58 HCSR04 (uint8_t triggerPin, uint8_t echoPin,
void (*fptr)(
void *));
88 mraa_pwm_context m_pwmTriggerCtx;
89 mraa_gpio_context m_echoPinCtx;
92 long m_RisingTimeStamp;
93 long m_FallingTimeStamp;
94 uint8_t m_InterruptCounter;
HCSR04(uint8_t triggerPin, uint8_t echoPin, void(*fptr)(void *))
Definition: hcsr04.cxx:34
~HCSR04()
Definition: hcsr04.cxx:56
uint8_t m_doWork
Definition: hcsr04.h:77
void ackEdgeDetected()
Definition: hcsr04.cxx:83
std::string name()
Definition: hcsr04.h:82
int getDistance()
Definition: hcsr04.cxx:67
C++ API for HCSR04 (ultrasonic ranging module) component.
Definition: hcsr04.h:48