
A project from electroniclovers on Hackster walks through how a DC motor turns current into rotation, using magnets, a copper loop and a 3D simulation to show the steps.
It starts with two permanent magnets and the attraction between opposite poles. Next, current through a copper rod makes a magnetic field around it, and reversing the current flips that field. Put the rod between the magnet’s north and south poles and the two fields push the rod one way. Flip the current and it pushes the other way.
Bend two rods into a rectangular loop on a shaft and the sides push in opposite directions, so the loop turns. At 90 degrees, the torque drops to zero, so a split-ring commutator with carbon brushes reverses the current every half turn to keep it going. Adding a second coil at right angles to the first covers that dead spot. The build uses Blender, Unity or a WebGL viewer for the simulation part.
See more at hackster.io.