.

Dependencies:   BurstSPI EaEpaper mbed

Fork of epaper_mbed_130411_KL25Z by Peter Drescher

Committer:
dreschpe
Date:
Sun Nov 10 22:34:29 2013 +0000
Revision:
3:6ab30c065d39
Parent:
1:5ba919589a12
Child:
4:05cb9a1b60ca
fix

Who changed what in which revision?

UserRevisionLine numberNew contents of line
dreschpe 0:057244fcbbb6 1 #include "mbed.h"
dreschpe 0:057244fcbbb6 2 #include "EaEpaper.h"
dreschpe 0:057244fcbbb6 3 #include "Arial28x28.h"
dreschpe 0:057244fcbbb6 4 #include "Arial12x12.h"
dreschpe 0:057244fcbbb6 5 #include "font_big.h"
dreschpe 0:057244fcbbb6 6 #include "graphics.h"
dreschpe 0:057244fcbbb6 7
dreschpe 3:6ab30c065d39 8 EaEpaper epaper(PTD7, // PWR_CTRL
dreschpe 3:6ab30c065d39 9 PTD6, // BORDER
dreschpe 3:6ab30c065d39 10 PTE31, // DISCHARGE
dreschpe 3:6ab30c065d39 11 PTA17, // RESET_DISP
dreschpe 3:6ab30c065d39 12 PTA16, // BUSY
dreschpe 3:6ab30c065d39 13 PTC17, // SSEL
dreschpe 3:6ab30c065d39 14 PTD4, // PWM
dreschpe 3:6ab30c065d39 15 PTD2,PTD3,PTD1, // MOSI,MISO,SCLK
dreschpe 3:6ab30c065d39 16 PTE0,PTE1); // SDA,SDL
dreschpe 0:057244fcbbb6 17
dreschpe 0:057244fcbbb6 18 int main() {
dreschpe 0:057244fcbbb6 19
dreschpe 0:057244fcbbb6 20 epaper.cls();
dreschpe 0:057244fcbbb6 21 epaper.set_font((unsigned char*) Arial28x28); // select the font
dreschpe 0:057244fcbbb6 22 epaper.locate(5,20);
dreschpe 0:057244fcbbb6 23 epaper.printf("Hello Mbed");
dreschpe 0:057244fcbbb6 24 epaper.rect(3,15,150,50,1);
dreschpe 0:057244fcbbb6 25
dreschpe 0:057244fcbbb6 26 epaper.set_font((unsigned char*) Arial12x12);
dreschpe 0:057244fcbbb6 27 epaper.locate(5,60);
dreschpe 0:057244fcbbb6 28 epaper.printf("small Font");
dreschpe 0:057244fcbbb6 29 epaper.set_font((unsigned char*) Neu42x35);
dreschpe 0:057244fcbbb6 30 epaper.locate(5,70);
dreschpe 0:057244fcbbb6 31 epaper.printf("big Font");
dreschpe 0:057244fcbbb6 32
dreschpe 0:057244fcbbb6 33 epaper.write_disp(); // update screen
dreschpe 0:057244fcbbb6 34
dreschpe 0:057244fcbbb6 35 wait(5);
dreschpe 0:057244fcbbb6 36 epaper.fillcircle(180,30,22,1);
dreschpe 0:057244fcbbb6 37 epaper.circle(160,150,20,1);
dreschpe 0:057244fcbbb6 38 epaper.write_disp(); // update screen
dreschpe 0:057244fcbbb6 39
dreschpe 0:057244fcbbb6 40 }