From ad2c634fef72d3aa1ab9bc8b61f567bbde3be2c0 Mon Sep 17 00:00:00 2001 From: Davide QUARANTIELLO Date: Wed, 16 Sep 2026 17:07:24 +0200 Subject: [PATCH 1/3] wakeup component for powerdown --- README.md | 2 ++ .../LIS2DUXS12_Datalog_Terminal_I3C.ino | 6 ++++++ library.properties | 2 +- src/LIS2DUXS12Sensor.cpp | 2 +- src/LIS2DUXS12Sensor.h | 2 +- 5 files changed, 11 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index cc9c6bb..78c3ff1 100644 --- a/README.md +++ b/README.md @@ -29,6 +29,7 @@ An instance can be created and enabled when the SPI bus is used following the pr An instance can be created and enabled when the I3C bus is used with SETDASA (static-to-dynamic address assignment): LIS2DUXS12Sensor Accelero(&I3C, LIS2DUXS12_I3C_ADD_H); I3C.resetDynamicAddresses(); + I3C.isI3CDeviceReady(0x19); I3C.assignDynamicAddress(Accelero.getStaticAddress(), LIS2DUXS12_DYNAMIC_ADDRESS); Accelero.begin(LIS2DUXS12_DYNAMIC_ADDRESS); I3C.setClock(12500000); @@ -38,6 +39,7 @@ An instance can be created and enabled when the I3C bus is used with ENTDAA (dyn LIS2DUXS12Sensor Accelero(&I3C); I3C.begin(I3C_SDA, I3C_SCL, 1000000U); + I3C.isI3CDeviceReady(0x19); I3C.discover(devices, 8, &found); // find dynAddr by matching LIS2DUXS12_I3C_PID_H in discovered devices Accelero.begin(dynAddr); diff --git a/examples/LIS2DUXS12_Datalog_Terminal_I3C/LIS2DUXS12_Datalog_Terminal_I3C.ino b/examples/LIS2DUXS12_Datalog_Terminal_I3C/LIS2DUXS12_Datalog_Terminal_I3C.ino index 91995af..2d6c7c6 100644 --- a/examples/LIS2DUXS12_Datalog_Terminal_I3C/LIS2DUXS12_Datalog_Terminal_I3C.ino +++ b/examples/LIS2DUXS12_Datalog_Terminal_I3C/LIS2DUXS12_Datalog_Terminal_I3C.ino @@ -36,6 +36,12 @@ void setup() Serial.println("resetDynamicAddresses() failed"); while (1) {} } + + if (!I3C.isI3CDeviceReady(0x19)) { + Serial.println("isI3CDeviceReady() failed"); + while (1) {} + } + if (!I3C.assignDynamicAddress(sensor.getStaticAddress(), LIS2DUXS12_DYNAMIC_ADDRESS)) { Serial.println("assignDynamicAddress() failed"); while (1) {} diff --git a/library.properties b/library.properties index 5d4c25f..943585f 100644 --- a/library.properties +++ b/library.properties @@ -1,5 +1,5 @@ name=STM32duino LIS2DUXS12 -version=1.1.0 +version=1.1.1 author=SRA maintainer=stm32duino sentence=Ultra Low Power 3D accelerometer. diff --git a/src/LIS2DUXS12Sensor.cpp b/src/LIS2DUXS12Sensor.cpp index a208e15..f4d7226 100644 --- a/src/LIS2DUXS12Sensor.cpp +++ b/src/LIS2DUXS12Sensor.cpp @@ -2,7 +2,7 @@ ****************************************************************************** * @file LIS2DUXS12Sensor.cpp * @author STMicroelectronics - * @version V1.1.0 + * @version V1.1.1 * @date September 2026 * @brief Implementation of an LIS2DUXS12 Inertial Measurement Unit (IMU) 3 axes * sensor. diff --git a/src/LIS2DUXS12Sensor.h b/src/LIS2DUXS12Sensor.h index c0448f6..a63f526 100644 --- a/src/LIS2DUXS12Sensor.h +++ b/src/LIS2DUXS12Sensor.h @@ -2,7 +2,7 @@ ****************************************************************************** * @file LIS2DUXS12Sensor.h * @author STMicroelectronics - * @version V1.1.0 + * @version V1.1.1 * @date September 2026 * @brief Abstract Class of an LIS2DUXS12 Inertial Measurement Unit (IMU) 3 axes * sensor. From fe3c440f048684cd42667762d72dbddc78e13d21 Mon Sep 17 00:00:00 2001 From: Davide QUARANTIELLO Date: Thu, 17 Sep 2026 15:00:22 +0200 Subject: [PATCH 2/3] fix version in component --- src/LIS2DUXS12Sensor.cpp | 2 +- src/LIS2DUXS12Sensor.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/LIS2DUXS12Sensor.cpp b/src/LIS2DUXS12Sensor.cpp index f4d7226..a208e15 100644 --- a/src/LIS2DUXS12Sensor.cpp +++ b/src/LIS2DUXS12Sensor.cpp @@ -2,7 +2,7 @@ ****************************************************************************** * @file LIS2DUXS12Sensor.cpp * @author STMicroelectronics - * @version V1.1.1 + * @version V1.1.0 * @date September 2026 * @brief Implementation of an LIS2DUXS12 Inertial Measurement Unit (IMU) 3 axes * sensor. diff --git a/src/LIS2DUXS12Sensor.h b/src/LIS2DUXS12Sensor.h index a63f526..c0448f6 100644 --- a/src/LIS2DUXS12Sensor.h +++ b/src/LIS2DUXS12Sensor.h @@ -2,7 +2,7 @@ ****************************************************************************** * @file LIS2DUXS12Sensor.h * @author STMicroelectronics - * @version V1.1.1 + * @version V1.1.0 * @date September 2026 * @brief Abstract Class of an LIS2DUXS12 Inertial Measurement Unit (IMU) 3 axes * sensor. From 55c927ea5591029d2f46d67c7bede1637bc934e3 Mon Sep 17 00:00:00 2001 From: Davide QUARANTIELLO Date: Thu, 17 Sep 2026 15:45:10 +0200 Subject: [PATCH 3/3] fix readme --- README.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 78c3ff1..92c7d69 100644 --- a/README.md +++ b/README.md @@ -26,7 +26,8 @@ An instance can be created and enabled when the SPI bus is used following the pr Accelero.begin(); Accelero.Enable_X(); -An instance can be created and enabled when the I3C bus is used with SETDASA (static-to-dynamic address assignment): +An instance can be created and enabled when the I3C bus is used with SETDASA (static-to-dynamic address assignment): + LIS2DUXS12Sensor Accelero(&I3C, LIS2DUXS12_I3C_ADD_H); I3C.resetDynamicAddresses(); I3C.isI3CDeviceReady(0x19);