🏆
Global Engineering Publisher
Serving Researchers Since 2012

AI Driven Exercise Prescription for Chronic Low Back Pain Using Wearable Sensors

DOI : 10.17577/IJERTCONV14IS060114
Download Full-Text PDF Cite this Publication

Text Only Version

AI Driven Exercise Prescription for Chronic Low Back Pain Using Wearable Sensors

Neha Vinod P1

1 Undergraduate student, Department of Biomedical Engineering,

ACS College of Engineering

pnehavinod@gmail.com

Umrana Laeeqh4

4 Undergraduate student, Department of Biomedical Engineering,

ACS College of Engineering umranalaeeqh13@gmail.com

Anusha M2

2 Undergraduate student, Department of Biomedical Engineering,

ACS College of Engineering anushamallesh2203@gmail.com

Dr. Hariharasudhan V. G.5

5Associate Professor Department of Biomedical Engineering

ACS College of Engineering hariinstru88@gmail.com

Sapna G R3

3 Undergraduate student, Department of Biomedical Engineering,

ACS College of Engineering

grsapna23@gmail.com

Abstract Chronic Low Back Pain (CLBP) is one of the most common musculoskeletal disorders and often requires continuous monitoring and guided rehabilitation. Traditional physiotherapy provides effective supervision only in clinical settings, making it difficult for patients to maintain correct posture and exercise form at home. This paper presents an AI- driven wearable rehabilitation system that integrates multi- sensor data acquisition, IoT communication, and cloud-based machine learning to support personalized exercise guidance for individuals with CLBP. The system uses an ESP32 microcontroller connected to EMG, MPU6050, MAX30100, pulse, and temperature sensors to capture muscle activity, posture dynamics, and physiological responses in real time. All measurements are displayed locally and uploaded to the ThingSpeak cloud, where machine learning models and threshold-based decision rules identify posture deviations, muscle fatigue, and exertion levels. The system provides real- time corrective feedback and automated exercise recommendations to enable safe home-based physiotherapy. Experimental results show reliable sensor performance and high predictive accuracy, with the Random Forest model achieving 97.5% accuracy. The proposed solution offers a low- cost, non-invasive, and portable platform for intelligent rehabilitation, supporting patient self-management and remote physiotherapist monitoring.

