A very small electric motor has two small permanent magnets, a commutator, two brushes, three poles, and an electromagnet made by winding wire around a piece of metal. It works the same way a larger version does, but on a much smaller scale.