Line Following Circuit Board Wiring Guide Soldering the Analog Optosensors 1. Obtain a line following printed circuit board from the store as well as three analog optosensors (w/6 resistors). 2. Remove the middle stubs from the analog optosensors using diagonal cutters or any other method that you want. Sand down any extra material, so the optosensor will be able to lay flush with the board when you solder. 3. Place the analog optosensor on the top side of the board, and make sure all four pins go through the board and that the symbols on the optosensor (diode and transistor) match the symbols on the board. The metallic spots on the circuit board are called pads. On reverse side, at each pad location where the pins poke through. Ensure solder connection is good by lightly tugging on the optosensor and checking for loose pins. Trim all the leads on the back of the board to make it as flat as possible.
4. Place the 180 Ohm resistor on the top side of the board next to the analog optosensor. Push each of the two pins through the holes in the board, so that the resistor lays flush against the board. Solder each end of the resistor to the terminals on the board. The resistor leads can be trimmed after soldering. Note: Orientation of resistors does not matter. Reverse side of the board should appear the same as in the following diagram on the left. Back Front METHOD A for Attaching Wires 5a. If you want to be able to remove your wire connectors (the wires that connect your line following board to your proteus) from the line following board, Method 1 is advised. Acquire a strip of long male header from the store. Cut away a three pin strip as shown in the following image. 6a. Bend the 3 pin strip into a right angle as shown in the following. You can bend it either by bending it against a hard surface, or by using needle nose pliers from the store.
7a. Insert the bent side of the header into the circuit board as shown. Solder the pins of the header to the backside of the circuit board. When soldering, the solder should flow over all of the pad and around the header pin. You can use diagonal cutters to shorten the pin leads. You will then need to take ribbon cable (a three wire strip), and solder this to a three-pin female header strip. The strip of ribbon cable should be long enough to reach from the Proteus controller to the underside of your robot design.
Method B for Attaching Wires 5b. If you do not want to be able to remove the wires from the circuit board with header connectors, consider Method B. Take three pieces of ribbon cable and strip approximately ¼ of an inch. Place the wires through the centered set of three holes on the board. Solder each wire to each hole. (See Diagram) Note: Wires can be soldered to either side of the board. As seen on the front side of the board, the left (grey wire) is ground, the middle (white wire) is +3.3V, and the right (black wire) is signal. Back Front Soldering Resistors and 4 Pin Male Header 6. Take the other three ends of the ribbon cable and solder them to a 4 pin male header strip (seen below). The specifications for which terminal is ground, +3.3V, and signal can be seen in the following image. Include the 68 kohm resistor as the pull up resistor between the signal and +3.3V pins.
7. Decide how far apart you want your other two optosensors by checking the spacing needed on the course for your specific line following algorithm. Place the other two analog optosensors with resistors equal distance apart on one of the four choices for spacing and repeat steps 2-6. Make sure to trim all the leads on the back of the board to make sure it can be mounted as flush as possible to the base of your robot. Also, make sure to cover the bottom of the circuit board when finished with electrical tape or some other insulator, so you do not short any of the sensors by contacting it with metal.