Keywords Chronic low back pain, wearable sensors, Internet of Things (IoT), machine learning, rehabilitation system, posture monitoring.

  1. Introduction

    Chronic Low Back Pain (CLBP) remains one of the most common conditions affecting mobility, daily activities, and overall quality of life. Sedentary lifestyles, long working hours, and incorrect posture habits have contributed to a steady increase in the number of individuals experiencing persistent back discomfort. Although exercise-based physiotherapy is widely recommended, its success depends on how accurately patients perform the prescribed movements. Without supervision, many people unknowingly adopt incorrect techniques, which can delay recovery or even intensify existing pain.

    Recent advances in wearable sensors and IoT technologies have made it possible to observe movement patterns and physiological responses outside hospital or clinical environments. Studies have shown that devices such

    as inertial measurement units (IMUs) can track posture, surface EMG sensors can capture muscle activation, and optical sensors can monitor cardiovascular behavior. While these systems provide useful information, most of them mainly function as monitoring tools and do not give real- time, personalized feedback to help patients correct themselves during exercise.

    To overcome these limitations, this work presents an AI- driven exercise support system designed for individuals with CLBP. The wearable setup gathers multiple signals EMG for muscle effort, MPU6050 for spinal orientation, MAX30100 for heart-rate and SpO readings, along with temperature and pulse measurements. An ESP32 microcontroller manages the data collection and wirelessly transmits it to the ThingSpeak cloud. Machine-learning analysis (Random Forest), supported by clinically inspired threshold rules, is then applied to detect posture deviations, early signs of fatigue, and abnormal exertion levels. Based on this analysis, the system provides simple, immediate on-screen feedback to help users maintain proper form even during unsupervised home sessions.

    The key contributions of this study include:

    1. Development of a compact wearable system combining multiple IoT sensors for CLBP rehabilitation.

    2. Use of cloud-based processing to interpret biomechanical and physiological data.

    3. Integration of an AI-assisted recommendation layer for corrective exercise support.

    4. Prototype evaluation demonstrating reliable sensing, meaningful predictions, and practical usability.

    Overall, this system seeks to improve home rehabilitation by offering timely, actionable guidance to patients while enabling physiotherapists to monitor progress more effectively.

  2. Related Work

    A wide range of studies has examined sensor-assisted rehabilitation and intelligent monitoring systems for musculoskeletal conditions, particularly Chronic Low Back Pain (CLBP). Sampathrajan et al. [1] presented an IoT-

    based posture-correction framework that used Bayesian networks to estimate injury-risk conditions. Their findings showed that posture deviations can be detected using simple sensor inputs; however, the system did not include physiological or muscular measurements, limiting its ability to evaluate fatigue or exertion during exercise.

    Cortell-Tormo et al. [2] developed Lumbatex, a wearable platform that uses inertial measurement units (IMUs) to track lumbar spine movement with considerable precision. Although the system performed well for motion analysis, it was designed mainly for controlled laboratory settings and did not incorporate additional physiological signals such as EMG or heart-rate data, reducing its usefulness for comprehensive rehabilitation feedback. Similar IMU-based studies primarily focus on identifying kinematic abnormalities, offering limited insight into the users overall physiological condition.

    Several researchers have also explored machine-learning approaches for back-pain assessment. Alahakone et al. [3] modeled CLBP risk factors using demographic and clinical datasets. Their approach achieved competitive prediction accuracy but lacked real-time sensing, making it unsuitable for continuous rehabilitation support or feedback during exercise performance.

    More recent work highlights the benefit of multimodal sensingparticularly systems that fuse EMG and IMU datato improve posture classification and fatigue detection accuracy [4]. Despite their advantages, these systems are often constrained to offline evaluations or controlled experiments and do not typically integrate cloud analytics or automated, personalized exercise recommendations.

    The system proposed in this paper builds upon these foundational studies by combining multiple wearable sensors (EMG, IMU, heart-rate/SpO, and temperature) with cloud-based machine learning to deliver real-time rehabilitation assistance. Unlike earlier solutions, this work emphasizes continuous monitoring, on-device feedback, and personalized guidance, making it more suitable for home- based CLBP management.

  3. System Design and Methodology

  1. System Overview

    The proposed system is a wearable IoT-based rehablitation platform designed to assist individuals with Chronic Low Back Pain (CLBP). It integrates multiple physiological and biomechanical sensors with an ESP32 microcontroller to continuously monitor muscle activity, posture, heart rate, oxygen saturation, and body temperature. The collected data is processed in real time and transmitted to the ThingSpeak cloud for further machine-learning analysis and exercise recommendation.

  2. Hardware Architecture

    The hardware setup consists of the ESP32 microcontroller connected to:

    1. EMG sensor monitors lumbar muscle activation and early fatigue signals.

    2. MPU6050 IMU measures trunk posture and movement through accelerometer and gyroscope data.

    3. MAX30100 pulse oximeter records heart rate and

      SpO levels during exercise.

    4. Temperature sensor detects changes in body temperature related to exertion.

    5. LCD display provides real-time feedback to the user.

      All sensors are powered through a portable Li-ion battery, ensuring a lightweight, wearable design suitable for home-based physiotherapy.

  3. Sensor Data Acquisition

    Each sensor captures data at appropriate sampling rates:

    1. EMG at 1000 Hz

    2. MPU6050 at 100 Hz

    3. MAX30100 at 25100 Hz

    4. Temperature at 15 Hz

      The ESP32 reads analog/digital signals, applies basic filtering, rectification (for EMG), and sensor fusion (for IMU) before displaying the values on the LCD.

  4. Cloud Connectivity and Data Transmission

    The ESP32s built-in Wi-Fi module is used to transmit sensor readings to the ThingSpeak cloud at fixed intervals. ThingSpeak serves as a remote data repository and provides MATLAB-based analytical tools to process incoming time- series signals. This architecture enables remote access, visualization, and real-time monitoring.

  5. Data Preprocessing and Feature Extraction

    Raw sensor data is cleaned and processed to generate meaningful features:

    1. EMG: RMS value, muscle activation level, fatigue index.

    2. IMU: trunk inclination angle, angular velocity, stability metrics.

    3. Physiological sensors: HRV, SpO trends,

      temperature rise during exertion.

      These extracted features form the dataset used for machine-learning model training and prediction.

  6. Machine Learning Model and Prediction Pipeline

    Machine-learning models deployed on the ThingSpeak MATLAB engine analyze multi-sensor features to:

    1. Detect posture deviations

    2. Predict muscle fatigue

    3. Identify overexertion

    4. Estimate risk of incorrect exercise performance

      Models evaluated include Random Forest, SVM, Decision Tree, Naïve Bayes, and KNN, with Random Forest showing the highest overall performance.

  7. Exercise Recommendation Engine

    Based on ML predictions, the system provides customized exercise guidance such as:

    1. Corrective posture cues

    2. Intensity adjustments

    3. Rest intervals

    4. Safety notifications

