Fork from ST-Expansion-Sw-Team Repo.
Dependencies: VL53L1X_mbed
Diff: XNucleo53L1A1.cpp
- Revision:
- 28:b3aa04ca507c
- Parent:
- 22:27f00d9b777b
--- a/XNucleo53L1A1.cpp Thu Oct 29 16:33:44 2020 +0000 +++ b/XNucleo53L1A1.cpp Mon Nov 02 14:09:59 2020 +0000 @@ -3,7 +3,7 @@ XNucleo53L1A1 *XNucleo53L1A1::_instance = NULL; -XNucleo53L1A1 *XNucleo53L1A1::instance(vl53L1X_DevI2C *ext_i2c) +XNucleo53L1A1 *XNucleo53L1A1::instance(VL53L1X_DevI2C *ext_i2c) { if (_instance == NULL) { _instance = new XNucleo53L1A1(ext_i2c); @@ -13,7 +13,7 @@ return _instance; } -XNucleo53L1A1 *XNucleo53L1A1::instance(vl53L1X_DevI2C *ext_i2c, +XNucleo53L1A1 *XNucleo53L1A1::instance(VL53L1X_DevI2C *ext_i2c, PinName gpio1_centre, PinName gpio1_left, PinName gpio1_right) { @@ -30,10 +30,10 @@ { int status, n_dev = 0; - sensor_centre->VL53L1_Off(); - sensor_left->VL53L1_Off(); - sensor_right->VL53L1_Off(); - status = sensor_centre->InitSensor(NEW_SENSOR_CENTRE_ADDRESS); + sensor_centre->vl53l1_off(); + sensor_left->vl53l1_off(); + sensor_right->vl53l1_off(); + status = sensor_centre->init_sensor(NEW_SENSOR_CENTRE_ADDRESS); if (status) { delete sensor_centre; delete xshutdown_centre; @@ -45,7 +45,7 @@ n_dev++; } - status = sensor_left->InitSensor(NEW_SENSOR_LEFT_ADDRESS); + status = sensor_left->init_sensor(NEW_SENSOR_LEFT_ADDRESS); if (status) { delete sensor_left; delete xshutdown_left; @@ -57,7 +57,7 @@ n_dev++; } - status = sensor_right->InitSensor(NEW_SENSOR_RIGHT_ADDRESS); + status = sensor_right->init_sensor(NEW_SENSOR_RIGHT_ADDRESS); if (status) { delete sensor_right; delete xshutdown_right;