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

Revision:
22:ffa88619551d
Parent:
21:7ef1b0b40841
Child:
29:7edc76b15e3d
--- a/display_modules.cpp	Wed Jun 21 08:39:10 2017 +0000
+++ b/display_modules.cpp	Fri Jun 23 07:25:24 2017 +0000
@@ -65,7 +65,7 @@
      
     
     
-    void screen_main_2(int pid)     // test main screen
+    void screen_main_2(int32_t pid)     // test main screen
  {
     char buff2[10];     
     backlight = 0 ;
@@ -153,14 +153,14 @@
       
       
                 
- void screen_ecg_2(float heart_rate)   // ECG screen 2
+ void screen_ecg_2(uint16_t heart_rate)   // ECG screen 2
    {
     char buf[5];
     backlight = 0 ;
     TFT.BusEnable(true) ;
     TFT.background(White) ;
     TFT.foreground(Green) ;
-    sprintf (buf, "%.0f bpm",heart_rate);
+    sprintf (buf, "%d bpm",heart_rate);
     TFT.fillrect(5,90,230,150,White);  
     TFT.locate(3,100) ;  
     TFT.printf(" ECG Tst Done  ") ;   
@@ -495,5 +495,41 @@
     TFT.BusEnable(false) ;
     backlight = 1 ; 
    }
-   
+  
+  
+  void bat_screen_nocharge()
+   {
+        
+       /* lcd.FillRect(10,10,20,40,COLOR_RED); 
+       lcd.FillRect(5,127,230,200,COLOR_BLACK); 
+        lcd.FillRoundRect(60,230,180,300,COLOR_BLACK);
+        lcd.Print( "Low battery",60,130 ,COLOR_RED,COLOR_BLACK, 0);
+        lcd.Print( "Connect",60,160 ,COLOR_RED,COLOR_BLACK, 0);
+        lcd.Print( "Charger",30,205,COLOR_RED,COLOR_BLACK,0);      */
+        
+        backlight = 0 ;
+    TFT.BusEnable(true) ;
+     TFT.fillrect(10,10,20,40,Red);
+    TFT.fillrect(5,127,230,200,White);
+    TFT.fillrect(60,230,180,300,White);
+    TFT.locate(60,130) ;  
+    TFT.printf("Low battery") ;
+    
+    
+    
+         TFT.BusEnable(false) ;
+    backlight = 1 ; 
+          
+ } 
+    
+ void bat_screen_charge()
+   {
+        
+       // lcd.FillRect(10,10,20,40,COLOR_GREEN); 
+            backlight = 0 ;
+    TFT.BusEnable(true) ;
+     TFT.fillrect(10,10,20,40,Green);
+    TFT.BusEnable(false) ;
+    backlight = 1 ;    
+    }     
    
\ No newline at end of file