Contains the main execution of the clock uses headers to import functions

Dependencies:   RTC-DS1307 SPI_TFT_ILI9341 TFT_fonts mbed tsi_sensor

Fork of TFT_Mikroelectronika_IL9341_sketchpad by Oxford CWM Team

Committer:
mlin
Date:
Thu May 25 09:48:31 2017 +0000
Revision:
16:3cb9b1fbc039
Parent:
12:50289d0ac834
Child:
19:4c30c3182e04
Added basic interaction control for the time screen

Who changed what in which revision?

UserRevisionLine numberNew contents of line
mlin 9:eee503060d69 1 #include "libs.h"
Owenmatthewmcgowan 12:50289d0ac834 2 //DigitalOut led(LED1);
mlin 16:3cb9b1fbc039 3 bool f_alarm, f_alarm_sound;
mlin 16:3cb9b1fbc039 4 int f_state_no;
Owenmatthewmcgowan 12:50289d0ac834 5 //DigitalIn sw_w(SW3);
cstevens 6:18c7288b5e00 6
mlin 9:eee503060d69 7 void main()
dreschpe 0:7c3b9bfd6ead 8 {
dreschpe 0:7c3b9bfd6ead 9 TFT.claim(stdout); // send stdout to the TFT display
dreschpe 0:7c3b9bfd6ead 10 TFT.set_orientation(1);
dreschpe 0:7c3b9bfd6ead 11 TFT.background(Black); // set background to black
dreschpe 0:7c3b9bfd6ead 12 TFT.foreground(White); // set chars to white
mlin 11:1da15361a35b 13 TFT.cls();
mlin 11:1da15361a35b 14 // pc.baud(115200);
Owenmatthewmcgowan 12:50289d0ac834 15 /*int i = 0;
mlin 10:9d9b3b9b28b8 16 while (true) {
mlin 11:1da15361a35b 17 i = (i % 3) + 1;
mlin 11:1da15361a35b 18 draw_state(i);
mlin 11:1da15361a35b 19 wait(1);
Owenmatthewmcgowan 12:50289d0ac834 20 }*/
mlin 16:3cb9b1fbc039 21
mlin 16:3cb9b1fbc039 22
Owenmatthewmcgowan 12:50289d0ac834 23 draw_state(4);
mlin 11:1da15361a35b 24
mlin 11:1da15361a35b 25
mlin 11:1da15361a35b 26
cstevens 6:18c7288b5e00 27
dreschpe 0:7c3b9bfd6ead 28 }