asd

Dependencies:   EPD_GDE021A1 mbed

Files at this revision

API Documentation at this revision

Comitter:
flawless
Date:
Thu Jun 01 12:33:16 2017 +0000
Commit message:
q

Changed in this revision

EPD_GDE021A1.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/EPD_GDE021A1.lib	Thu Jun 01 12:33:16 2017 +0000
@@ -0,0 +1,1 @@
+http://developer.mbed.org/teams/ST/code/EPD_GDE021A1/#6ee9c1afd6ec
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/main.cpp	Thu Jun 01 12:33:16 2017 +0000
@@ -0,0 +1,69 @@
+#include "mbed.h"
+#include "EPD_GDE021A1.h"
+
+#define EPD_CS       PA_15
+#define EPD_DC       PB_11
+#define EPD_RESET    PB_2
+#define EPD_BUSY     PA_8
+#define EPD_POWER    PB_10
+#define EPD_SPI_MOSI PB_5
+#define EPD_SPI_MISO PB_4
+#define EPD_SPI_SCK  PB_3
+
+EPD_GDE021A1 epd(EPD_CS, EPD_DC, EPD_RESET, EPD_BUSY, EPD_POWER, EPD_SPI_MOSI, EPD_SPI_MISO, EPD_SPI_SCK);
+
+DigitalOut led1(LED1);
+
+//width 48
+//height 26
+static uint8_t Battery_img[] = {
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xfe, 0xff, 0xff, 0xff, 0xff, 0x0f, 
+0xfe, 0xff, 0xff, 0x3f, 0x00, 0x0c, 
+0xfe, 0xff, 0xff, 0x3f, 0x00, 0x08, 
+0xfe, 0xff, 0xff, 0x3f, 0x00, 0x08, 
+0xfe, 0xff, 0xff, 0x3f, 0x00, 0x08, 
+0xfe, 0xff, 0xff, 0x3f, 0x00, 0x08, 
+0xfe, 0xff, 0xff, 0x3f, 0x00, 0x18, 
+0xfe, 0xff, 0xff, 0x3f, 0x10, 0x38, 
+0xfe, 0xff, 0xff, 0x3f, 0x10, 0x38, 
+0xfe, 0xff, 0xff, 0x3f, 0x10, 0x38, 
+0xfe, 0xff, 0xff, 0x3f, 0xff, 0x39, 
+0xfe, 0xff, 0xff, 0x3f, 0x10, 0x38, 
+0xfe, 0xff, 0xff, 0x3f, 0x10, 0x38, 
+0xfe, 0xff, 0xff, 0x3f, 0x10, 0x38, 
+0xfe, 0xff, 0xff, 0x3f, 0x00, 0x38, 
+0xfe, 0xff, 0xff, 0x3f, 0x00, 0x18, 
+0xfe, 0xff, 0xff, 0x3f, 0x00, 0x08, 
+0xfe, 0xff, 0xff, 0x3f, 0x00, 0x08, 
+0xfe, 0xff, 0xff, 0x3f, 0x00, 0x08, 
+0xfe, 0xff, 0xff, 0x3f, 0x00, 0x0c, 
+0xfe, 0xff, 0xff, 0x3f, 0x00, 0x0c, 
+0xfe, 0xff, 0xff, 0xff, 0xff, 0x0f, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+};
+
+int main()
+{
+    led1 = 1;
+    
+    epd.Clear(EPD_COLOR_WHITE);  
+//    epd.DisplayStringAtLine(5, (uint8_t*)"HUEMBED", CENTER_MODE);
+//    epd.DisplayStringAtLine(2, (uint8_t*)"demo", LEFT_MODE);
+//    epd.DrawImage(130, 0, 48, 26, Battery_img);
+//    epd.DrawRect(50, 4, 60, 4);
+//    epd.RefreshDisplay();
+    wait(2);
+uint8_t i = 30;
+    while(1) {
+        led1 = !led1;
+        epd.Clear(EPD_COLOR_WHITE); 
+        epd.DisplayStringAtLine(5, (uint8_t*)"HUEMBED", CENTER_MODE); 
+        epd.DisplayStringAtLine(3, (uint8_t*)i, CENTER_MODE);
+        epd.RefreshDisplay();
+        i++;
+        wait(2);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/mbed.bld	Thu Jun 01 12:33:16 2017 +0000
@@ -0,0 +1,1 @@
+https://mbed.org/users/mbed_official/code/mbed/builds/86740a56073b
\ No newline at end of file