Skip to content

Commit e84f36e

Browse files
committed
Fixes an issue from an update of the ht16k33
1 parent 4afec77 commit e84f36e

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

adafruit_featherwing/led_segments.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,10 @@ def print(self, value):
4949
:type value: str or int or float
5050
5151
"""
52+
# Attempt to round off so we can still display the value
53+
if isinstance(value, float) and len(str(value)) > 5:
54+
value = round(value)
55+
5256
self._segments.print(value)
5357
self._segments.show()
5458

0 commit comments

Comments
 (0)