/* **************************************** * * Title * * **************************************** * * (C) 201x-xx-xx Paolo Iocco * * rev. 0.x * * **************************************** * * Circuit diagram * --------------- * +-------+ * | ooooo | * D1--TX<----| A |<---------RAW * D0--RX---->| r |<---------GND * RST------->| d |<---------RST * GND------->| u |<---------VCC * D2-------->| i |-----A3---D17 * D3----#--->| n |-----A2---D16 * D4-------->| o |-----A1---D15 * D5<---#----| |-----A0---D14 * D6<---#----| m |-----SCK--D13 * D7---------| i |-----MISO-D12 * D8---------| n |--#--MOSI-D11 * D9----#----| i |--#--SS---D10 * +-------+ * * ***************************************** */ #include "sys64738.h" #define led 13 // PORTB.5 #define LCD_CE 4 // portd.4 #define LCD_RST 3 // portd.3 #define LCD_DC 5 // portd.5 #define LCD_SDI 6 // portd.6 #define LCD_SCK 7 // portd.7 Display5110 Lcd(LCD_CE, LCD_RST, LCD_DC, LCD_SDI, LCD_SCK); void setup() { pinMode(led, OUTPUT); Lcd.Init(); Lcd.WriteStringXY(0,0,"Hello World",FONT_6x8); } void loop() { digitalWrite(led, HIGH); // turn the LED on (HIGH is the voltage level) delay(100); // wait for a second digitalWrite(led, LOW); // turn the LED off by making the voltage LOW delay(400); // wait for a second }