Hi all. I’m starting my first real Spark project and would like to add an LCD for feedback. The LCD I’m using came with an Arduino kit I bought and the backpack is a Serial IIC I2C Adapter Serial Interface Board Module For Arduino, Model: GY-IIC-LCD.
I’ve read the existing I2C/LCD posts (very informative) and tried all the code. Some of it sorta worked, some not at all (no fault of the authors I’m sure). By sorta, I mean I can get the backlight to work but it doesn’t write anything to the screen.
Does anyone have a bare-bones “Hello World” sample code I can use as a starting point? I would like to start simple and build on whatever success I can achieve. BTW, I am a novice programmer so simpler is better.
Thanks,
Bruster
@Bruster, you now have 3 topics regarding this display. Can I ask you to kindly keep it to one so we don’t have to repeat our answers
I have the impression that something is not setup correctly with either the hardware or the code. On THIS topic, can you post the code your are attempting to use?
Hi all,
I just got my new Spark and I’m trying to get it to work with my 1602 LCD with backpack. Unfortunately I can’t even get to 1st base (no backlight). The LCD came with the Arduino kit I bought and the backpack is a Serial IIC I2C Adapter Serial Interface Board Module For Arduino 1602 2004 LCD, Model: GY-IIC-LCD.
I know the LCD works as I tried it on an Arduino (twice) and have used it on other Arduino projects. I tried two different AC adapters as power sources as well as powering from USB. One of the power sources I used to test with the UNO. There is an LED on the backpack that lights up. I checked the voltage between VCC and GND and it’s 4.56v on the Spark and 4.78v on the Arduino.
Any thoughts or magic tricks to get the LCD to illuminate?
Bruster
@Bruster, first things first. You may need pull-up resistors (4.7K ohms) on the I2C lines if there are none on the backpack. Seconds, which library are you using? Third, I believe the backlight is turned on with software so that may explain that.
@peekay123, I’m using code from a project called “lcd-buses-±weather-report” and trimmed out everything but the backlight command for now. I’ll try the pull-ups and see if that helps. Thanks.
Dang. Didn’t work. I added the 4.7k pull-ups from the +5v rail to D0 and D1. Is there a simple I2C LCD test sketch floating around? Something akin to “Hello Sparky!”?
I can see that you don’t have any external pull-up resistors on the i2c lines. On Spark these always need a pull-up resistor (4.7k ohm is ideal) to 3.3V.
Have you tried adding pull-up resistors on both lines?
Hi @bko. I didn’t at first but I read others discussing the pull-ups and added them but it didn’t make any difference. I put the 4.7k resistors from the +5 rail to D1 and D1. The code loads into the Spark, the main LED breaths cyan but the display remains blank.
@Bruster The display in your picture looks broken - you shouldn’t have that blacked out area in the centre of the LCD and certainly not that large smudge along where the bottom line of text should be. Have you exposed it to high temperatures or dropped it/had something resting on it?
Do you have a different LCD you can test this with?
Hey @NanoAkron. I appreciate the input but the LCD itself is ok. I’m using it right now on an Arduino project. I think what you are seeing is just the plastic film on the screen that protects the soft plastic display. I never remove that unless I have to.
However, I have ordered new 16x2 and 20x4 displays.