Magnetic attraction/repulsion with motor/generator and similar systems?
The force that causes motion is due to the interaction of two magnetic fields, at least one of which is created by a current flowing through a conductor. Force is given by F=BIL, which is, essentially, the Lorentz force.

In a generator, a voltage (and consequent current if there's a circuit) is created by moving a conductor in a magnetic field. Mechanical energy is thereby converted to electrical energy (if a current flows). If there is no circuit, there will be zero current, and zero force is required to move the conductor. The induced voltage (actually, an EMF) is E=BLv, where v is the velocity of the conductor wrt the magnetic field.