The document describes a magnetic levitation system that uses an electromagnet to levitate a small magnet. A Hall effect sensor measures the vertical position of the levitating magnet and a digital signal controller controls the current in the electromagnet coil through pulse-width modulation to maintain the magnet's level of levitation. The system provides feedback to stabilize the levitating material's position and compensate for disturbances through varying the current in the electromagnet coil.