A very simple analog circuit for levitating small objects, which is the essence of many enlightening discussions and experiments with some modified prototypes. The electronics now even fit in the housing of a modified "Finder"-relay!

I wrote at Elektor Labs about my experiments with my magnetic  levitation circuits.
In the helpful discussions with Luc Lemmens of the Elektor team about magnetic levitation some thoughts came up, which I followed up. The result was another strong simplification of  the "old" analog circuit that allows to levitate small (magnetic) objects.
Despite the much  simpler design, the functionality is very good.

The now used components are very common and  easily available:
- LM311 comparator
- SS49E Hall sensor
- 5V Finder relay as electromagnet

Simplified circuitry:
A realization from the previous circuit was that only a very small additional controlled magnetic field must be generated to keep the levitation object in position. The actual heavy work is done by the permanent force between the permanent magnet in the levitation object and the iron core.
The comparator LM311 can provide the small control current of maximum 90 mA at 5V without an additional external driver transistor. This simplifies the circuit considerably.

How to get the right relay ... and how to modify it
The electromagnet now consists of the solenoid coil of a 5V relay "Finder", which is very readily available and considerably easier to modify.
The transparent "Finder" relay housing is often glued to its base. However, it can be easily opened by heating the adhesive joint with a hair dryer. A cutter, also slightly heated, then helps to separate it.

The core of the solenoid must be changed again from its U-shape to a J- or better I-shape to avoid a magnetic short. This is quite easy because the round core and the rectangular flat extension are only clamped together. This rough clamping can be loosened with a small cutting disc or a milling head.
Finally, the freed iron core can be turned to obtain a slightly larger and also flat pole face for gluing on the HALL sensor.
At least the electromagnet and  the HALL sensor can be mounted within the relay's housing, where they are well protected  against the magnet.

The operating voltage is 5V at only 50mA (up to a maximum of 90mA )
The described modification of the "Finder" relay creates a very good electromagnet and even a good mechanical protection of the whole circuit against vagabonding permanent magnets. If you really want to build it that small within the former relay housing , it can be done with acceptable mechanical effort and usual means.
But of course the circuit can also be built very easily on a breadboard or grid board and only four wires are needed to connect the coil + LED + resistor  and the sensor to the rest of the circuit. A  20cm piece of flat band cable was very helpful to me for this purpose in the prototype.

There  is a short video of the resulting setup.

Read about  my "old" circuit    and  as well  HERE  Luc's article about  it