1. The motor driver and sensors on the Furby
There are a number of sensors and a motor driver on the Furby. The following is a list of these sensors and their functions.(The pin numbers are counted from top to bottom)
|
Function/Location
|
Connection
|
Type
|
Pin number
|
Colors
|
|
back
|
direct
|
switch
|
pin 1 and 2
|
yellow
|
|
inversion
|
direct
|
tilt (ball)
|
black, red
|
|
|
microphone
|
direct
|
mic
|
black, red
|
|
|
index
|
connector
|
switch
|
black, red
|
|
|
stomach
|
connector (w/ speaker)
|
switch
|
pin 3 and 4
|
black, red
|
|
tongue
|
connector (w/ encoder)
|
switch
|
pin 1 and 2
|
brown/orange
|
|
light sensor
|
connector (w/ IR)
|
photoresistor
|
pin 1 and 2
|
black, red
|
|
IR (detect/emit)
|
connector (w/ light sensor)
|
photo-transistor/diode
|
pin 5/6 |
yellow/green |
|
IR encoder
|
connector (w/ tongue)
|
photo-transistor/diode
|
pin 3 and 4
|
black, red
|
|
motor
|
connector
|
black, red
|
||
|
speaker
|
connector (w/ stomach)
|
pin 1 and 2
|
brown/orange
|
The
above sensors and the motor driver are connected to the
microcontroller through circuits built on the circuit board of the
Furby. In order to use these sensors and the motor driver, we have to
understand what's built on the circuit board of the Furby first and
then try to reproduce them. Click on the image on the right to look
at the schematics of the Furby. (Schematics created by Chris Brown,
taken from http://www.hackfurby.com/schematic.html)
1.1 Circuit for the motor driver
When we were building the motor driver circuit, we did not use the driver circuit shown in the schematics. We built a pull-up and pull-down network to drive the motor instead. This made the circuit simpler and easier to build.

Fig 1. Schematics of the motor driver
The NPN and PNP transistors used in this circuit are both power transistors because a lot of power is dissipated in this circuit. The voltage drop across the transistors can be as high as 10V and the maximum current going through the transistors is about 100mA. So, the power dissipated in the transistors can be as high as 1V. Transistors for general purpose cannot handle this high power and so power transistors are used. The NPN used in our circuit is TIP31 and the PNP is TIP42, both bought from Radio Shack. It is also recommended you should use appropiate heat sinks to avoid overheating.
1.2 Circuit for the encoder circuit
To interface the encoder of the Furby to the STG card, we can construct a circuit similar to the one built on the Furby, using the 74LS14 Hex Schmitt trigger IC chip. The circuit would be like this.

Pin 4(red) of the connector of the Furby should be connected to +5V and Pin 3 (black) should be connected to the pull down resistor and pin1 of the 74LS14 chip. Pin 2 of the chip should be connected to pin 3 of the chip and pin 4 of the chip should be connected to the encoder input of the STG card.
Note that the resistor value of the pull-down resistor affects the voltage at pin 3 of the Furby's connector. We used a 1k ohm resistor to make it less sensitive to light (since we're now operating with it open to ambient light). There are other ways to put the pull-down resistor:
(1) put a potentiometer there, so we can adjust the sensitivity;
(2) put a comparator there, so we can adjust the level at which the output of the comparator changes from high to low
You should also disable the quadrature mode of the STG card to count the correct number of pulses. The following code fragment should be executed every time you use the encoder.
fOutPW(wBaseAddress + CNT0_C, 0xC0); //disables quadrature mode
Note: CNT0_C is the command register, doing this allows us to use the single pulse on the encoder channel A.
1.3 Circuit for the home switch
It is very simple to interface the home switch to the STG switch. The circuit looks like this:

In the above diagram, a 20k ohm resistor is used as the pull-up resistor. You can, however, use any resistor as the pull-up resistor as long as the resistance is high enough to protect the circuit.