44 uint16_t dirty_shaddow =
dirty_;
49 if (dirty_shaddow & (0x1 << i))
void wait()
Wait on (decrement) a semaphore.
static constexpr size_t NUM_CHANNELS
maximum number of PWM channels supported by the PCA9685
OSSem sem_
Wakeup for the thread processing.
void write_pwm_duty(unsigned channel, uint16_t counts)
Set the pwm duty cycle.
std::array< uint16_t, NUM_CHANNELS > duty_
local cache of the duty cycles
uint16_t dirty_
set if the duty_ value is updated (bit mask)
void * entry() override
User entry point for the created thread.