We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 9fd54ee commit d9fb336Copy full SHA for d9fb336
1 file changed
lib/apds9960/examples/light_theremin.py
@@ -58,7 +58,7 @@
58
# Clamp the light reading to the expected range to avoid out-of-bounds errors
59
clamped_light = max(MIN_LIGHT, min(light_level, MAX_LIGHT))
60
61
- # Avoid diving by zero if MAX_LIGHT is not greater than MIN_LIGHT
+ # Avoid dividing by zero if MAX_LIGHT is not greater than MIN_LIGHT
62
range_light = MAX_LIGHT - MIN_LIGHT
63
if range_light <= 0:
64
range_light = 1
0 commit comments