Closed
Description
Setting the LED current to 0, with sensor.led_current=0 gives the unexpected result of actually setting the current to the maximum value possible, due to wrap around in the calculation.
Suggest modifying line 620 of file to:
new_current = max(0, min(127,int((led_curent - 4) / 1)))
to coerce current being set to valid range.
regards
dave Langstaff
Metadata
Metadata
Assignees
Labels
No labels