Dependencies:   mbed

Committer:
JLS
Date:
Sat Dec 25 10:47:48 2010 +0000
Revision:
0:c1a2bb86a79d
Child:
1:2e21ada3b00e

        

Who changed what in which revision?

UserRevisionLine numberNew contents of line
JLS 0:c1a2bb86a79d 1 #include "TFT_4DGL.h"
JLS 0:c1a2bb86a79d 2
JLS 0:c1a2bb86a79d 3 TFT_4DGL lcd(p9,p10,p11);
JLS 0:c1a2bb86a79d 4
JLS 0:c1a2bb86a79d 5 int main() {
JLS 0:c1a2bb86a79d 6
JLS 0:c1a2bb86a79d 7 float a = 2.27;
JLS 0:c1a2bb86a79d 8
JLS 0:c1a2bb86a79d 9 float x = 0.001;
JLS 0:c1a2bb86a79d 10 float y = 0.001;
JLS 0:c1a2bb86a79d 11
JLS 0:c1a2bb86a79d 12 int xout = 0;
JLS 0:c1a2bb86a79d 13 int yout = 0;
JLS 0:c1a2bb86a79d 14
JLS 0:c1a2bb86a79d 15 lcd.baudrate(600000);
JLS 0:c1a2bb86a79d 16
JLS 0:c1a2bb86a79d 17 while (1) {
JLS 0:c1a2bb86a79d 18
JLS 0:c1a2bb86a79d 19 double oldX = x;
JLS 0:c1a2bb86a79d 20
JLS 0:c1a2bb86a79d 21 x = a*oldX*(1-y);
JLS 0:c1a2bb86a79d 22 y = oldX;
JLS 0:c1a2bb86a79d 23
JLS 0:c1a2bb86a79d 24 xout = 35+(x*250);
JLS 0:c1a2bb86a79d 25 yout = 15+(y*205);
JLS 0:c1a2bb86a79d 26
JLS 0:c1a2bb86a79d 27 lcd.pixel(yout,xout,WHITE);
JLS 0:c1a2bb86a79d 28
JLS 0:c1a2bb86a79d 29 }
JLS 0:c1a2bb86a79d 30 }