Ranging with the Time-of-Flight (ToF) sensors on the X-NUCLEO-53L1A1 expansion board, and 2 Satellite boards connected to the expansion board.
Dependencies: mbed X_NUCLEO_53L1A1_mbed
Revision 22:49949975c59b, committed 2019-07-24
- Comitter:
- johnAlexander
- Date:
- Wed Jul 24 12:53:28 2019 +0000
- Parent:
- 21:bb3dcf713446
- Commit message:
- Refactored init-sensor.
Changed in this revision
X_NUCLEO_53L1A1.lib | Show annotated file Show diff for this revision Revisions of this file |
main.cpp | Show annotated file Show diff for this revision Revisions of this file |
--- a/X_NUCLEO_53L1A1.lib Thu Jul 18 14:00:37 2019 +0000 +++ b/X_NUCLEO_53L1A1.lib Wed Jul 24 12:53:28 2019 +0000 @@ -1,1 +1,1 @@ -https://os.mbed.com/teams/ST-Expansion-SW-Team/code/X_NUCLEO_53L1A1_mbed/#24a73ef7469f +https://os.mbed.com/teams/ST-Expansion-SW-Team/code/X_NUCLEO_53L1A1_mbed/#0e99f593daa9
--- a/main.cpp Thu Jul 18 14:00:37 2019 +0000 +++ b/main.cpp Wed Jul 24 12:53:28 2019 +0000 @@ -34,7 +34,7 @@ #include "mbed.h" #include "XNucleo53L1A1.h" -#include "vl53L1x_I2c.h" +#include "VL53L1X_I2C.h" #define VL53L1_I2C_SDA D14 #define VL53L1_I2C_SCL D15 @@ -187,7 +187,7 @@ /* * Main ranging function */ -void range_measure(vl53L1X_DevI2C *device_i2c) +void range_measure(VL53L1X_DevI2C *device_i2c) { int status = 0; @@ -231,7 +231,7 @@ stop_button.rise(&switch_measuring_sensor_irq); stop_button.enable_irq(); - vl53L1X_DevI2C *dev_I2C = new vl53L1X_DevI2C(VL53L1_I2C_SDA, VL53L1_I2C_SCL); + VL53L1X_DevI2C *dev_I2C = new VL53L1X_DevI2C(VL53L1_I2C_SDA, VL53L1_I2C_SCL); range_measure(dev_I2C); // start continuous measures return 0;