
.
.
Text on I2C-LCD1602 Display written over Web-Page
Sometimes it might be useful to write a text which should be displayed on a LCD display without any cabling, that is possible to do over your own Wi-Fi network and a NodeMCU ESP8266 module. And the project uses ONLY 4 wires as the LCD1602 gets addressed over the I2C bus. Let us remember WHAT the I2C bus is in our previous tutorial:
Check out the wiring below please, ONLY 4 wires plus 2 for the power supply connections:
.
.
Let us have a look on the video below who shows how it works:
.
.
SO, knowing now how it works, let us have a look on the Sketch (Code). I changed a bit the code, as I am using an I2C LCD1602 and I added as well some more text displayed on the LCD1602 display. Check below, please, the original code. I will explain WHAT could (should) GET changed later with a screenshot of the changes and/or a download…
The Arduino code and the library for this project can be found at the links below. The library has to be saved in the Arduino libraries folder of the same name:
- https://www.dropbox.com/s/4by3peoau2s25wz/esp8266weblcd.ino?dl=0 ===> The .ino file (Arduino Sketch/Code)
- https://www.dropbox.com/s/l5qe8ko64mu0037/esplcdweb.h?dl=0 ===> The esplcdweb.h file for creating the web-page
- …
Find below, please, my changed code (Sketch) for downloading:
The download is a text file created with OpenOffice, copy the content and place it into a new Sketch on the Arduino IDE. ALL you have to do now is to change some lines, e.g.:
- in line 47: Enter your SSID
- in line 48 Enter your Wi-Fi Network Password
See PIC below, please:
.
.
This should work for you now; in case of that you wouldn’t see the display working find here the trouble-shooting:
Mostly it is that your LCD1602 uses a different I2C-Address and/or that the ESP8266 isn’t allowed in your network for security reasons, to make sure check my blog post here, please:
- I2C Scanner
- https://gustmees.wordpress.com/2018/07/04/first-steps-with-the-nodemcu-esp8266-wi-fi-module-maker-makered-coding-tips/
- https://gustmees.wordpress.com/2018/04/20/first-steps-with-the-esp8266-wi-fi-module-maker-makered-coding-scrolling-text-time-temp-humidity-with-8×8-led-matrix/
Here below a working Sketch which shows how it is working: for security reasons you won’t see my SSID, nor my real IP-Address! 😉
.
.
.
The author Gust MEES is ICT Course Instructor, ”Member of the Advisory Board” from “Luxembourg Safer Internet” (LuSI), BEESECURE, Official Partner (Consultant) from the Ministry of Education in Luxembourg, project “MySecureIT“, Official Partner from the Ministry of Commerce in Luxembourg, project “CASES” (Cyberworld Awareness and Security Enhancement Structure). The author was also a winner of an electronics contest (Germanic countries) in 1979 and got his project published in the “Electronics Magazine ELO”. |
.
Stay tuned for next blog post(s) 😉..
.
Keywords necessary for me to create this blog post: NodeMCU, ESP8266, Web Server, I2C, LCD1602, Coding, Maker, MakerED, MakerSpaces…
.
.
.
.
.
.
.
.
.
.
.