mirror of
https://github.com/esphome/esphome.git
synced 2024-11-29 02:04:13 +01:00
tm1637 - support 6 character displays (#1803)
This commit is contained in:
parent
96e46db272
commit
514d11d46f
2 changed files with 2 additions and 2 deletions
|
@ -253,7 +253,7 @@ uint8_t TM1637Display::print(uint8_t start_pos, const char* str) {
|
|||
pos--;
|
||||
this->buffer_[pos] |= 0b10000000;
|
||||
} else {
|
||||
if (pos >= 4) {
|
||||
if (pos >= 6) {
|
||||
ESP_LOGE(TAG, "String is too long for the display!");
|
||||
break;
|
||||
}
|
||||
|
|
|
@ -63,7 +63,7 @@ class TM1637Display : public PollingComponent {
|
|||
GPIOPin *clk_pin_;
|
||||
uint8_t intensity_;
|
||||
optional<tm1637_writer_t> writer_{};
|
||||
uint8_t buffer_[4] = {0};
|
||||
uint8_t buffer_[6] = {0};
|
||||
};
|
||||
|
||||
} // namespace tm1637
|
||||
|
|
Loading…
Reference in a new issue