A minimal sample for the RA8875 display.

Dependencies:   mbed RA8875

Committer:
WiredHome
Date:
Sat Jan 23 17:31:45 2016 +0000
Revision:
1:55ebb2423290
Parent:
0:8446f99d40a0
Child:
2:6948590d9b13
update libs

Who changed what in which revision?

UserRevisionLine numberNew contents of line
WiredHome 1:55ebb2423290 1 #include "mbed.h" // v112
WiredHome 1:55ebb2423290 2 #include "RA8875.h" // v102
WiredHome 0:8446f99d40a0 3
WiredHome 0:8446f99d40a0 4 RA8875 lcd(p5, p6, p7, p12, NC, "tft");
WiredHome 0:8446f99d40a0 5
WiredHome 0:8446f99d40a0 6 int main()
WiredHome 0:8446f99d40a0 7 {
WiredHome 0:8446f99d40a0 8 lcd.init();
WiredHome 0:8446f99d40a0 9 lcd.printf("printing 3 x 2 = %d", 3*2);
WiredHome 0:8446f99d40a0 10 lcd.circle( 400,25, 25, BrightRed);
WiredHome 0:8446f99d40a0 11 lcd.fillcircle( 400,25, 15, RGB(128,255,128));
WiredHome 0:8446f99d40a0 12 lcd.ellipse( 440,75, 35,20, BrightBlue);
WiredHome 0:8446f99d40a0 13 lcd.fillellipse( 440,75, 25,10, Blue);
WiredHome 0:8446f99d40a0 14 lcd.triangle( 440,100, 475,110, 450,125, Magenta);
WiredHome 0:8446f99d40a0 15 lcd.filltriangle( 445,105, 467,111, 452,120, Cyan);
WiredHome 0:8446f99d40a0 16 lcd.rect( 400,130, 475,155, Brown);
WiredHome 0:8446f99d40a0 17 lcd.fillrect( 405,135, 470,150, Pink);
WiredHome 0:8446f99d40a0 18 lcd.roundrect( 410,160, 475,190, 10,8, Yellow);
WiredHome 0:8446f99d40a0 19 lcd.fillroundrect(415,165, 470,185, 5,3, Orange);
WiredHome 0:8446f99d40a0 20 lcd.line( 430,200, 460,230, RGB(0,255,0));
WiredHome 0:8446f99d40a0 21 for (int i=0; i<=30; i+=5)
WiredHome 0:8446f99d40a0 22 lcd.pixel(435+i,200+i, White);
WiredHome 0:8446f99d40a0 23 }