In this demonstration I made a very basic instrument construction just to show how the pickup is used. I will talk about this in the last step. How you adapt your own version to your instrument depends entirely on your imagination!
Step 1: The Motor
Step 2: Small Holes
its a good idea to glue the axle so that it doesn't spin.
Step 3: Small Solderings
it doesn't matter which wire goes where.
Step 4: Ta Daa!
The nitty gritty of why this works is pretty simple: electric pickups on guitars are just magnets and coiled wire, the vibrations of the strings create a fluctuation in the magnetic field which creates a very small alternating current in the wire. This is then sent off to an amplifier which comes out as noise. It's all called Faraday's law of Induction which is about one of the only things I remember from physics lessons. Electric motors work using the same Law of induction, so they're built from magnets and coils just like a pickup, the only difference is how they're utilised in everyday use, innit.
The 'instrument' in the demonstration below was a simple one-stringed instrument with a tuning peg at one end and an anchor at the other (for ideas on homemade/DIY tuning pegs, check out my post on it at my blog here.
I used two small L-Brackets in order to get the wire to the right height to pass through the motor without it touching the sides.
I've included an image of the pickup in-use in an instrument I built. The axle on the motor was at a different angle that allowed 2 strings to go through it.