diff --git a/adafruit_ht16k33/segments.py b/adafruit_ht16k33/segments.py index 0d2fc45..6f9a976 100755 --- a/adafruit_ht16k33/segments.py +++ b/adafruit_ht16k33/segments.py @@ -250,7 +250,8 @@ def _put(self, char, index=0): elif char in '0123456789': character = ord(char) - 48 elif char == ' ': - character = 0x00 + self._set_buffer(index, 0x00) + return elif char == ':': self._set_buffer(4, 0x02) return diff --git a/docs/examples.rst b/docs/examples.rst index ab9c3a8..6744dae 100644 --- a/docs/examples.rst +++ b/docs/examples.rst @@ -3,10 +3,14 @@ Simple test Ensure your device works with this simple test. -.. literalinclude:: ../examples/matrix.py - :caption: examples/matrix.py +.. literalinclude:: ../examples/ht16k33_matrix_simpletest.py + :caption: examples/ht16k33_matrix_simpletest.py :linenos: -.. literalinclude:: ../examples/segments.py - :caption: examples/segments.py +.. literalinclude:: ../examples/ht16k33_segments_simpletest.py + :caption: examples/ht16k33_segments_simpletest.py + :linenos: + +.. literalinclude:: ../examples/ht16k33_bicolor24_simpletest.py + :caption: examples/ht16k33_bicolor24_simpletest.py :linenos: diff --git a/examples/bicolor24.py b/examples/ht16k33_bicolor24_simpletest.py similarity index 100% rename from examples/bicolor24.py rename to examples/ht16k33_bicolor24_simpletest.py diff --git a/examples/matrix.py b/examples/ht16k33_matrix_simpletest.py similarity index 100% rename from examples/matrix.py rename to examples/ht16k33_matrix_simpletest.py diff --git a/examples/segments.py b/examples/ht16k33_segments_simpletest.py similarity index 100% rename from examples/segments.py rename to examples/ht16k33_segments_simpletest.py