mirror of
https://github.com/IcedRooibos/py32f0-template.git
synced 2025-10-29 08:52:04 -07:00
fix: misorder on some module
This commit is contained in:
parent
983ff1cbc6
commit
103d647e7b
@ -92,9 +92,9 @@ int main(void)
|
|||||||
// Shift display test
|
// Shift display test
|
||||||
LCD_SendCommand(LCD1602_I2C_ADDR, LCD1602_CMD_CLEAR_DISPLAY);
|
LCD_SendCommand(LCD1602_I2C_ADDR, LCD1602_CMD_CLEAR_DISPLAY);
|
||||||
LL_mDelay(500);
|
LL_mDelay(500);
|
||||||
LCD_SendCommand(LCD1602_I2C_ADDR, LCD1602_DDRAM_ROW0|8);
|
LCD_SendCommand(LCD1602_I2C_ADDR, LCD1602_DDRAM_ROW0|9);
|
||||||
LCD_SendString(LCD1602_I2C_ADDR, "Shift");
|
LCD_SendString(LCD1602_I2C_ADDR, "Shift");
|
||||||
LCD_SendCommand(LCD1602_I2C_ADDR, LCD1602_DDRAM_ROW1|7);
|
LCD_SendCommand(LCD1602_I2C_ADDR, LCD1602_DDRAM_ROW1|8);
|
||||||
LCD_SendString(LCD1602_I2C_ADDR, "<<<->>>");
|
LCD_SendString(LCD1602_I2C_ADDR, "<<<->>>");
|
||||||
LL_mDelay(500);
|
LL_mDelay(500);
|
||||||
for (i = 0; i < 8; i++)
|
for (i = 0; i < 8; i++)
|
||||||
|
|||||||
@ -73,6 +73,8 @@ void LCD_Init(uint8_t lcd_addr)
|
|||||||
LCD_SendCommand(lcd_addr, LCD1602_CMD_HOME);
|
LCD_SendCommand(lcd_addr, LCD1602_CMD_HOME);
|
||||||
// display on, right shift, underline off, blink off
|
// display on, right shift, underline off, blink off
|
||||||
LCD_SendCommand(lcd_addr, LCD1602_CMD_MODE_ON_CURSOR_BLNK);
|
LCD_SendCommand(lcd_addr, LCD1602_CMD_MODE_ON_CURSOR_BLNK);
|
||||||
|
// move direction right
|
||||||
|
LCD_SendCommand(lcd_addr, LCD1602_CMD_DIRECTION_RIGHT);
|
||||||
// clear display (optional here)
|
// clear display (optional here)
|
||||||
LCD_SendCommand(lcd_addr, LCD1602_CMD_CLEAR_DISPLAY);
|
LCD_SendCommand(lcd_addr, LCD1602_CMD_CLEAR_DISPLAY);
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user