ban4jp -
/
AkiSpiLcd_demo
Simple animation demo.
Fork of AkiSpiLcd_example by
main.cpp
- Committer:
- k4zuki
- Date:
- 2014-05-06
- Revision:
- 5:8883e74c0f11
- Parent:
- 3:8dbf3336dc66
- Child:
- 6:b4ae3f550487
File content as of revision 5:8883e74c0f11:
#define MBEDSHIELD_050 #include "mbed.h" #include "hogepic.h" #include "AkiSpiLcd.h" /* 1 SCLK D3=p13 2 MOSI D5=p11 3 CS D2=p14 4 DISP enable D5=p22 */ AkiSpiLcd LCD(MOSI_, SCK_, D2, D5); DigitalOut myled(LED1); extern const uint8_t hogepic[]; int main() { wait_ms(1); LCD.cls(); LCD.updateSingle(10,(uint8_t*)(hogepic+2000)); LCD.updateMulti(100,(240-100),(uint8_t*)(hogepic)); while(1) { for(int i=0; i<240; i++) { LCD.updateMulti(i,(240-i),(uint8_t*)(hogepic)); LCD.updateMulti(0,(i),(uint8_t*)(hogepic+50*(240-i))); } } }