On-device ECG stress detection deployed on a resource-constrained ARM Cortex-M4 microcontroller

Continuous stress monitoring using wearable devices demands lightweight inference architectures that operate within the strict memory and power constraints of embedded microcontrollers. This study investigates on-device binary stress classification (stress vs. non-stress) from single-lead electrocardiogram (ECG) signals using two lightweight deep neural network architectures — an artificial neural network (ANN) and a one-dimensional convolutional neural network (1D-CNN) — deployed on an ARM Cortex-M4 microcontroller (STM32MP157F-DK2) with 128 KB FLASH and 256 KB SRAM. Using the WESAD dataset, ECG signals were down sampled to 500 Hz and segmented into balanced one-second windows. Models were iteratively optimised to satisfy hardware budgets and deployed via STM32Cube X-CUBE-AI with medium compression. The ANN (1500 input features, five hidden layers) achieved 78.74% test accuracy at 6.29 ms inference latency, while the 1D-CNN (500 input features, one convolutional and three fully connected layers) achieved 79.34% at 13.43 ms. End-to-end validation was performed using live ECG data acquired through an AD8232 sensor. Results demonstrate that clinically meaningful stress classification is achievable on resource-constrained platforms without cloud dependency, offering a practical pathway towards privacy-preserving wearable mental health monitoring.

Authors

Institutions

Publication Details

Journal
Discover Electronics
Published
2026-09-10
DOI
https://doi.org/10.1007/s44291-026-00279-8
Primary Topic
ECG Monitoring and Analysis
Type
article
Field-Weighted Citation Impact
0.00
Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
OCT
article

On-device ECG stress detection deployed on a resource-constrained ARM Cortex-M4 microcontroller

Hermawan Nugroho, Koay Xian Cong
Discover Electronics
ECG Monitoring and Analysis
article

On-device ECG stress detection deployed on a resource-constrained ARM Cortex-M4 microcontroller

Hermawan Nugroho, Koay Xian Cong
article en

Abstract

Continuous stress monitoring using wearable devices demands lightweight inference architectures that operate within the strict memory and power constraints of embedded microcontrollers. This study investigates on-device binary stress classification (stress vs. non-stress) from single-lead electrocardiogram (ECG) signals using two lightweight deep neural network architectures — an artificial neural network (ANN) and a one-dimensional convolutional neural network (1D-CNN) — deployed on an ARM Cortex-M4 microcontroller (STM32MP157F-DK2) with 128 KB FLASH and 256 KB SRAM. Using the WESAD dataset, ECG signals were down sampled to 500 Hz and segmented into balanced one-second windows. Models were iteratively optimised to satisfy hardware budgets and deployed via STM32Cube X-CUBE-AI with medium compression. The ANN (1500 input features, five hidden layers) achieved 78.74% test accuracy at 6.29 ms inference latency, while the 1D-CNN (500 input features, one convolutional and three fully connected layers) achieved 79.34% at 13.43 ms. End-to-end validation was performed using live ECG data acquired through an AD8232 sensor. Results demonstrate that clinically meaningful stress classification is achievable on resource-constrained platforms without cloud dependency, offering a practical pathway towards privacy-preserving wearable mental health monitoring.

Discover ElectronicsVol. 3(1)
University of Nottingham Malaysia Campus (MY)
Openalex Percentile: Top 10%
ECG Monitoring and Analysis
AI Navigator

Ask Laika to Summarize, Analyze, and Connect papers live on the map.

Summarize Papers & Methodologies

Extract key findings, datasets, and comparative methods across publications.

Benchmark Rankings & Visual Analytics

Rank top research institutions, authors, funders, topics, and journals by Field-Weighted Citation Impact (FWCI) and paper volume with instant charts.

Connect Distant Disciplines

Bridge topological clusters on the map to find hidden collaborative intersections.