Utilize the PropWare::Printer class to print formatted text to an LCD
cmake_minimum_required(VERSION 3.12)
 
project(HD44780_Demo)
 
create_simple_executable(${PROJECT_NAME} HD44780_Demo.cpp)
 
 
 
static const Port::Mask RS = Port::Mask::P16;
static const Port::Mask RW = Port::Mask::P17;
static const Port::Mask EN = Port::Mask::P18;
 
static const Pin::Mask           FIRST_DATA_PIN = Pin::Mask::P19;
static const HD44780::BusWidth   
BITMODE        = HD44780::BusWidth::WIDTH8;
 
static const HD44780::Dimensions DIMENSIONS     = HD44780::Dimensions::DIM_16x2;
 
    
    HD44780 lcd(FIRST_DATA_PIN, RS, RW, EN, 
BITMODE, DIMENSIONS);
    lcd.start();
 
    
    Printer lcdPrinter(lcd);
 
    
    lcdPrinter.printf("%u %s%d 0x%07X", 123456789, "Hello!", -12345, 0xabcdef);
 
    return 0;
}