Introduction
This application note describes the LC sensor metering feature included in the STM32U5 Nucleo board NUCLEO-U575ZI-Q.
The STM32U5 Series microcontrollers combine ultra-low-power with performance, offering a complete set of analog and digital
peripherals. These peripherals can operate in autonomous mode down to Stop 2 mode, a subset of which is used to build
the LC sensorbased meter. This is the starting point for the implementation of gas or water meter applications, based on the
inductive reading of a rotating mechanical wheel.
The demonstration based on the STM32U5 can be executed with a single USB cable (type A to B) connecting the host PC to
the NUCLEO-U575ZI-Q, and a custom LC sensor board.
This application note is delivered with the X-CUBE-LCSENSOR expansion package dedicated to STM32U5xx microcontrollers
using the STM32CubeMX (6.6.1) tool with the LPBAM interface.
LC sensor metering implementation on STM32U5 Series featuring LPBAM
AN5834
Application note
AN5834 - Rev 1 - December 2022
For further information contact your local STMicroelectronics sales office.
www.st.com
1 General information
The STM32U5 Series microcontrollers are based on the Arm
®
Cortex
®
-M33 processor.
Note: Arm is a registered trademark of Arm Limited (or its subsidiaries) in the US and/or elsewhere.
Table 1. Acronyms and terms
Acronym Definition Description
Vmid
Middle voltage (V
DD
/2)
It allows energizing LC sensor. It is delivered by
DAC peripheral output for STM32U5. To save power
consumption, Vmid is disabled when the LC sensor is not
activated.
Vcmp Comparator threshold voltage It is set above Vmid to provide a noise margin.
Texcit Excitation pulse width It allows driving LC sensor in output push-pull.
Tcapture Time to perform the measurement
During this time, the comparator collects oscillations,
compares them to Vcmp and delivers pulses to the low
power timer.
Count Pulse count number
It is generated by the LC sensor and conditioned by the
comparator.
CountDetect
Detection threshold for the count
number
It allows defining the sensor state (metal or no metal).
CountMax
Maximum number of counted pulses,
without metal, in proximity of the LC
sensor
-
CountMin
Minimum number of counted pulses,
with metal, in proximity of the LC
sensor
-
Reference documents
[1]
Application note Demonstration of LC sensor for gas or water metering based on STM32L073Z
EVAL and
STM32L476RG
NUCLEO boards (AN4636)
[2] Application note How to build STM32 LPBAM application using STM32CubeMX (AN5816)
AN5834
General information
AN5834 - Rev 1
page 2/60