There is a ring permanent magnet fixed in the DC motor, and the current generates ampere force through the coil on the rotor. When the coil on the rotor is parallel to the magnetic field, the direction of the magnetic field that continues to rotate will change. So at this time, the brush at the end of the rotor is in alternating contact with the conversion plate, so the current direction on the coil is also changed, and the direction of the Lorentz force is unchanged, so the motor can maintain a direction of rotation.
The working principle of DC generator is to change the alternating electromotive force induced in the armature coil into DC electromotive force when it is drawn from the end of the brush by the commutator combined with the commutating action of the brush.
The direction of the induced electromotive force is determined according to the right-hand rule (the magnetic induction line points to the palm of the hand, the thumb points to the direction of movement of the conductor, and the other four fingers point to the direction of the induced electromotive force in the conductor.
The direction of force on the conductor is determined by the left-hand rule. This pair of electromagnetic forces forms a torque acting on the armature, which is called electromagnetic torque in a rotating motor, and the direction of the torque is counterclockwise in an attempt to make the armature rotate counterclockwise. If this electromagnetic torque can overcome the resistance torque on the armature (such as the resistance torque caused by friction and other load torque), the armature can rotate counterclockwise.