Real-time recommendations are displayed directly on the LCD, making the system usable without clinician supervision.

Fig. 1. Overall System Architecture and Workflow

*Fig. 1 shows the overall architecture of the proposed wearable rehabilitation system. The framework consists of three major stages: multi-sensor data acquisition, ESP32- based edge processing, and cloud-assisted AI/ML analysis for exercise recommendations.

Iv. Hardware And Software Implementation

  1. Hardware Components

    The proposed wearable rehabilitation system integrates multiple biomedical and motion-tracking sensors with an ESP32 microcontroller. Each component contributes a specific physiological or biomechanical measurement essential for assessing Chronic Low Back Pain (CLBP).

    1. EMG Sensor

      Measures lumbar muscle activation by detecting surface electrical activity. Used to identify muscle fatigue, abnormal activation patterns, and exertion level.

    2. MPU6050 IMU (Accelerometer + Gyroscope)

      Captures posture, trunk bending angles, and movement dynamics. Essential for detecting improper bending, twisting, or rapid movements.

    3. MAX30100 (Heart Rate + SpO)

      Provides continuous measurement of heart rate and oxygen saturation. Helps assess cardiovascular stress and early signs of overexertion.

    4. Temperature Sensor

      Monitors body-surface temperature variations to detect signs of stress, fatigue, or inflammation.

    5. ESP32 Microcontroller

      Acts as the edge-processing unit and communication hub. Performs sensor reading, preprocessing, real-time LCD feedback, and Wi-Fi-based cloud upload.

    6. LCD Display (16×2 or I2C)

      Provides instant on-device feedback including posture alerts, fatigue warnings, and exercise prompts.

  2. Software Components

    1. Firmware Logic (ESP32)

      The microcontroller executes:

      • Continuous multi-sensor sampling

      • Filtering & smoothing

      • Feature extraction (EMG RMS, trunk angle, heart rate)

      • LCD feedback generation

      • Wi-Fi data upload every 1520 seconds

    2. ThingSpeak Cloud Platform

      Used for:

      • Data storage

      • Time-series visualization

      • MATLAB-based ML model execution

      • API communication with the wearable device

    3. Machine Learning Models

      Multiple ML algorithms (KNN, SVM, Naïve Bayes, Decision Tree, Random Forest) were trained and evaluated for classifying:

      • Posture categories

      • Muscle fatigue levels

      • Exertion risk levels

        Random Forest achieved the best overall performance and was chosen for deployment.

  3. Data Flow

    1. Sensors capture EMG, posture, heart-rate, SpO,

      and temperature.

    2. ESP32 preprocesses and displays instant feedback.

    3. Data is transmitted to ThingSpeak for cloud-side ML analysis.

    4. The ML model classifies user condition and returns exercise recommendations.

    5. ESP32 displays actionable prompts to the user.

  1. Results

    1. Sensor Data Correlation Analysis

      A correlation heatmap was generated to study relationships between physiological and biomechanical parameters.

      Fig. 2. Correlation Heatmap

      Fig. 2 shows that: EMG is strongly negatively correlated with heart rate (0.77) and blood pressure 0.70), indicating

      that fatigue-related EMG spikes often coincide with cardiovascular stress. SpO shows moderate positive correlation with EMG (0.66), suggesting improved oxygenation during stable muscle engagement. Temperature exhibits low-to-moderate correlation with other features, behaving as an independent stress indicator.

      These correlations validate that multiple sensors contribute complementary information, strengthening the systems ability to detect posture issues, fatigue, and overexertion.

    2. Machine Learning Model Performance

      Five ML algorithms were evaluated for classifying the

      users physical condition based on extracted features.

      TABLE I. ML MODEL PERFORMANCE

      Key Observations:

      • Random Forest outperformed all models across all metrics.

      • Decision Tree also showed strong performance, but with slightly lower generalization.

      • KNN and Naïve Bayes performed well but were more sensitive to noisy EMG data.

        Random Forest was selected as the final model for deployment due to its robustness, highest accuracy, and stable classification of posture and fatigue levels.

    3. Random Forest Confusion Matrix Analysis

      The confusion matrix (Fig.3) demonstrates the classification performance across three conditions: Normal, High, and Low.

      Fig. 3. Random Forest Confusion Matrix

      Key Points:

      • The Random Forest classifier achieved very high class-wise accuracy, correctly identifying 97.5% of

        High, 100% of Low, and 95% of Normal conditions.

      • Misclassifications were minimal and occurred only between Normal and Low, indicating borderline physiological values near threshold limits.

      • No High cases were misclassified as Normal or Low, demonstrating strong sensitivity for detecting fatigue/overexertion.

      • Low-condition recognition was perfect, showing the models reliability in identifying under exertion or weak muscle activation.

      • Overall, the model maintains balanced performance across all classes, making it suitable for real-time rehabilitation monitoring and corrective feedback.

        TABLE II. THRESHOLD RANGES

        Table. II. Shows the threshold ranges used for classifying physiological and biomechanical parameters into Low, Normal, and High conditions for AI-based exercise recommendation. These thresholds combine clinical reference values and dataset-specific variations to support reliable decision-making during rehabilitation.

        The threshold limits for each physiological parameter were determined by combining clinical reference ranges with observations from the collected dataset. For EMG signals, raw amplitude distributions from the prototype testing showed three natural groupings (<1000, 10002500, and

        >2500), which aligned with clinical interpretations of weak activation, normal contraction, and early fatigue. Similarly, thresholds for SpO, heart rate, blood pressure, and temperature were selected based on widely accepted physiological norms and rehabilitation guidelines. These ranges were cross-checked against values reported in existing literature on CLBP rehabilitation to ensure that the system identifies deviations that are both statistically meaningful and clinically relevant. By grounding the thresholds in both empirical data and established biomedical standards, the system is able to provide stable and interpretable decision outputs that complement the machine-learning predictions.

    4. Real-Time System Testing

      The prototype was tested on multiple users performing controlled rehabilitation exercises.

      Observations:

      • Posture detection was accurate and responded quickly to deviations in trunk angle.

      • EMG fatigue detection was consistent with expected muscle activation patterns.

      • Heart rate and SpO readings matched standard medical-grade devices within acceptable error margins.

      • LCD feedback was immediate and helped users self-correct movements during testing.

      • Cloud upload intervals (1520 sec) worked smoothly without packet loss.

    This confirms that the system performs reliably in real- world rehabilitation scenarios.

  2. Discussion

    The results indicate that combining EMG, IMU, heart- rate, SpO, and temperature inputs provides a more dependable understanding of posture quality, exertion, and muscle fatigue during rehabilitation exercises. Among the evaluated models, the Random Forest classifier achieved the best performance, reaching 97.5% accuracy, with high precision and recall across all activity classes. The confusion matrix further confirmed that posture categories and exertion states were identified with minimal misclassification. These findings show that multi-sensor fusion captures complementary biomechanical and physiological patterns that single-sensor systems often miss. Real-time tests also demonstrated that the ESP32 responded consistently, delivering timely LCD feedback and maintaining stable uploads to the cloud during movement.

    Alongside the ML outputs, threshold conditions played an important role in identifying unsafe or inefficient exercise execution. EMG values rising beyond 2500 (raw sensor range) signaled potential fatigue or excessive load, while SpO falling below 92%, heart rate exceeding 120 bpm, and temperature readings above 38°C indicated physiological strain. These thresholds allowed the system to provide immediate corrective prompts, supporting safer home-based rehabilitation.

    Despite promising results, overall performance was influenced by real-world factors such as electrode placement, variations in user posture, and fluctuations in Wi-Fi connectivity during data transfer. The machine-learning component was evaluated on a limited dataset, and broader data collection would likely improve model robustness. Even with these constraints, the outcomes demonstrate that a cloud-connected, AI-supported wearable platform can reliably augment conventional physiotherapy and provide personalized, real-time guidance for individuals managing chronic low back pain.

  3. Conclusion

    This This work presents a wearable, AI-driven rehabilitation system designed to assist individuals with Chronic Low Back Pain (CLBP) by providing continuous monitoring and personalized exercise guidance. The integration of EMG, IMU, MAX30100, and temperature sensors with an ESP32 microcontroller enables real-time capture of muscle activation, posture motion, cardiovascular response, and exertion-related temperature changes. The collected multi-sensor signals are processed locally and transmitted to the ThingSpeak cloud, where machine- learning models evaluate patterns related to posture deviation, muscle fatigue, and exertion levels. Among all the classifiers tested, the Random Forest model achieved the highest performance, reaching 97.5% accuracy, demonstrating consistent precision across all activity classes

    and outperforming KNN, SVM, Naïve Bayes, and Decision Tree approaches.

    To enhance decision reliability, the system also incorporates threshold-based conditions for each physiological parameterfor example, EMG value less than 1000 (low), 10002500 (normal), and greater than 2500 (high), along with clinically informed ranges for SpO, heart rate, blood pressure, and temperature. These thresholds allow the device to flag under-exertion, normal effort, or possible fatigue and overexertion, complementing the machinelearning predictions and enabling a stable, hybrid decision-making process.

    Real-time testing demonstrated that the system provides immediate and meaningful feedback through the wearable LCD, enabling users to correct their posture or reduce exertion without requiring direct clinical supervision. While practical challenges such as sensor placement accuracy and network fluctuations may influence overall performance, the results consistently show that this low-cost, portable solution can support safer and more effective home-based rehabilitation. Overall, the proposed system highlights the potential of combining IoT sensing, cloud analytics, and AI to make CLBP rehabilitation more personalized, accessible, and clinically meaningful.

  4. Future Scope

