It oscillates current through out the 2 coils(+amps, -amps, 0amps) in a certain order to attract and repel N/S side of a magnet to cause it to spin in a certain direction. Red LEDs is positive and blue LEDs is negative to represent current directions.