Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
41 changes: 37 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,16 +29,43 @@ Parallel LCD pin to Nano
4 RS -> D9
5 RW -> A0
6 EN -> A1
11 D4 -> D5
12 D5 -> D6
13 D6 -> D7
14 D7 -> D8
11 DB4 -> D5
12 DB5 -> D6
13 DB6 -> D7
14 DB7 -> D8

1 gnd
2 +5v
3 contrast
15,16 backlight power (on some)

PanelOne (5V) LCD pin to Nano
--------------------

AUX2 6 RS -> D9
AUX2 8 EN -> A1
AUX2 10 DB4 -> D5
AUX2 9 DB5 -> D6
AUX2 7 DB6 -> D7
AUX2 5 DB7 -> D8
AUX2 4 ENCA -> D2
AUX2 3 ENCB -> D3
AUX3 7 ENCSW -> A2

AUX2 2 -> GND
AUX2 1 -> +5V

PanelOne (5V) SD pin to Smoothie
--------------------

AUX3 3 CS -> Unused GPIO : 1.30
AUX3 4 CLK -> SCK : 0.15
AUX3 5 DO -> MISO : 0.17
AUX3 6 DI -> MOSI : 0.18

AUX3 2 -> GND
AUX3 8 -> +5V

Smoothie to Nano
----------------
MOSI -> D11 : 0.18
Expand All @@ -58,6 +85,12 @@ add this to your config file on smoothie
panel.spi_cs_pin 0.16 # spi chip select
panel.busy_pin 2.11 # busy pin NOTE 1.30 on Azteeg X5

second SD card on panelone

panel.external_sd true # set to true if there is an extrernal sdcard on the panel
panel.external_sd.spi_channel 0 # set spi channel the sdcard is on
panel.external_sd.spi_cs_pin 1.30 # set spi chip select for the sdcard (or any spare pin)
panel.external_sd.sdcd_pin nc # sd detect signal (set to nc if no sdcard detect) (or any spare pin)

Requirements
------------
Expand Down
2 changes: 2 additions & 0 deletions digitalWriteFast.h
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
#include "Arduino.h"
#if ARDUINO < 150
#include <wiring.h>
#endif

#define BIT_READ(value, bit) (((value) >> (bit)) & 0x01)
#define BIT_SET(value, bit) ((value) |= (1UL << (bit)))
Expand Down
10 changes: 9 additions & 1 deletion upa.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,9 @@ SS -> D10
#define VIKI 1
//#define PARALLEL 1

//select if parallel panel has RW pin connected
#define RW_PIN 1

#ifdef VIKI
#include "LiquidTWI2.h"
#include "utility/twi.h"
Expand All @@ -32,6 +35,7 @@ LiquidTWI2 lcd(0); // uses pins SDA -> A4, SCL -> A5
#include "LiquidCrystalFast.h"
// parallel LCD Pins
// LCD pins: RS RW EN D4 D5 D6 D7
// if not defined RW_PIN then RW needs to be connected to GND
#define LCD_RS 9 // D9
#define LCD_RW A0 // A0
#define LCD_EN A1 // A1
Expand All @@ -40,7 +44,11 @@ LiquidTWI2 lcd(0); // uses pins SDA -> A4, SCL -> A5
#define LCD_D6 7 // D7
#define LCD_D7 8 // D8

#if defined(RW_PIN)
LiquidCrystalFast lcd(LCD_RS, LCD_RW, LCD_EN, LCD_D4, LCD_D5, LCD_D6, LCD_D7);
#else
LiquidCrystalFast lcd(LCD_RS, LCD_EN, LCD_D4, LCD_D5, LCD_D6, LCD_D7);
#endif // defined(RW_PIN)

#define CLICK_PIN A2 // A2 Encoder click pin
#define BUZZER_PIN A3 // A3 Buzzer pin
Expand Down Expand Up @@ -240,7 +248,7 @@ void setup (void)
clear();

lcd.setCursor(0, 0);
lcd.print("UPA V0.98");
lcd.print("UPA V0.99");
lcd.setCursor(0, 1);
lcd.print("Starting up...");
} // end of setup
Expand Down