Schematic? How is it being powered? Have you uploaded with the LCD disconnected successfully? Which LCD? From MarkT
Mark, thanks for getting back to me.
I’m using an Arduino R3 board, sold by NKC Electronics (says it is made in Italy). The R3 board and all related electronics are powered via the USB cable which connects to the USB port on my Mac Powerbook.
The LCD display module is a 4line x 16 column from Hacktronics, and I’ve followed their wiring instructions, with some variance in the resistor and potentiometer I’ve selected:
• resistor at pin 15 (backlight) is orange-orange-brown-gold (330K), whereas they recommend 40K minimum to limit current (but note that the backlight has continued to operate).
• potentiometer at V0 (LCD power) is a trimpot that I received in a box of Arduino accessories from G&O Accessory (fulfilled by NKC Electronics). I have used it to provide between 4.85 and 4.9 volts to V0 via the center tap, the outside pins are +5V and GND.
• I should also point out that I soldered the header pins onto the module myself, so there’s a risk of cold solder joints, though the display was working for the first few days.
Here’s the wiring instructions:
LCD PIN LCD NAME Arduino PIN
1 VSS GND
2 VDD 5V
3 V0 (contrast) Potentiometer
4 RS 12
5 R/W 11
6 Enable 10
7 No connect
8 No connect
9 No connect
10 No connect
11 Data 4 5
12 Data 5 4
13 Data 6 3
14 Data 7 2
15 Backlight 13, resistor
16 B.Light GND GND
The LCD module is plugged into a breadboard into which I had also periodically plugged in other projects back when the LCD was working, including a photo sensor and associated resistor, and a stepper motor. These other projects shared the power and ground with the LCD module (either plugging into the power or ground busses, or plugging wires directly into the protoboard rows for the LCD that receive either power or ground). I’ve removed the other projects for now.
Since the LCD worked previously, and since the other projects continued to work while they were on the board, I would have thought I fried the LCD somehow, except that the backlight continued to work and I began receiving the intermittent programmer error I mentioned previously. Here is the code I am running, I got it from the Hacktronics website, and uncommented the lines to work with a 4 line LCD instead of 2 line, and I tried unsuccessfully to add a debugging print out to the serial monitor:
// character LCD example code
// rs (LCD pin 4) to Arduino pin 12
// rw (LCD pin 5) to Arduino pin 11
// enable (LCD pin 6) to Arduino pin 10
// LCD pin 15 to Arduino pin 13
// LCD pins d4, d5, d6, d7 to Arduino pins 5, 4, 3, 2
LiquidCrystal lcd(12, 11, 10, 5, 4, 3, 2);
int backLight = 13; // pin 13 will control the backlight
delay (5000); //gives me time to go to menu to open serial monitor
// need to find a command to do that!
// this does not work as a diagnostic
Serial.print("Ping: "); // one of these lines should write to the serial monitor
Serial.println("Ping");// one of these lines should write to the serial monitor
digitalWrite(backLight, HIGH); // turn backlight on. Replace 'HIGH' with 'LOW' to turn it off.
lcd.begin(16,4); // columns, rows. use 16,2 for a 16x2 LCD, etc.
lcd.clear(); // start with a blank screen
lcd.setCursor(0,0); // set cursor to column 0, row 0 (the first row)
lcd.print("Hello, Ben"); // change this text to whatever you like. keep it clean.
lcd.setCursor(0,1); // set cursor to column 0, row 1
// if you have a 4 row LCD, uncomment these lines to write to the bottom rows
// and change the lcd.begin() statement above.
lcd.setCursor(0,2); // set cursor to column 0, row 2
lcd.setCursor(0,3); // set cursor to column 0, row 3
lcd.print("Pull NFL Score");
Thanks again for the help, Bryan