#include <LiquidCrystal_I2C.h>
LiquidCrystal_I2C lcd(0x27, 16, 2);
uint8_t user_card[8]{
0b11111,
0b11111,
0b10101,
0b11111,
0b10101,
0b11111,
0b11111
};
void createChar(uint8_t location, uint8_t mychar[]){
lcd.command(LCD_SETCGRAMADDR | location << 3);
for(size_t i = 0; i < 8; i++){
lcd.write(user_card[i]);
}
}
void setup(){
lcd.init();
lcd.backlight();
createChar(1, user_card);
lcd.setCursor(0,0);
lcd.print("\1\1\1\1\1\1\1\1\1\1\1\1\1\1\1\1\1\1");
}
void loop(){
lcd.scrollDisplayLeft();
delay(50);
}