Changes done in ECG and BT

Dependencies:   SDFileSystem ds3231 eeprom_Nikita mbed testUniGraphic_150217

Fork of merged_code2_20sept_2017_4th_oct_2017 by nikita teggi

Committer:
nikitateggi
Date:
Fri Feb 10 10:39:13 2017 +0000
Revision:
3:9a06c2bed650
Parent:
2:3b7b71bfc941
Child:
4:6bd81bb1790d
Peak detect to 400 samples

Who changed what in which revision?

UserRevisionLine numberNew contents of line
nikitateggi 0:c47fb0c1bbf6 1 #include "mbed.h"
nikitateggi 0:c47fb0c1bbf6 2 #include "ili9325.h"
nikitateggi 0:c47fb0c1bbf6 3 #include "lcd_base.h"
nikitateggi 0:c47fb0c1bbf6 4 #include "display_modules.h"
nikitateggi 0:c47fb0c1bbf6 5 #include "touch_modules.h"
nikitateggi 1:8316c23ec6b9 6 #include "rtc.h"
nikitateggi 3:9a06c2bed650 7 //#include "main.h"
nikitateggi 0:c47fb0c1bbf6 8
nikitateggi 0:c47fb0c1bbf6 9
nikitateggi 0:c47fb0c1bbf6 10 BusOut dataBus( PTC12, PTC13, PTB10, PTC9, PTD4, PTD5, PTD6, PTD7 ); // 16 pins//POC
nikitateggi 0:c47fb0c1bbf6 11 ILI9325_LCD lcd( PTC5, PTB9, PTC0, PTB0, &dataBus, NC, PTE31);
nikitateggi 0:c47fb0c1bbf6 12
nikitateggi 0:c47fb0c1bbf6 13
nikitateggi 1:8316c23ec6b9 14 void init_screen() // initializing the screen
nikitateggi 1:8316c23ec6b9 15 {
nikitateggi 1:8316c23ec6b9 16 lcd.Initialize(PORTRAIT);
nikitateggi 1:8316c23ec6b9 17 }
nikitateggi 0:c47fb0c1bbf6 18
nikitateggi 0:c47fb0c1bbf6 19 void screen_main()//main screen
nikitateggi 0:c47fb0c1bbf6 20 {
nikitateggi 1:8316c23ec6b9 21 char buff1[32];
nikitateggi 1:8316c23ec6b9 22 time_t epoch_time;
nikitateggi 1:8316c23ec6b9 23 lcd.ClearScreen();
nikitateggi 1:8316c23ec6b9 24 lcd.SetFont(&TerminusFont);
nikitateggi 1:8316c23ec6b9 25 epoch_time=rtc_read();
nikitateggi 1:8316c23ec6b9 26 sprintf(buff1 ,"%s", ctime(&epoch_time));
nikitateggi 1:8316c23ec6b9 27 lcd.Print( buff1,20,100,COLOR_YELLOW,COLOR_BLACK, 0);
nikitateggi 1:8316c23ec6b9 28 lcd.SetFont(&TerminusBigFont);
nikitateggi 1:8316c23ec6b9 29 lcd.Print( "SENSESEMI",50,20,COLOR_WHITE,COLOR_BLACK, 0);
nikitateggi 1:8316c23ec6b9 30 lcd.Print( "SenseSmart",45,60,COLOR_WHITE,COLOR_BLACK, 0);// align text to center horizontally and use starndard colors
nikitateggi 1:8316c23ec6b9 31 lcd.FillRoundRect(60,130,180,200,COLOR_YELLOW);
nikitateggi 1:8316c23ec6b9 32 lcd.Print( "SYS",100,140,COLOR_BLACK,COLOR_YELLOW,0);
nikitateggi 1:8316c23ec6b9 33 lcd.Print( "CONFIG",70,170,COLOR_BLACK,COLOR_YELLOW,0);
nikitateggi 1:8316c23ec6b9 34 lcd.FillRoundRect(60,230,180,300,COLOR_GREEN);
nikitateggi 1:8316c23ec6b9 35 lcd.Print( "TEST",90,250,COLOR_BLACK,COLOR_GREEN,0);
nikitateggi 3:9a06c2bed650 36
nikitateggi 3:9a06c2bed650 37 }
nikitateggi 1:8316c23ec6b9 38
nikitateggi 1:8316c23ec6b9 39 void screen_main_2(int pid)//main screen
nikitateggi 1:8316c23ec6b9 40 {
nikitateggi 1:8316c23ec6b9 41
nikitateggi 1:8316c23ec6b9 42 char buff2[10];
nikitateggi 3:9a06c2bed650 43
nikitateggi 1:8316c23ec6b9 44 lcd.FillRect(5,10,250,120,COLOR_BLACK);
nikitateggi 1:8316c23ec6b9 45 //lcd.Print( "SenseSmart", CENTER, 95);
nikitateggi 1:8316c23ec6b9 46 sprintf(buff2 ,"%d", pid);
nikitateggi 1:8316c23ec6b9 47 lcd.Print( "PATIENT ID",20,50,COLOR_YELLOW,COLOR_BLACK, 0);
nikitateggi 1:8316c23ec6b9 48 lcd.Print(buff2,200,50,COLOR_YELLOW,COLOR_BLACK, 0);
nikitateggi 1:8316c23ec6b9 49
nikitateggi 1:8316c23ec6b9 50 lcd.SetFont(&TerminusBigFont);
nikitateggi 3:9a06c2bed650 51 // lcd.FillRect(5,120,230,320,COLOR_BLACK);
nikitateggi 3:9a06c2bed650 52 lcd.FillRoundRect(60,130,180,200,COLOR_BLACK);
nikitateggi 3:9a06c2bed650 53 lcd.FillRoundRect(60,230,180,300,COLOR_BLACK);
nikitateggi 0:c47fb0c1bbf6 54 lcd.FillRoundRect(10,130,100,200,COLOR_CYAN);
nikitateggi 0:c47fb0c1bbf6 55 lcd.Print( "BG",40,160,COLOR_BLACK,COLOR_CYAN,0);
nikitateggi 0:c47fb0c1bbf6 56 lcd.FillRoundRect(130,130,220,200,COLOR_YELLOW);
nikitateggi 0:c47fb0c1bbf6 57 lcd.Print( "ECG",160,160,COLOR_BLACK,COLOR_YELLOW,0);
nikitateggi 0:c47fb0c1bbf6 58 lcd.FillRoundRect(10,215,100,285,COLOR_MAGENTA);
nikitateggi 0:c47fb0c1bbf6 59 lcd.Print( "BP",40,245,COLOR_BLACK,COLOR_MAGENTA,0);
nikitateggi 0:c47fb0c1bbf6 60 lcd.FillRoundRect(130,215,220,285,COLOR_GREEN);
nikitateggi 1:8316c23ec6b9 61 lcd.Print( "HOME",150,245,COLOR_BLACK,COLOR_GREEN,0);
nikitateggi 3:9a06c2bed650 62
nikitateggi 1:8316c23ec6b9 63 }
nikitateggi 1:8316c23ec6b9 64
nikitateggi 1:8316c23ec6b9 65
nikitateggi 0:c47fb0c1bbf6 66
nikitateggi 1:8316c23ec6b9 67 void screen_main_1()//main screen
nikitateggi 1:8316c23ec6b9 68 {
nikitateggi 3:9a06c2bed650 69
nikitateggi 1:8316c23ec6b9 70 lcd.SetFont(&TerminusBigFont);
nikitateggi 1:8316c23ec6b9 71 lcd.FillRect(5,127,230,320,COLOR_BLACK);
nikitateggi 1:8316c23ec6b9 72 lcd.FillRoundRect(10,130,100,200,COLOR_CYAN);
nikitateggi 1:8316c23ec6b9 73 lcd.Print( "BLE",30,160,COLOR_BLACK,COLOR_CYAN,0);
nikitateggi 1:8316c23ec6b9 74 lcd.FillRoundRect(130,130,220,200,COLOR_YELLOW);
nikitateggi 1:8316c23ec6b9 75 lcd.Print( "ERASE",140,160,COLOR_BLACK,COLOR_YELLOW,0);
nikitateggi 1:8316c23ec6b9 76 lcd.FillRoundRect(10,215,100,285,COLOR_MAGENTA);
nikitateggi 1:8316c23ec6b9 77 lcd.Print( "FILE",20,245,COLOR_BLACK,COLOR_MAGENTA,0);
nikitateggi 1:8316c23ec6b9 78 lcd.FillRoundRect(130,215,220,285,COLOR_GREEN);
nikitateggi 1:8316c23ec6b9 79 lcd.Print( "HOME",145,245,COLOR_BLACK,COLOR_GREEN,0);
nikitateggi 3:9a06c2bed650 80
nikitateggi 1:8316c23ec6b9 81 }
nikitateggi 0:c47fb0c1bbf6 82
nikitateggi 0:c47fb0c1bbf6 83
nikitateggi 0:c47fb0c1bbf6 84 void screen_ecg()
nikitateggi 0:c47fb0c1bbf6 85 {
nikitateggi 3:9a06c2bed650 86
nikitateggi 3:9a06c2bed650 87 // lcd.FillRect(5,127,230,320,COLOR_BLACK);
nikitateggi 3:9a06c2bed650 88
nikitateggi 3:9a06c2bed650 89 lcd.FillRoundRect(10,130,100,200,COLOR_BLACK);
nikitateggi 3:9a06c2bed650 90 lcd.FillRoundRect(130,130,220,200,COLOR_BLACK);
nikitateggi 3:9a06c2bed650 91 lcd.FillRoundRect(10,215,100,285,COLOR_BLACK);
nikitateggi 3:9a06c2bed650 92 lcd.FillRoundRect(130,215,220,285,COLOR_BLACK);
nikitateggi 3:9a06c2bed650 93
nikitateggi 1:8316c23ec6b9 94 lcd.FillRoundRect(60,130,180,200,COLOR_YELLOW);
nikitateggi 1:8316c23ec6b9 95 lcd.Print( "START",80,150,COLOR_BLACK,COLOR_YELLOW,0);
nikitateggi 1:8316c23ec6b9 96 // lcd.Print( "CONFIG",70,170,COLOR_BLACK,COLOR_YELLOW,0);
nikitateggi 1:8316c23ec6b9 97 lcd.FillRoundRect(60,230,180,300,COLOR_GREEN);
nikitateggi 1:8316c23ec6b9 98 lcd.Print( "RET",100,250,COLOR_BLACK,COLOR_GREEN,0);
nikitateggi 3:9a06c2bed650 99
nikitateggi 1:8316c23ec6b9 100 }
nikitateggi 1:8316c23ec6b9 101
nikitateggi 1:8316c23ec6b9 102
nikitateggi 0:c47fb0c1bbf6 103
nikitateggi 1:8316c23ec6b9 104 void screen_ecg_2()
nikitateggi 1:8316c23ec6b9 105 {
nikitateggi 3:9a06c2bed650 106
nikitateggi 3:9a06c2bed650 107 lcd.FillRect(5,90,230,150,COLOR_BLACK);
nikitateggi 3:9a06c2bed650 108 lcd.Print( " Tst is Done ",3,150,COLOR_GREEN,COLOR_BLACK,0);
nikitateggi 3:9a06c2bed650 109 // lcd.Print( "DONE", CENTER, 95);
nikitateggi 3:9a06c2bed650 110 // lcd.Print( "s Done ",80,150,COLOR_GREEN,COLOR_BLACK,0);
nikitateggi 3:9a06c2bed650 111 lcd.FillRect(10,215,230,290,COLOR_BLACK);
nikitateggi 3:9a06c2bed650 112 // lcd.FillRoundRect(10,215,100,285,COLOR_MAGENTA);
nikitateggi 3:9a06c2bed650 113 // lcd.FillRoundRect(130,215,220,285,COLOR_GREEN);
nikitateggi 1:8316c23ec6b9 114 lcd.FillRoundRect(60,230,180,300,COLOR_GREEN);
nikitateggi 1:8316c23ec6b9 115 lcd.Print( "RET",100,250,COLOR_BLACK,COLOR_GREEN,0);
nikitateggi 3:9a06c2bed650 116
nikitateggi 1:8316c23ec6b9 117 }
nikitateggi 1:8316c23ec6b9 118
nikitateggi 1:8316c23ec6b9 119
nikitateggi 0:c47fb0c1bbf6 120
nikitateggi 0:c47fb0c1bbf6 121 void screen_bp() // bp main screen
nikitateggi 0:c47fb0c1bbf6 122 {
nikitateggi 3:9a06c2bed650 123 lcd.FillRoundRect(10,130,100,200,COLOR_BLACK);
nikitateggi 3:9a06c2bed650 124 lcd.FillRoundRect(130,130,220,200,COLOR_BLACK);
nikitateggi 3:9a06c2bed650 125 lcd.FillRoundRect(10,215,100,285,COLOR_BLACK);
nikitateggi 3:9a06c2bed650 126 lcd.FillRoundRect(130,215,220,285,COLOR_BLACK);
nikitateggi 3:9a06c2bed650 127
nikitateggi 1:8316c23ec6b9 128 lcd.FillRoundRect(60,130,180,200,COLOR_YELLOW);
nikitateggi 1:8316c23ec6b9 129 lcd.Print( "START",80,150,COLOR_BLACK,COLOR_YELLOW,0);
nikitateggi 1:8316c23ec6b9 130 // lcd.Print( "CONFIG",70,170,COLOR_BLACK,COLOR_YELLOW,0);
nikitateggi 1:8316c23ec6b9 131 lcd.FillRoundRect(60,230,180,300,COLOR_GREEN);
nikitateggi 1:8316c23ec6b9 132 lcd.Print( "RET",100,250,COLOR_BLACK,COLOR_GREEN,0);
nikitateggi 3:9a06c2bed650 133
nikitateggi 3:9a06c2bed650 134 }
nikitateggi 3:9a06c2bed650 135
nikitateggi 3:9a06c2bed650 136 void screen_bp1(float SBP, float DBP) // bp main screen
nikitateggi 3:9a06c2bed650 137 {
nikitateggi 3:9a06c2bed650 138 lcd.FillRoundRect(3,130,200,200,COLOR_BLACK);
nikitateggi 3:9a06c2bed650 139 lcd.FillRoundRect(60,230,180,300,COLOR_BLACK);
nikitateggi 3:9a06c2bed650 140 char buf[10];
nikitateggi 3:9a06c2bed650 141 sprintf (buf, "SBP: %f",SBP);
nikitateggi 3:9a06c2bed650 142 lcd.Print( buf, 5,100,COLOR_CYAN,COLOR_BLACK, 0);
nikitateggi 3:9a06c2bed650 143 sprintf (buf, "DBP: %f",DBP);
nikitateggi 3:9a06c2bed650 144 lcd.Print( buf, 5,150,COLOR_CYAN,COLOR_BLACK, 0);
nikitateggi 3:9a06c2bed650 145 lcd.FillRoundRect(60,230,180,300,COLOR_GREEN);
nikitateggi 3:9a06c2bed650 146 lcd.Print( "RET",100,250,COLOR_BLACK,COLOR_GREEN,0);
nikitateggi 3:9a06c2bed650 147 }
nikitateggi 3:9a06c2bed650 148
nikitateggi 3:9a06c2bed650 149
nikitateggi 3:9a06c2bed650 150
nikitateggi 0:c47fb0c1bbf6 151
nikitateggi 0:c47fb0c1bbf6 152
nikitateggi 1:8316c23ec6b9 153 void screen_glc() // glc main screen
nikitateggi 0:c47fb0c1bbf6 154 {
nikitateggi 3:9a06c2bed650 155
nikitateggi 1:8316c23ec6b9 156 //lcd.FillRect(5,127,230,320,COLOR_BLACK);
nikitateggi 3:9a06c2bed650 157 // lcd.FillRect(5,127,230,320,COLOR_BLACK);
nikitateggi 3:9a06c2bed650 158 lcd.FillRoundRect(10,130,100,200,COLOR_BLACK);
nikitateggi 3:9a06c2bed650 159 lcd.FillRoundRect(130,130,220,200,COLOR_BLACK);
nikitateggi 3:9a06c2bed650 160 lcd.FillRoundRect(10,215,100,285,COLOR_BLACK);
nikitateggi 3:9a06c2bed650 161 lcd.FillRoundRect(130,215,220,285,COLOR_BLACK);
nikitateggi 1:8316c23ec6b9 162 lcd.FillRoundRect(60,130,180,200,COLOR_YELLOW);
nikitateggi 1:8316c23ec6b9 163 lcd.Print( "START",80,150,COLOR_BLACK,COLOR_YELLOW,0);
nikitateggi 1:8316c23ec6b9 164 lcd.FillRoundRect(60,230,180,300,COLOR_GREEN);
nikitateggi 1:8316c23ec6b9 165 lcd.Print( "RET",100,250,COLOR_BLACK,COLOR_GREEN,0);
nikitateggi 3:9a06c2bed650 166
nikitateggi 0:c47fb0c1bbf6 167 }
nikitateggi 0:c47fb0c1bbf6 168
nikitateggi 3:9a06c2bed650 169 void screen_bp2()
nikitateggi 3:9a06c2bed650 170 {
nikitateggi 3:9a06c2bed650 171
nikitateggi 3:9a06c2bed650 172
nikitateggi 3:9a06c2bed650 173 lcd.FillRoundRect(3,130,200,200,COLOR_BLACK);
nikitateggi 3:9a06c2bed650 174 lcd.FillRoundRect(60,230,180,300,COLOR_BLACK);
nikitateggi 3:9a06c2bed650 175 lcd.FillRect(5,215,230,290,COLOR_BLACK);
nikitateggi 3:9a06c2bed650 176
nikitateggi 0:c47fb0c1bbf6 177
nikitateggi 3:9a06c2bed650 178 }
nikitateggi 1:8316c23ec6b9 179
nikitateggi 1:8316c23ec6b9 180
nikitateggi 1:8316c23ec6b9 181 void ecg_countdown()
nikitateggi 1:8316c23ec6b9 182 {
nikitateggi 1:8316c23ec6b9 183 char tim1[5];
nikitateggi 3:9a06c2bed650 184
nikitateggi 3:9a06c2bed650 185 // lcd.DrawRect(20,90,90,40,COLOR_BLACK);
nikitateggi 3:9a06c2bed650 186 // lcd.FillRect(5,127,230,320,COLOR_BLACK);
nikitateggi 3:9a06c2bed650 187 lcd.FillRoundRect(3,130,200,200,COLOR_BLACK);
nikitateggi 3:9a06c2bed650 188 lcd.FillRoundRect(60,230,180,300,COLOR_BLACK);
nikitateggi 3:9a06c2bed650 189 lcd.FillRect(5,215,230,290,COLOR_BLACK);
nikitateggi 1:8316c23ec6b9 190 lcd.Print( "ECG starts in", CENTER, 95);
nikitateggi 1:8316c23ec6b9 191 for(int i=5;i>=0;i--)
nikitateggi 1:8316c23ec6b9 192 {
nikitateggi 1:8316c23ec6b9 193 wait(1);
nikitateggi 1:8316c23ec6b9 194 sprintf (tim1, "%d",i);
nikitateggi 1:8316c23ec6b9 195 lcd.Print( tim1,120,120,COLOR_YELLOW,COLOR_BLACK, 0);
nikitateggi 1:8316c23ec6b9 196
nikitateggi 1:8316c23ec6b9 197 }
nikitateggi 2:3b7b71bfc941 198 lcd.Print( "Tst in Progres",3,150,COLOR_GREEN,COLOR_BLACK,0);
nikitateggi 3:9a06c2bed650 199
nikitateggi 1:8316c23ec6b9 200 }
nikitateggi 1:8316c23ec6b9 201
nikitateggi 1:8316c23ec6b9 202
nikitateggi 1:8316c23ec6b9 203
nikitateggi 1:8316c23ec6b9 204 void screen_again()
nikitateggi 1:8316c23ec6b9 205 {
nikitateggi 3:9a06c2bed650 206
nikitateggi 1:8316c23ec6b9 207 //lcd.DrawRect(20,90,90,40,COLOR_BLACK);
nikitateggi 1:8316c23ec6b9 208 lcd.FillRect(5,127,230,200,COLOR_BLACK);
nikitateggi 1:8316c23ec6b9 209 lcd.Print( "Take test",50,130 ,COLOR_CYAN,COLOR_BLACK, 0);
nikitateggi 1:8316c23ec6b9 210 lcd.Print( "again?",75,160 ,COLOR_CYAN,COLOR_BLACK, 0);
nikitateggi 1:8316c23ec6b9 211 lcd.Print( "YES",30,245,COLOR_BLACK,COLOR_MAGENTA,0);
nikitateggi 1:8316c23ec6b9 212
nikitateggi 1:8316c23ec6b9 213 lcd.Print( " NO ",150,245,COLOR_BLACK,COLOR_GREEN,0);
nikitateggi 1:8316c23ec6b9 214 //lcd.FillRect(5 ,127,230,200,COLOR_BLACK);
nikitateggi 1:8316c23ec6b9 215 }
nikitateggi 1:8316c23ec6b9 216
nikitateggi 1:8316c23ec6b9 217
nikitateggi 1:8316c23ec6b9 218 void screen_glc_2()
nikitateggi 1:8316c23ec6b9 219 {
nikitateggi 3:9a06c2bed650 220
nikitateggi 1:8316c23ec6b9 221 lcd.FillRect(5,127,230,320,COLOR_BLACK);
nikitateggi 1:8316c23ec6b9 222
nikitateggi 0:c47fb0c1bbf6 223
nikitateggi 1:8316c23ec6b9 224 lcd.FillRoundRect(60,230,180,300,COLOR_GREEN);
nikitateggi 1:8316c23ec6b9 225 lcd.Print( "RET",100,250,COLOR_BLACK,COLOR_GREEN,0);
nikitateggi 3:9a06c2bed650 226
nikitateggi 1:8316c23ec6b9 227 }
nikitateggi 1:8316c23ec6b9 228
nikitateggi 1:8316c23ec6b9 229 void glc_1()
nikitateggi 1:8316c23ec6b9 230 {
nikitateggi 3:9a06c2bed650 231
nikitateggi 1:8316c23ec6b9 232 //lcd.ClearScreen();
nikitateggi 3:9a06c2bed650 233 // lcd.DrawRect(20,90,90,40,COLOR_BLACK);
nikitateggi 3:9a06c2bed650 234 // lcd.FillRect(5,127,230,320,COLOR_BLACK);
nikitateggi 3:9a06c2bed650 235 lcd.FillRoundRect(3,130,200,200,COLOR_BLACK);
nikitateggi 3:9a06c2bed650 236 lcd.FillRoundRect(60,230,180,300,COLOR_BLACK);
nikitateggi 3:9a06c2bed650 237 lcd.FillRect(5,215,230,290,COLOR_BLACK);
nikitateggi 1:8316c23ec6b9 238 lcd.Print( "BLOOD GLUCOSE",20,130 ,COLOR_CYAN,COLOR_BLACK, 0); // align text to center horizontally and use starndard colors
nikitateggi 1:8316c23ec6b9 239 lcd.Print( "Insert strip",5,160,COLOR_MAGENTA,COLOR_BLACK, 0); // align text to center horizontally and use starndard colors
nikitateggi 1:8316c23ec6b9 240 }
nikitateggi 1:8316c23ec6b9 241
nikitateggi 1:8316c23ec6b9 242 void glc_2()
nikitateggi 1:8316c23ec6b9 243 {
nikitateggi 3:9a06c2bed650 244
nikitateggi 1:8316c23ec6b9 245 lcd.Print( "Strip Detected",5,160, COLOR_GREEN,COLOR_BLACK, 0);
nikitateggi 1:8316c23ec6b9 246 lcd.Print( "Insert Blood",5,190,COLOR_RED,COLOR_BLACK, 0);
nikitateggi 1:8316c23ec6b9 247 }
nikitateggi 0:c47fb0c1bbf6 248
nikitateggi 1:8316c23ec6b9 249 void glc_3()
nikitateggi 1:8316c23ec6b9 250 {
nikitateggi 3:9a06c2bed650 251
nikitateggi 1:8316c23ec6b9 252 lcd.Print( "Blood Detected",5,190,COLOR_GREEN,COLOR_BLACK, 0);
nikitateggi 1:8316c23ec6b9 253 lcd.Print( "computing", 5,220,COLOR_MAGENTA,COLOR_BLACK, 0);
nikitateggi 1:8316c23ec6b9 254 }
nikitateggi 1:8316c23ec6b9 255
nikitateggi 1:8316c23ec6b9 256 void glc_4(unsigned int mgdl)
nikitateggi 1:8316c23ec6b9 257 {
nikitateggi 3:9a06c2bed650 258
nikitateggi 1:8316c23ec6b9 259 lcd.FillRect(5,127,230,320,COLOR_BLACK);
nikitateggi 1:8316c23ec6b9 260 char buf[10];
nikitateggi 2:3b7b71bfc941 261 sprintf (buf, "BG is %d mg/dl",mgdl);
nikitateggi 1:8316c23ec6b9 262 lcd.Print( buf, 5,100,COLOR_YELLOW,COLOR_BLACK, 0);
nikitateggi 1:8316c23ec6b9 263 }