ConstReads a setting back from the four register bytes a channel holds.
The inverse of the builders above, so a caller can read a channel off the bus and see what it is set to rather than decoding the registers by hand.
The four channel registers.
The counts at which the output goes high and low.
Builds a setting with no phase delay: on at count 0, off at off.
The count at which the output goes low, which sets the duty.
The four register bytes.
Builds a setting from explicit on and off counts.
The count at which the output goes high.
The count at which it goes low.
The four register bytes; counts are masked to 12 bits.
The setting that holds a channel continuously low, the power-on state.
The four register bytes. This is not the same as a zero duty, which still glitches high for one count.
Builds the setting that drives a hobby servo to a pulse width.
The high-pulse width in microseconds. Typical travel is about 1000 to 2000 microseconds.
OptionalupdateRateHz: number
The PWM frequency the controller is set to, usually 50.
The four register bytes.
The four register bytes for one PCA9685 channel.
Each call returns a buffer in the channel's own register order, so it can be written in a single bus transaction.