Embedded Machine-Vision Control of Electromagnetic Levitation Using Data-Driven Force Modelling
Chen Zhong, Damiano Padovani, Andrea Cioncolini, Angelo AlessandriElectromagnetic levitation systems are instrumental in rail transportation, manufacturing machinery, contactless bearings, and precision scientific instrumentation. These systems are inherently open-loop-unstable, require accurate motion tracking to detect the position of the levitated object, and need effective real-time control to adjust the electromagnetic force. In this paper, we propose a machine-vision-based magnetic levitation system comprising a Raspberry Pi microcomputer programmed in Python, a machine-vision camera with software triggering, and a lifting electromagnet actuated using a model-based PID controller with compensation and feedforward augmentation. Since all components are available off-the-shelf, the present magnetic levitation system is cost-effective and easy to replicate. To the best of our knowledge, the present setup seems to be the first entirely based on a Raspberry Pi microcomputer; the first in which the electromagnetic force is predicted with an empirical correlation based on dedicated measurements, making analytical/numerical predictions unnecessary; and the first where the added mass is incorporated in the equation of motion of the levitated object (it is a non-negligible phenomenon, function of the position, for levitation in liquids). The visual tracking system has an accuracy of about ±15 micrometers, and the controller operates at 100 Hz. When actuating a sphere large enough to significantly distort the electromagnetic field, this magnetic levitation setup achieves position-tracking errors (RMS errors in the range of 74 to 194 μm during quasi-static and dynamic tests) comparable to or better than those of machine-vision-based magnetic levitation systems proposed in previous investigations, at a fraction of the cost.