Machine Learning-Based Position Detection Using Hall-Effect Sensor Arrays on Resource-Constrained Microcontroller
This paper presents an electromagnetic levitation system that stabilizes a magnetic body using an array of electromagnets controlled by a Hall-effect sensor array and TinyML-based position detection. Departing from conventional optical tracking methods, the proposed design combines finite-element-optimized electromagnets with a microcontroller-optimized neural network that processes sensor data to predict the levitated object's position with 0.0263-0.0381 mm mean absolute error. The system employs both quantized and full-precision implementations of a supervised multi-output regression model trained on spatially sampled data (40 × 40 × 15 mm volume at 5 mm intervals). Comprehensive benchmarking demonstrates stable operation at 850-1000 Hz control frequencies, matching optical systems' performance while eliminating their cost and complexity. The integrated solution performs real-time position detection and current calculation entirely on-board, requiring no external tracking devices or high-performance computing. By achieving sub 30 μm accuracy with standard microcontrollers and minimal hardware, this work validates machine learning as a viable alternative to optical position detection in magnetic levitation systems, reducing implementation barriers for research and industrial applications. The complete system design, including electromagnetic array characterization, neural network architecture selection, and real-time implementation challenges, is presented alongside performance comparisons with conventional approaches.
Authors
- Zalán Németh
- Chan Hwang See (ORCID: https://orcid.org/0000-0001-8439-7321)
- Arfan Ghani (ORCID: https://orcid.org/0000-0002-1362-3720)
- Simeon Keates (ORCID: https://orcid.org/0000-0002-2826-672X)
- Keng Goh (ORCID: https://orcid.org/0000-0001-5205-5802)
- Raed A. Abd‐Alhameed (ORCID: https://orcid.org/0000-0003-2972-9965)
Institutions
- University of Chichester (GB)
- University of Basrah (IQ)
- University of Bradford (GB)
- Edinburgh Napier University (GB)
- Iraq University College (IQ)
- American University of Ras Al Khaimah (AE)
Publication Details
- Journal
- Sensors
- Published
- 2025-10-18
- DOI
- https://doi.org/10.3390/s25206444
- Primary Topic
- Inertial Sensor and Navigation
- Type
- article
- Field-Weighted Citation Impact
- 0.00