I have a spare Arduino Mega 2560 with RAMPS 1.4 board and a Reprap Smart controller and LCD that came from a 3D printer.
I am trying to control stepper motors, servo's and an LCD panel without using MARLIN Firmware.
I have never used Arduino before but by reading tutorials etc, I have managed to get four steppers working and also two servos.
What I would like to do is use the LCD panel.
Is there a way to do this? I have tried the example files supplied with Arduino IDE but these do not work.
I know that, in the Marlin Firmware, there are several lines that had to be changed in Configuration.h to be able to use the LCD.
Is it just a case of using the sketches supplied with Marlin? and if so, which ones?
Any help would be much appreciated.
This depends on LCD itself. What kind of LCD is mounted on the panel. Picture?
Oliver
dc42
January 14, 2017, 8:19am
3
olikraus:
This depends on LCD itself. What kind of LCD is mounted on the panel. Picture?
Oliver
These displays use standard 12864 panels with ST7920 controllers. Marlin uses u8glib to drive them, which AFAIR is your library.
olikraus:
This depends on LCD itself. What kind of LCD is mounted on the panel.
Oliver
Hi Oliver
it just says "Reprap discount smart controller"
It is a 4x20 LCD with a rotary encoder, SD card reader, beeper and 'kill' switch
These LCD Panels are sold with different controllers. If this is a 4x20 LCD in your case, then the Arduino LiquidCrystal lib should work. The only difficulty will be to figure out the correct pin numbers.
Oliver
olikraus:
These LCD Panels are sold with different controllers. If this is a 4x20 LCD in your case, then the Arduino LiquidCrystal lib should work. The only difficulty will be to figure out the correct pin numbers.
Oliver
Thank you olikraus. All sorted now.
If anybody else is following this thread, the following line gives the correct pins
liquidCrystal lcd(16, 17, 23, 25, 27, 29);
Pin 16=RS
Pin 17=Enable
Pins 23,25,27 and 29 are instead of pins 4,5,6 and 7 (for a standard LCD setup)
1 Like
phraust
February 11, 2017, 10:25pm
7
Dunno if this is too late, but I've been messing around with the same setup (ramps 1.4 + gadgets3d 4x20 LCD panel) and found this:
http://reprap.org/wiki/RAMPS_1.3/1.4_GADGETS3D_Shield_with_Panel
It has a bunch of info on em, plus the pins for everything:
#define BEEPER 33 // Beeper and is Connected into GADGETS3D shield MEGA_18BEEPER
#define LCD_PINS_RS 16 // LCD control and is connected into GADGETS3D shield LCDRS
#define LCD_PINS_ENABLE 17 // LCD enable pin and is connected into GADGETS3D shield LCDE
#define LCD_PINS_D4 23 // LCD signal pin, connected to Gadgets3D shield LCD4
#define LCD_PINS_D5 25 // LCD signal pin, connected to Gadgets3D shield LCD5
#define LCD_PINS_D6 27 // LCD signal pin, connected to Gadgets3D shield LCD6
#define LCD_PINS_D7 29 // LCD signal pin, connected to Gadgets3D shield LCD7
#define BTN_EN1 37 // Encoder left direction, connected to Gadgets3D shield S_E1
#define BTN_EN2 35 // Encoder right direction, connected to Gadgets3D shield S_E2
#define BTN_ENC 31 // Encoder Click, connected to Gadgets3D shield S_EC
1 Like
I am trying to achieve the same thing with the same setup.
This is the code I am using:
#include <LiquidCrystal.h>
LiquidCrystal lcd(16, 17, 23, 25, 27, 29);
void setup() {
// put your setup code here, to run once:
lcd.begin(20, 4);
}
void loop() {
lcd.home();
lcd.print("hello, world!");
delay(500);
lcd.clear();
delay(500);
}
The screen is on but there are no characters. I have tried changing the trim pot. What should I do?