Dreamforce 2014 Demo of RFID-based Salesforce Case generation for status reporting.

Dependencies:   ID12RFID ReportDB SalesforceCaseGenerator SalesforceInterface

Dependents:   mbed_mqtt_endpoint_ublox_ethernet mbed_mqtt_endpoint_ublox_cellular mbed_nsp_endpoint_ublox_cellular mbed_nsp_endpoint_ublox_ethernet ... more

Files at this revision

API Documentation at this revision

Comitter:
ansond
Date:
Tue Oct 07 22:12:19 2014 +0000
Parent:
22:17da4f0985dc
Commit message:
reset for exercise

Changed in this revision

StatusReporter.cpp Show annotated file Show diff for this revision Revisions of this file
diff -r 17da4f0985dc -r 324d739f9a22 StatusReporter.cpp
--- a/StatusReporter.cpp	Mon Oct 06 19:14:49 2014 +0000
+++ b/StatusReporter.cpp	Tue Oct 07 22:12:19 2014 +0000
@@ -25,8 +25,11 @@
  
  // ****************** DreamForce 2014 ******************// 
  
- // Temperature sensor - The TMP36 sensor uses A3 in the shield.. See Definitions.h for the define.
- AnalogIn tmp36_temp_sensor(TEMP_PIN);
+ // TEMP SENSOR - The TMP36 sensor uses A3 in the shield.. See Definitions.h for the define.
+ //
+ // Uncommnent the following line to bind to the TMP36 temperature sensor
+ //
+ // AnalogIn tmp36_temp_sensor(TEMP_PIN);
  
  // ****************** DreamForce 2014 ******************// 
  
@@ -41,15 +44,24 @@
  
  // Calculate the ambient temperature of the TMP36 sensor in C...
  int StatusReporter::getLocalTemperature() {
-     // Temperature sensor output voltage per TMP36 data sheet
+     // TEMP SENSOR: temperature calculation per TMP36 data sheet
      //
-     // Celcius temperature is calulated as follows:
+     // Celcius temperature is calculated as follows (with 3.3V input):
+     //
      //      tempC = ((temperature_sensor_voltage*3.3) - 0.6) * 100.0;
      //
-     //      Example: float tempC = (float)(((float)tmp36_temp_sensor*3.3)-0.600)*100.0;
+     // You can use the following code snippet:
+     // 
+     //      float tempC = (float)(((float)tmp36_temp_sensor*3.3)-0.600)*100.0;
+     //
+     // in place of:
+     // 
+     //      float tempC = 0.0;
+     // 
+     // to calculate the ambient temperature via the TMP36 sensor (in Celcius)
      //
      
-     float tempC = (float)(((float)tmp36_temp_sensor*3.3)-0.600)*100.0;
+     float tempC = 0.0;
      
      // DEBUG
      LOG_CONSOLE("Ambient Temp: %.1f C",tempC);