Demo program for driving the memory LCD on the Zero Gecko Starter Kit.
This demo program shows how to drive the memory LCD on the Zero Gecko Starter Kit, by using asynchronous transfers.
Information
All examples in this repo are considered EXPERIMENTAL QUALITY, meaning this code has been created as one-off proof-of-concept and is suitable as a demonstration for experimental purposes only. This code will not be regularly maintained by Silicon Labs and there is no guarantee that these projects will work across all environments, SDK versions and hardware.
Diff: main.cpp
- Revision:
- 11:9b7257e888c1
- Parent:
- 10:2acd2401b1a0
- Child:
- 12:542a3be118c1
diff -r 2acd2401b1a0 -r 9b7257e888c1 main.cpp --- a/main.cpp Wed May 27 11:59:26 2015 +0000 +++ b/main.cpp Wed May 27 12:09:22 2015 +0000 @@ -15,7 +15,6 @@ #define MOSI_PIN PE10 #define CS_PIN PA10 #define EXTCOM_PIN PF3 -#define DISP_PIN PA8 #define DISPSEL_PIN PA8 #else #error "undefined pinout" @@ -23,7 +22,9 @@ DigitalOut CS(CS_PIN); DigitalOut EXTCOM(EXTCOM_PIN); +#ifdef DISP_PIN DigitalOut DISP(DISP_PIN); +#endif DigitalOut DISP_SEL(DISPSEL_PIN); SPI displaySPI(MOSI_PIN, NC, SCK_PIN); @@ -58,7 +59,9 @@ int main() { // Enable the LCD DISP_SEL = 1; +#ifdef DISP_PIN DISP = 1; +#endif // Start generating the 1Hz call for keeping time timeKeeping.attach(&secondsCallback, 1.0f);