This is the assessment project

Dependencies:   C12832 FXOS8700Q LM75B mbed

Fork of app-shield-LM75B by Chris Styles

Committer:
co838_am2073
Date:
Mon Feb 22 09:03:00 2016 +0000
Revision:
10:5cf5a731af73
Parent:
9:b14eedf2e34b
More options, update rate controll, and comments in code

Who changed what in which revision?

UserRevisionLine numberNew contents of line
co838_am2073 10:5cf5a731af73 1 /**
co838_am2073 10:5cf5a731af73 2 * This project is using the following inputs:
co838_am2073 10:5cf5a731af73 3 * - SW2 Button (right): Used to navigate between the different states (views)
co838_am2073 10:5cf5a731af73 4 * - SW3 Button (left): Used to change the state mode -if the state has another mode-
co838_am2073 10:5cf5a731af73 5 * - POT1 Potentiometer (left): Used to change the update rate (in seconds)
co838_am2073 10:5cf5a731af73 6 *
co838_am2073 10:5cf5a731af73 7 * The project is constructed around one class: Core.
co838_am2073 10:5cf5a731af73 8 * This class will manage the inputs, and the different states
co838_am2073 10:5cf5a731af73 9 * (I am using a state machine, based on the state ID, and the function pointer of this state).
co838_am2073 10:5cf5a731af73 10 * The states functions are called state*StateName*.
co838_am2073 10:5cf5a731af73 11 *
co838_am2073 10:5cf5a731af73 12 * The current states are:
co838_am2073 10:5cf5a731af73 13 * - Temperature state
co838_am2073 10:5cf5a731af73 14 * => This state has 2 modes (SW3 Button to switch): Celsius or Fahrenheit temperature
co838_am2073 10:5cf5a731af73 15 * - Accelerometer state
co838_am2073 10:5cf5a731af73 16 * - Magnetometer state
co838_am2073 10:5cf5a731af73 17 *
co838_am2073 10:5cf5a731af73 18 * All the outputs are done on the shield LCD.
co838_am2073 10:5cf5a731af73 19 *
co838_am2073 10:5cf5a731af73 20 * The documentation for each methods is defined in the core.h file
co838_am2073 10:5cf5a731af73 21 */
co838_am2073 9:b14eedf2e34b 22 #include "core.h"
okano 0:ce7a8546502b 23
chris 2:9e757151de9b 24 int main ()
okano 0:ce7a8546502b 25 {
co838_am2073 9:b14eedf2e34b 26 Core core;
co838_am2073 9:b14eedf2e34b 27 core.init();
co838_am2073 9:b14eedf2e34b 28 while (true)
co838_am2073 9:b14eedf2e34b 29 {
co838_am2073 9:b14eedf2e34b 30 core.update();
chris 2:9e757151de9b 31 }
okano 0:ce7a8546502b 32 }