Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: mbed X_NUCLEO_53L1A1_mbed
Diff: main.cpp
- Revision:
- 21:37399a49b40e
- Parent:
- 20:0aa91eb13b8f
- Child:
- 22:e811600253b0
--- a/main.cpp Thu Jul 18 13:35:15 2019 +0000
+++ b/main.cpp Thu Jul 18 14:12:25 2019 +0000
@@ -123,11 +123,13 @@
=============================================================================*/
int main()
{
-#if TARGET_STM
- #if USER_BUTTON==PC_13 // we are cross compiling for an STM32-Nucleo
- InterruptIn stop_button(USER_BUTTON);
- stop_button.rise(&measuring_stop_irq);
- #endif
+#if TARGET_STM // we are cross compiling for an STM32-Nucleo
+ InterruptIn stop_button(USER_BUTTON);
+ stop_button.rise(&measuring_stop_irq);
+#endif
+#if TARGET_Freescale // we are cross-compiling for NXP FRDM boards.
+ InterruptIn stop_button(SW2);
+ stop_button.rise(&measuring_stop_irq);
#endif
vl53L1X_DevI2C *device_i2c = new vl53L1X_DevI2C(VL53L1_I2C_SDA, VL53L1_I2C_SCL);
range_measure(device_i2c); // start continuous measures