STM32 LCD Interface for Multiple Display Proteus Simulation

by Marwen Maghrebi

In this article, we explore interfacing STM32 LCD Display of various sizes, like 16×2 and 20×4, using Proteus simulation

STM32 LCD Display demonstrating interfacing and data visualization

Things used in this project

Software apps and online services:

1- STMicroelectronics STM32CubeMX

2- STMicroelectronics STM32CubeIDE

3- Proteus 8

Interfacing Multiple Displays with STM32 Microcontroller in 4-Bit Mode: A Guide to LCD Integration and Operation:

In this project, we will connect multiple STM32 LCD Displays to the STM32 microcontroller using the 4-bit mode, which requires six GPIO pins. The STM32 operates at 3.3V logic levels, while the LCD Displays operate at 5V. However, this is not a problem because the displays can still recognize the 3.3V output from the STM32. The only 5V line required is the VDD line for the displays, which can be powered using the 5V pin on the STM32 board. We will simulate this setup using Proteus software. Following this article, we will take the 16×2 LCD Display as an example to explain how these displays work.

Liquid crystal displays (LCD Displays) are commonly used to display data in devices such as calculators, microwave ovens, and many other electronic devices. The 16×2 LCD Display features a 16-pin header interface and assumes it has the standard Hitachi LCD driver, HD44780 controller. We’ll see how it works internally and how to interface it with the STM32.

LCD Module Pinout:

This is the pinout for a typical 16×2 LCD Display unit.

Pins’ Functions Description:

STM32CubeMX Configuration:

  • Open CubeMX & Create New Project Choose The Target MCU STM32F103C6 & Double-Click Its Name
  • Go To The Clock Configuration & Set The System Clock To 8MHz
  • Configure The GPIO Pins [PB3..PB9] as Output Pins
  • Generate The Initialization Code & Open The Project In CubeIDE
  • Create header and source file for liquid crystal

STM32CubeIDE Configuration :

  • Write The Application Layer Code
  • LiquidCrystal.h & LiquidCrystal.c
  •  main.c

Proteus Configuration :

  • Open Proteus & Create New Project and click next

  • Click on Pick Device
  • Search for STM32F103C6 & [LCD 16*2… LCD 20*4]
  • Click on Terminal Mode then choose (DEFAULT & POWER &GROUND)
  • finally make the circuit below and start the simulation

That’s all!

If you have any questions or suggestions don’t hesitate to leave a comment below

You Might Also Like

Leave a Comment


Are you sure want to unlock this post?
Unlock left : 0
Are you sure want to cancel subscription?
-
00:00
00:00
Update Required Flash plugin
-
00:00
00:00