Home » Tutorials » Topical Tutorials » LLEMU (Legacy LCD Emulator)

Initialization

Initialization of the LLEMU is very simple, it's just a call to its initialization function at whatever point in the program you would like the LLEMU to start displaying (this will most likely be in initialize()).

Initialization is done as such:

Writing to the LLEMU

Writing to the LLEMU is nearly identical to writing to the LCD with PROS 2. Most writing should be done with the print function, which is analogous to printf.

Using the Buttons

Using the buttons can be done in a similar method to PROS 2 with the pros::lcd::read_buttons function. See the above example for printing the button readings.

While this is sufficient for most applications, some tasks are easier to perform using the pros::lcd::register_btn#_cb functions (where # is replaced with 0, 1, or 2 for the left, center, and right buttons respectively). With these function you can assign a function to be called each time that the button is pressed.