I build a prototype to see if it was possible to implement the control system in software.
Since static passive magnetic levitation is not possible a HALL effect sensor
is used to constantly regulate the magnetic field.
To achieve stability a software based PID controller is used.
This is the Arduino code for the project