Returns the specified PWM output pin’s current duty cycle
Device
Float — the duty cycle as a value between 0.0 and 1.0
This method provides the actual pulse-width modulation duty cycle as a value between 0.0 and 1.0. This is the case even if the PWM is running in ‘zombie’ mode, ie. it continues to operate across Squirrel reloads, firmware upgrades and device restarts.