Example to sweep a servo according to MEMS sensors position
Dependencies: Servo X_NUCLEO_IKS01A1 mbed
Fork of HelloWorld_IKS01A1 by
Diff: main.cpp
- Revision:
- 3:a2d2342526db
- Parent:
- 0:c71c9af137dd
- Child:
- 4:b1526d074d83
diff -r aa9679264ab0 -r a2d2342526db main.cpp --- a/main.cpp Mon Aug 17 10:18:05 2015 +0200 +++ b/main.cpp Mon Aug 31 12:07:22 2015 +0200 @@ -48,9 +48,9 @@ static MotionSensor *accelerometer = mems_expansion_board->GetAccelerometer(); static MagneticSensor *magnetometer = mems_expansion_board->magnetometer; static HumiditySensor *humidity_sensor = mems_expansion_board->ht_sensor; -static PressureSensor *pressure_sensor = mems_expansion_board->pressure_sensor; +static PressureSensor *pressure_sensor = mems_expansion_board->pt_sensor; static TempSensor *temp_sensor1 = mems_expansion_board->ht_sensor; -static TempSensor *temp_sensor2 = mems_expansion_board->pressure_sensor; +static TempSensor *temp_sensor2 = mems_expansion_board->pt_sensor; /* Helper function for printing floats & doubles */ static char *printDouble(char* str, double v, int decimalDigits=2)