Vizic Technologies
/
House
SMARTGPU drawing figures demo!
Revision 0:8ab32fd6eb85, committed 2011-09-14
- Comitter:
- emmanuelchio
- Date:
- Wed Sep 14 05:31:55 2011 +0000
- Commit message:
- Rev 1.0
Changed in this revision
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/SMARTGPU.lib Wed Sep 14 05:31:55 2011 +0000 @@ -0,0 +1,1 @@ +http://mbed.org/users/emmanuelchio/code/SMARTGPU/#8da93960a86b
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/main.cpp Wed Sep 14 05:31:55 2011 +0000 @@ -0,0 +1,55 @@ +/**************************************************************************************/ +/*SMARTGPU intelligent embedded graphics processor unit + those examples are for use the SMARTGPU with the mbed microcontoller, just connect tx,rx,and reset + Board: + http://www.vizictechnologies.com/#/desarrollo/4554296549 + + www.vizictechnologies.com + Vizic Technologies copyright 2011 */ +/**************************************************************************************/ +/**************************************************************************************/ + +#include "mbed.h" +#include "SMARTGPU.h" + +//Some colour definitions +#define orange 0xFC0F +#define brown 0xBBCA +#define ligBlue 0x96DD + +SMARTGPU lcd(p13,p14,p15); //(TX,RX,Reset); + + +int main() { + lcd.reset(); //physically reset SMARTGPU + lcd.start(); //initialize the SMARTGPU processor + + //draw the house + lcd.drawRectangle(78,134,212,217,orange,FILL); //draw a rectangle + lcd.drawRectangle(78,134,212,217,BLACK,UNFILL); //draw a rectangle + lcd.drawTriangle(75,133,216,133,146,63,RED,FILL); //draw a triangle + lcd.drawTriangle(75,133,216,133,146,63,BLACK,UNFILL); //draw a triangle + lcd.drawRectangle(136,167,170,217,brown,FILL); //draw a rectangle + lcd.drawRectangle(136,167,170,217,BLACK,UNFILL); //draw a rectangle + lcd.drawCircle(106,160,15,ligBlue,FILL); //draw a circle + lcd.drawCircle(106,160,15,BLACK,UNFILL); //draw a circle + lcd.drawCircle(195,187,10,ligBlue,FILL); //draw a circle + lcd.drawCircle(195,187,10,BLACK,UNFILL); //draw a circle + + //draw left tree + lcd.drawRectangle(25,157,45,218,brown,FILL); //draw a rectangle + lcd.drawRectangle(25,157,45,218,BLACK,UNFILL); //draw a rectangle + lcd.drawCircle(35,120,35,GREEN,FILL); //draw a circle + lcd.drawCircle(35,120,35,BLACK,UNFILL); //draw a circle + //draw right tree + lcd.drawRectangle(270,167,283,218,brown,FILL); //draw a rectangle + lcd.drawRectangle(270,167,283,218,BLACK,UNFILL); //draw a rectangle + lcd.drawCircle(277,134,35,GREEN,FILL); //draw a circle + lcd.drawCircle(277,134,35,BLACK,UNFILL); //draw a circle + + //draw grass + lcd.drawLine(5,218,314,218,GREEN); //draw a line + + //loop forever + while(1); +} \ No newline at end of file
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/mbed.bld Wed Sep 14 05:31:55 2011 +0000 @@ -0,0 +1,1 @@ +http://mbed.org/users/mbed_official/code/mbed/builds/63bcd7ba4912