Introduction
For our last experiment in this batch, we're driving a proper little text screen, a 16x2 character LCD, the same kind of display you've probably seen on old microwaves or lab equipment. This particular display has a small I2C backpack module clipped onto the back of it, which means we only need four wires total instead of the ten or more a bare LCD would otherwise need. By the end of this one you'll understand both how these displays fundamentally work, and how an I2C expander chip can quietly simplify wiring for something that's normally a lot more pins than you'd like.
2. Scope
We'll get familiar with the HD44780 controller's 4-bit communication mode, see how the I2C backpack translates simple I2C bytes into that same 4-bit interface behind the scenes, build the driver functions ourselves, from initialization through to printing actual characters, and finally print a message to the screen. You're still building the whole driver logic yourself here, just talking to it over I2C rather than wiggling six separate GPIO pins directly.
3. Prerequisite
3.1 Hardware
-
STM32 Nucleo-F070RB development board
-
A 16x2 character LCD display (HD44780-compatible) with an I2C backpack module fitted
-
Breadboard and jumper wires
-
Micro-USB cable
3.2 Software
-
STM32CubeMX (standalone)
-
STM32CubeIDE
-
ST-LINK USB driver
Community Q&A
0 questionsAsk questions and get answers from our community and staff moderators.
No questions yet — be the first to start the conversation!
Ask a Question
Please log in to ask a question or post a reply.
Login to Participate