So, the electromagnet ‘pulls’ the piece of steel into its inner cavity.
The wooden stick and bead seems to be arranged and mounted in a way that gravity will ‘pull’ the piece of steel away from the solenoid.
I think the solenoids are only strong enough to ‘swing’ the stick and bead toward the tube, but not hold it in place for a sustained period.
[update]
Totally wrong. Seems to be the opposite. The solenoid sucks in the piece of steel, moving the stick and bead away from the tube, but normally, at rest, the bead rests against the tube, because of the hinge and gravity.