The electromagnets are these.
They are driven with an SN754410 h-bridge, which is controlled by an ATtiny84. It's not very stable, the magnet will only spin at a specific RPM.
But, hey, this is just a start. I'm receptive to any ideas anyone has to improve it.