Behrooz Abdi
/
Tiger_LCD
Landtiger (LPC1768) graphics LCD demo.
Diff: main.cpp
- Revision:
- 3:2dccfa0121de
- Parent:
- 2:43ede88fb5a3
- Child:
- 4:cdeea87f25d8
--- a/main.cpp Tue Nov 06 21:39:33 2012 +0000 +++ b/main.cpp Fri Oct 30 01:26:40 2015 +0000 @@ -126,6 +126,8 @@ // GLCD GLCD myGLCD; +#include "Julia.h" + // LCD Animation #if(0) void GLCD_pulse() { @@ -224,7 +226,7 @@ myGLCD.drawPixel(i,119+(cos(((i*1.13)*3.14)/180)*95)); } - myGLCD.setColor(255,255,0); + myGLCD.setColor(255,0,255); // myGLCD.print("Tan", 5, 39); for (int i=1; i<318; i++) { @@ -481,7 +483,7 @@ pc.printf("Hello World!\n\r"); - myGLCD.Init(); +// myGLCD.init(); // done in cosntructor myGLCD.clearScreen(White); // GLCD_clearScreen(Blue); // GLCD_Bmp( 0, 0, 320, 69, (unsigned char*) Bg_16bpp_t+70); @@ -510,12 +512,29 @@ pc.printf("LCD Controller ID = 0x%04X\n\r", myGLCD.getDriverCode()); - loop(); + loop(); +// float k = 0.0; + float re_min=-0.17775; + float im_min= 0.7675; + float len= 0.32375; + while(1) { pc.printf("+"); - + pc.printf("\n\rEnter re_min: "); + pc.scanf("%f", &re_min); + pc.printf("\n\rEnter im_min: "); + pc.scanf("%f", &im_min); + pc.printf("\n\rEnter len: "); + pc.scanf("%f", &len); + + pc.printf("\n\rValues: re_min=%0.5f, im_min=%0.5f, len=%0.5f\n\r", re_min, im_min, len); + mandelbrot(320, 240, 400, re_min, re_min+len, im_min, im_min+len); +// mandelbrot(150, 150, 400, re_min, re_min+len, im_min, im_min+len+k); + +// k = k + 0.023; + wait(0.1); };