The proposed system can be further enhanced by integrating more advanced bio-signals such as ECG, respiration rate, or muscle stiffness measurements to provide a deeper understanding of user exertion and recovery patterns. Incorporating on-device machine learning using Tiny ML or edge AI accelerators would reduce cloud dependency and improve real-time responsiveness, making the system more suitable for rural or low-connectivity environments. Additionally, expanding the dataset with recordings from a larger clinical population would allow the models to improve accuracy, personalization, and generalizability across age groups and severity levels.

Future work may also include developing a mobile application that synchronizes sensor data, visualizes trends, and offers personalized rehabilitation plans with real-time alerts. Gamification-based interfaces or VR/AR-guided exercise modules could further improve engagement and adherence to rehabilitation routines. Finally, clinical trials conducted with physiotherapists and rehabilitation centers would help validate the systems medical reliability, enabling its transition into a certified healthcare product for home-based, AI-supported physical therapy.

Acknowledgment

The authors gratefully acknowledge the support of the Department of Biomedical Engineering, ACS College of Engineering, Bengaluru, India, for providing constant guidance, valuable feedback, and continuous encouragement throughout the development of this project. The authors also thank the faculty members and laboratory staff for their technical support and for providing the required facilities to carry out the hardware integration and testing phases.

References

  1. R. Sampathrajan, V. Krishnamoorthy, and P. Kumar, IoT-driven posture correction for chronic back pain mitigation using Bayesian networks, in Proc. IEEE Int. Conf. Commun. Signal Process. (ICCSP), 2025.

  2. J. M. Cortell-Tormo, M. García-Jaén, D. Ruiz-Fernández, and V. Fuster-Lloret, Lumbatex: A wearable

    monitoring system based on inertial sensors to measure and control lumbar spine motion, IEEE Trans. Neural Syst. Rehabil. Eng., vol. 27, no. 5, pp. 11201130, 2019.

  3. N. Alahakone and S. Senanayake, EMG-based feedback system for monitoring muscle activation during rehabilitation exercises, IEEE Trans. Biomed. Eng., vol. 66, no. 4, pp. 11201130, 2019.

  4. Y. Wang, L. Chen, and H. Zhao, Combination of EMG and IMU sensors for exercise posture classification using machine learning, IEEE J. Biomed. Health Inform., vol. 26, no. 5, pp. 23012312, 2022.

  5. F. Pistolesi and B. Lazzerini, Assessing the risk of low back pain and injury via inertial and barometric sensors, IEEE Trans. Ind. Informat., vol. 16, no. 11, pp. 71997208, 2020.

  6. K. Sundaram, M. Ramesh, and P. Singh, AI-driven rehabilitation assistant using physiological signals for personalized exercise guidance, IEEE Trans. Neural Syst. Rehabil. Eng., vol. 28, pp. 18021812, 2020.

  7. A. Seth, A. James, and S. C. Mukhopadhyay, Wearable sensing system to perform real-time 3D posture estimation for lower back healthcare, in Proc. IEEE ROSE Symp., 2021.

  8. F. Haider, P. Albert, and S. Luz, Automatic recognition of low-back chronic pain level and protective movement behaviour using physical and muscle activity information, in Proc. IEEE Int. Conf. Autom. Face Gesture Recognit. (FG), 2020.

  9. A. Gupta, P. Sharma, and R. Verma, IoT-enabled physiotherapy system with cloud-based analytics for exercise prescription, IEEE Internet Things J., vol. 8, no. 12, pp. 98769885, 2021.

  10. K. A. Hasan and M. A. Hasan, Identification and analysis of risk factors of lower back pain using machine learning approaches, in Proc. IEEE ICECE, 2020.

  11. S. Patel, H. Park, P. Bonato, L. Chan, and M. Rodgers, A review of wearable sensors and systems with application in rehabilitation, J. NeuroEng. Rehabil., vol. 9, no. 1, p. 21, 2012.

  12. X. Liu, Q. Zhang, and W. Li, Reinforcement learning- based adaptive exercise recommendation system for chronic pain, Neural Comput. Appl., vol. 34, pp. 1024510258, 2022.

  13. P. S. Sharma, A. Gupta, and S. Lee, Human motion analysis and pain prediction using multi-sensor data fusion, Biomed. Signal Process. Control, vol. 71, p. 103125, 2022.

  14. A. Rodriguez, F. Martinez, and E. Garcia, Wearable postural control system for low back pain therapy using vibrotactile feedback, IEEE Trans. Instrum. Meas., vol. 70, pp. 110, 2021.

  15. J. Wang, L. Zhang, and H. Chen, A smart wearable system for monitoring low back pain patients in home environment, in Proc. IEEE EMBC, pp. 12341238, 2021.

  16. Y. Chen, Z. Wang, and X. Zhang, Personalized physical exercise recommendation based on multi- modal health data using machine learning, IEEE J. Biomed. Health Inform., vol. 26, no. 8, pp. 41234134,

    2022.

  17. R. Karthikeyan, P. Balasubramanian, and S. Kumar, An AI-assisted rehabilitation framework for musculoskeletal disorders using wearable sensors, IEEE Access, vol. 11, pp. 4567245685, 2023.

  18. D. Park, S. Kim, and H. Lee, An AI-powered digital physiotherapy platform for chronic pain management: A clinical validation study, Front. Digit. Health, vol. 5, p. 1122345, 2023.

  19. A. R. Rahman, B. Singh, and T. Smith, IoT-based remote physiotherapy monitoring system with real-time analytics, IEEE Sensors J., vol. 20, no. 24, pp. 15089 15098, 2020.

  20. S. N. Deepika, V. Priyanka, and S. Karthik, Deep learning-based human activity recognition for posture analysis using wearable sensors, Measurement, vol. 185, p. 110038, 2021.