Example program for Grove RGB LCD display.

Dependencies:   Grove_LCD_RGB_Backlight mbed

Files at this revision

API Documentation at this revision

Comitter:
cmatz3
Date:
Tue Mar 15 17:21:58 2016 +0000
Commit message:
initial commit;

Changed in this revision

Grove_LCD_RGB_Backlight.lib Show annotated file Show diff for this revision Revisions of this file
main.cpp Show annotated file Show diff for this revision Revisions of this file
mbed.bld Show annotated file Show diff for this revision Revisions of this file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Grove_LCD_RGB_Backlight.lib	Tue Mar 15 17:21:58 2016 +0000
@@ -0,0 +1,1 @@
+https://developer.mbed.org/users/cmatz3/code/Grove_LCD_RGB_Backlight/#253885b1f364
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/main.cpp	Tue Mar 15 17:21:58 2016 +0000
@@ -0,0 +1,39 @@
+#include "Grove_LCD_RGB_Backlight.h"
+#include "mbed.h"
+
+Grove_LCD_RGB_Backlight rgbLCD(p9, p10);
+//I2C i2c(p9, p10);
+//Serial pc(USBTX, USBRX);
+
+int main()
+{
+
+   rgbLCD.setRGB(0xff, 0xff, 0xff);                 //set the color 
+   rgbLCD.print("Hello World!");
+   rgbLCD.locate(0,1);
+   rgbLCD.print("This is a test");
+   wait(5);
+   int count = 0;
+   while(1)
+   {
+     if (count == 0)
+     {
+         rgbLCD.setRGB(0xff, 0x00, 0x00);
+     }   
+     else if (count == 1)
+     {
+         rgbLCD.setRGB(0x00, 0xff, 0x00);
+     }
+     else if (count == 2)
+     {
+         rgbLCD.setRGB(0x00, 0x00, 0xff);
+     }
+     wait(1);
+     count++;
+     if(count == 3)
+     {
+         count = 0;
+     }
+     
+   }
+}
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/mbed.bld	Tue Mar 15 17:21:58 2016 +0000
@@ -0,0 +1,1 @@
+http://mbed.org/users/mbed_official/code/mbed/builds/87f2f5183dfb
\ No newline at end of file