We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 92d73ac commit 0aea7b8Copy full SHA for 0aea7b8
adafruit_ht16k33/ht16k33.py
@@ -90,7 +90,7 @@ def brightness(self, brightness):
90
raise ValueError('Brightness must be a decimal number in the range: 0.0-1.0')
91
92
self._brightness = brightness
93
- xbright = int(15 * brightness)
+ xbright = round(15 * brightness)
94
xbright = xbright & 0x0F
95
self._write_cmd(_HT16K33_CMD_BRIGHTNESS | xbright)
96
0 commit comments