Taiga Develop 2 nedēļas atpakaļ
vecāks
revīzija
6b1ecfc1ee
1 mainītis faili ar 2 papildinājumiem un 2 dzēšanām
  1. 2 2
      sources/hd44780_shift_register.c

+ 2 - 2
sources/hd44780_shift_register.c

@@ -13,8 +13,8 @@ static chlcd_error_t __chlcd_hd44780_shift_register_set_byte(
     self->last_state = content; 
     
     for (uint8_t count = 0; count < 8; ++count) {
-        bool current = (content & 0b10000000) != 0x00;
-        content = content << 1;
+        bool current = (content & 0b1) != 0x00;
+        content = content >> 1;
 
         __R(chlcd_pin_write(self->register_data, current));
         __R(chlcd_sleep_us(200));