Project Autus - Automated Plant Chamber

Dependencies:   TextLCD mbed

Fork of keypad_test by Plamen Totev

Autus

This is the codebase accompanying the project Autus.

Autus is an automated growth chamber for plants.

Features

Control Humidity inside chamber wrt to external humidity. Control Temperature inside chamber. ( Peltier Heaters/Coolers ) Water and shower plants. Control soil humidity. Monitor water tanks level (Load Cell) /media/uploads/umairaftab/frdm_-_new_page1.png

Code Base Features

Fixed timing and CRC for DHT-11 Sensor. Fixed OneWire bug for ds18b20

Cyclic Executive Scheduler with Priority. Async IPC framework for PC App over bluetooth

Fake RTC systick, I was having some trouble with the on board rtc.

/media/uploads/umairaftab/download.png

Revision:
4:8d1df60ef3c3
Parent:
3:087ce66714c0
Child:
5:bf31a58915a5
--- a/UI/ui.cpp	Wed Apr 09 18:26:03 2014 +0000
+++ b/UI/ui.cpp	Wed Apr 09 21:36:13 2014 +0000
@@ -1,11 +1,40 @@
 #include "mbed.h"
+#include "keypad.h"
+//#include "globalvalues.h"
 #include "ui.h"
-#include "keypad.h"
+#include "airhumidity.h" //for error variables
 
 char lcd_keypad_value ; 
+int temp_unit = 0; //0 for celcius 1 for faren 2 for kelvin 
+char temp_unit_char = 'C'; 
+
+float outside_humidity;
+float outside_temp;
+float outside_dewpoint;
+
+float inside_humidity;
+float inside_temp;
+float inside_dewpoint;
+
+float soil1_humidity;
+float soil2_humidity;
+
+//Set Temperature Unit
+void set_temp_unit(){
+    if(temp_unit == 1){
+        temp_unit_char = 'F';
+    }
+    else if(temp_unit == 2){
+        temp_unit_char = 'K';
+    }
+    else{
+        temp_unit_char = 'C';
+    }
+}
 
 void ui_startup(){
-    
+    set_temp_unit();
+    lcd.cls();
     lcd.setCursor(TextLCD::CurOff_BlkOn);
     lcd.locate(0,0);
     lcd.printf("Project Autus");
@@ -13,8 +42,15 @@
     lcd.printf("Initializing Machine");
 }
 
-void ui_menu() {
-    
-    
-    
-}
\ No newline at end of file
+void ui_screen1() {
+  
+    lcd.cls();
+    lcd.setCursor(TextLCD::CurOff_BlkOn);
+    lcd.locate(0,0);
+    lcd.printf("T: %3.1f%c",inside_temp,temp_unit_char);
+    lcd.printf(" H: %3.1f",inside_humidity);   
+    lcd.locate(0,1);
+    lcd.printf("S1: %3.1f",soil1_humidity);
+    lcd.printf(" S2: %3.1f",soil2_humidity);
+}
+