The electric motor is a standard DC electric motor. See How Electric Motors Work to see the parts inside an actual electric motor.
On the end of the motor is a small 6-tooth gear. This gear fits into the center of the planetary gear system, as shown here:
A gear attached to the motor fits in the middle of the three smaller gears.
This gear system is the heart of any electric screwdriver. An electric motor by itself is a pretty weak device. You can grab the axle and stop a small motor's rotation very easily. But if you gear the motor way down, it can have enough strength to drive a screw into a piece of wood effortlessly. In this screwdriver the dual planetary gear system has a 56:1 reduction ratio. With this reduction ratio, the motor will turn 56 times for the chuck to turn once. This means that the chuck moves very slowly relative to the motor, but that the chuck has a great deal of torque (it takes 56 times more strength to stop the motor from spinning because of the gear ratio).
Here's where that number comes from. The center gear has to turn about three times to turn its three neighboring gears once. These gears have to turn about two and a half times to travel around the outer ring once, for a total of about 7.5 turns. The outer ring is stationary -- other gears just move around inside it.
The gear set has two identical layers, one on the top and one on the bottom (you can't see the bottom layer in the pictures -- it's hidden behind the top). The top layer of the gear system mounts to a little table that has a second 6-tooth gear under it. Because of the movement of the top layer, this gear moves once for every 7.5 rotations of the motor. It takes 7.5 turns of the bottom 6-tooth gear for the bottom gears to travel around the ring once, for a total gear ratio of about 56.25:1. The bottom gears attach to a piece of metal that turns the chuck once for every 56 rotations of the motor.
For more information on how electric motors work, read How Motors Work. For more information on how gears work, please read How Gears Work. To learn more about power tools and related topics, follow the links below.