Repo_test
Dependencies: 4DGL-uLCD-SE mbed
Revision 0:53bbc6d1d4de, committed 2017-08-26
- Comitter:
- jacksugar
- Date:
- Sat Aug 26 23:35:29 2017 +0000
- Commit message:
- Version_0.1
Changed in this revision
diff -r 000000000000 -r 53bbc6d1d4de 4DGL-uLCD-SE.lib --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/4DGL-uLCD-SE.lib Sat Aug 26 23:35:29 2017 +0000 @@ -0,0 +1,1 @@ +http://developer.mbed.org/users/sparkfun/code/4DGL-uLCD-SE/#e39a44de229a
diff -r 000000000000 -r 53bbc6d1d4de main.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/main.cpp Sat Aug 26 23:35:29 2017 +0000 @@ -0,0 +1,50 @@ +// Demo for the uLCD-144-G2 based on the work by Jim Hamblen + +#include "mbed.h" +#include "uLCD_4DGL.h" + +uLCD_4DGL uLCD(p9,p10,p11); // serial tx, serial rx, reset pin; + +int main() +{ + // basic printf demo = 16 by 18 characters on screen + uLCD.printf("\nHello uLCD World\n"); //Default Green on black text + uLCD.printf("\n Starting Demo..."); + uLCD.text_width(4); //4X size text + uLCD.text_height(4); + uLCD.color(RED); + for (int i=5; i>=0; --i) { + uLCD.locate(1,2); + uLCD.printf("%2D",i); + wait(.5); + } + uLCD.cls(); + uLCD.printf("Change baudrate......"); + uLCD.baudrate(9600); //jack up baud rate to max for fast display + //if demo hangs here - try lower baud rates + + wait(0.5); + //demo graphics commands + uLCD.background_color(BLACK); + uLCD.cls(); + uLCD.background_color(DGREY); + uLCD.filled_circle(60, 50, 30, 0xFF00FF); + uLCD.triangle(120, 100, 40, 40, 10, 100, 0x0000FF); + uLCD.line(0, 0, 80, 60, 0xFF0000); + uLCD.filled_rectangle(50, 50, 100, 90, 0x00FF00); + uLCD.pixel(60, 60, BLACK); + uLCD.read_pixel(120, 70); + uLCD.circle(120, 60, 10, BLACK); + uLCD.set_font(FONT_7X8); + uLCD.text_italic(ON); + uLCD.text_mode(TRANSPARENT); + uLCD.text_string("This", 1, 4, FONT_7X8, WHITE); + wait(.5); + uLCD.text_italic(ON); + uLCD.text_string("STUFF", 8, 8, FONT_7X8, BLACK); + wait(.5); +// uLCD.text_width(2); //4X size text +// uLCD.text_height(2); + uLCD.text_string("ROCKS", 5, 13, FONT_7X8, RED); + wait(200); +} \ No newline at end of file
diff -r 000000000000 -r 53bbc6d1d4de mbed.bld --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/mbed.bld Sat Aug 26 23:35:29 2017 +0000 @@ -0,0 +1,1 @@ +https://mbed.org/users/mbed_official/code/mbed/builds/e2bfab296f20 \ No newline at end of file