Instructables

Build a SpurtBot Line Follower

FeaturedContest Winner
Picture of Build a SpurtBot Line Follower
SpurtQRD-2.jpg
NOTE: Before you decide to build this robot, please read my newer Instructable on building a SpurtBot Shadow Runner robot. The new design uses a solderless breadboard, so after you build the robot, you can experiment with your own circuits to control the robot in new ways. OK, carry on.

SPURT stands for School Projects Using Robot Technology, a concept introduced by the Rostock University, in Germany. You can find more about their program on their website at http://spurt.uni-rostock.de/en/

These instructions are for building a very simple version of a line following robot, based on the SpurtBot design above. Thanks to Hartmut from Rostock University for his support in creating this design.

The schematic for the circuit is included in the images.

A version of these instructions can be found online at http://letsmakerobots.com/node/28981

You can also watch the video below for an explaination of how the SpurtBot works and a quick demonstration.

I hope you enjoy building your SpurtBot!




 

 
Remove these adsRemove these ads by Signing Up

Step 1: Gather your materials

Picture of Gather your materials
Parts/Materials

• (2) Bearings from inline skates (Search YouTube for vids on how to remove and clean them.)
• (1) Balloon for Bands/tires (Use heavier duty 'punching balloon'.)
• (1) Popsicle/craft stick (I like nice color ones, but use whatever you like.)
• (1) 2 inch piece of 5/16 inch wooden dowel (The dowel should fit snugly into the bearings.)
• (2) Motors (3VDC, Jency Motor ST130-12240-38, Jenco part # 154915 or Mabuchi FK-260SA-10400, Jenco part # 2081908)
• (2) AA alkaline batteries
• (1) QRD-1114 reflective sensor
• (1) bc 337 NPN transistor
• (1) Resistor (50 to 100 ohm for IR emitter)
• (1) 10K ohm resistor (optional pull-down resistor may improve performance)
• (1) Battery holder for 2xAA batteries
• 8 inches of red wire
• 6 inches of white wire
• 6 inches of black wire

 Tools/Supplies

• Wire cutters
• Wire strippers
• Needle nose pliers
• Hot glue gun and glue sticks
• Soldering iron and solder
• Drill and 1/16 inch drill bit
• Sharp scissors
• Heat shrink tubing (1/16 inch, 3/32 inch, and 1/8 inch)
• Butane Lighter or other heat source

Step 2: Make some holes

Picture of Make some holes
SpurtBotQRD Instructions 077 crop sm.jpg
SpurtBotQRD Instructions 078 crop sm.jpg
Using the four leads of the QRD-1114 sensor as a guide, mark four dots near the very end of the craft stick.

Now use the three leads of the bc337 transistor to mark three dots about half an inch behind the dots for the QRD-1114.

The two sets of holes should be close enough to each other that the leads of the QRD-1114 when it is inserted can be bent back to make contact with the leads of the bc337 transistor.

Use a 1/16th inch drill bit to drill holes over each of the dots. Go slowly and be careful to avoid running the holes too close together. Use of a drill press is very helpful, but you can do it with a hand drill if you don’t have one. A wooden backer board underneath the craft stick will also help support the material while you are drilling.

When you are done, the craft stick should look a lot like the third picture.







Step 3: Attach the dowel

Picture of Attach the dowel
Mark the center of the dowel as a guide, and use the hot glue gun to attach the dowel on top of the craft stick. The dowel should be about 3/5th back from the front of the craft stick where the holes are drilled.

You want to be sure the dowel is square with the craft stick. I like to use the corner of a table to hold the two pieces of wood at 90 degrees while the hot glue is drying.

 

Step 4: Attach the bearings

Picture of Attach the bearings
SpurtBotQRD Instructions 090 crop sm.jpg
Next place one bearing flat on its side. Hold the craft stick and dowel so that one end of the dowel is directly over the hole in the bearing. Being careful not to apply any pressure to the craft stick, push down firmly on the other end of the dowel until it is inserted fully into the bearing.

The end of the dowel should be flush with the surface of the side of the bearing, as shown in the 2nd picture.

Now repeat the process with the other bearing, so that you have one bearing on each side of the dowel. While you insert the second bearing, be careful to press down on the top of the dowel, rather than on the edges of the first bearing, or you might wind up with the dowel inserted too far into the first bearing.

Also be sure that the bearings are mounted at 90 degrees to the dowel. Congratulations, you now have a ‘rolling chassis’ for your SpurtBot.





Step 5: Attach your motors

Picture of Attach your motors
The motors need to be positioned carefully. Before you mount your motors, keep the following things in mind.

• The motor shafts need to be parallel to the rolling surface of the bearings. In other words, the motor shafts should be at 90 degrees to the craft stick and parallel to the dowel.
• The right motor shaft will need to be thickened with 3 to 4 pieces of heat shrink tubing. You need to leave about 1/8th of an inch between the shaft and the surface of the bearing to allow for the shrink tube to fit.
• Despite the above, you don’t want too much space between the motor shaft and the bearing, because it will add too much tension to the wheel when the bands are installed.
• To keep tension roughly equal on both bearings, you want both motors positioned the same distance from the bearings.
• The shaft of the right motor should be positioned directly behind the right bearing. The shaft of the left motor should be positioned directly in front of the left bearing.
• The shaft should overlap both sides of the bearing a little bit, so the tension bands will stay on the wheels.

OK, time to glue the motors on! Don’t sweat the points above too much. If you mess it up, hot glue is easy to remove and you can try again.

Start with the right motor, which will be mounted to the rear of the dowel. Position the motor and get a good feel for where it will go, noting the points above. Once you are ready, place a generous amount of hot glue on the craft stick and the dowel on the side the motor will touch.

CAUTION: Hot glue is, well… HOT. It will stick to your skin and burn you. The end of the hot glue gun is very hot. Don’t touch it, and don’t let it touch anything that can burn.

Pull the hot glue gun away quickly, and place it safely on the table. Working quickly, grab the right motor and place it on the SpurtBot.

You will have a few moments as the glue hardens, so check that the shaft is positioned as you want it. Then hold it still for a minute while the glue dries.

After the glue is dry, you can break off the little annoying threads of hot glue that inevitably happen.








Step 6: Mark you connections

Picture of Mark you connections
I like to mark all of my connections, so I don’t make (many) mistakes. Look at the SpurtBot from the top so that the front end with the holes is facing away from you.

Start with the four holes you drilled in Step 2 for the QRD-1114. Carefully mark the front-left hole with a ‘1’. Moving clockwise, the front-right hole is marked ‘2’. The hole just below that is marked ‘3’, and the hole just to the left of that is marked ‘4’.

Next, we’ll mark the three holes for the bc337 transistor. The left hole is marked ‘e’ for emitter. The center hole is marked ‘b’ for base. The right hole is marked ‘c’ for collector.

I also like to mark the shape of the bc337 transistor right on the SpurtBot, so I always insert it the right way. Make a little ‘D’ shaped marking behind the three mounting holes, with the flat side of the ‘D’ facing the front of the SpurtBot.

Step 7: Install the QRD-1114

Picture of Install the QRD-1114
SpurtBotQRD Instructions 105 crop sm.jpg
Note: If the QRD-1114 sensor is inserted incorrectly, it will be destroyed as soon as power is applied, so take your time with this step.

The sensor will be mounted ‘dead bug’, meaning the sensor will be pointed down with its leads up in the air. Look at the QRD-1114 reflective sensor. There is one dark lens and one clear lens. Pin 1 of the sensor is marked with a dot on the top of the case by the dark lens. Many people have trouble seeing the dot, because it is very small. When mounted correctly underneath the SpurtBot, the clear lens will be towards the rear. See the picture below.

You will insert the leads up from the bottom, and through the four holes you drilled in the front of the SpurtBot in Step 2.

Make sure that lead 1 of the QRD-1114 is inserted into the hole you marked ‘1’.

Hold the QRD-1114 flush against the underside of the SpurtBot, and bend all four leads slightly outward to help hold the sensor in place.



Step 8: Install the resistor

You are going to solder the resistor between pins 1 and three of the QRD-1114. A small 1/8th Watt resistor should fit nicely. Try to solder it so that it is as close to the craft stick as possible. This will help keep the QRD-1114 in place.

Solder one side of the resistor to pin 1 of the QRD-1114. It may be helpful to use an object to hold the other side of the resistor, or get a friend to help you. Don’t worry if the solder isn’t perfect.

Now go solder the other side of the resistor to pin 3 of the QRD-1114. Because the resistor is now held in place from your previous solder joint, this should be pretty easy.

If you need to, go back and re-solder the first side of the resistor, positioning it so that it is close to the surface of the craft stick, as mentioned above.

Check to be sure the QRD-1114 is still mounted flush to the underside of the craft stick. Adjust the two solder joints if needed to be sure the QRD-1114 is in place.

Cut off the leads from the QRD-1114 and the resistor at pin 3 only (refer to 2nd picture). Leave the leads of the QRD-1114 pin 1, 2 and 4 alone for now.

NOTE: I have found that adding a 10k ohm pull-down resistor between pin 1 of the QRD-1114 and ground improves performance.  It tends to make the line following more accurate in some situations by insuring the base of the BC337 transistor is pulled firmly to ground.

If you want to use the optional 10k ohm pull-down resistor, this would be a good time to install it. Solder the resistor across pin 2 and pin 4 of the QRD-1114, so that the 10k ohm resistor is sitting diagonally across the resistor you already installed between pin 1 and pin 3. Then cut the excess leads from the 10k ohm resistor, leaving the excess lead from the QRD-1114 pin 2 and pin 4 in place for now.

Step 9: Test your motors

You need to know which way your motors will turn when you connect power to them. So we are going to test them.

Insert the two AA batteries into the battery holder.

Start with the right motor, which is mounted behind the dowel with its shaft behind the right bearing.

Looked at from the right side, the bearing needs to turn clockwise for the SpurtBot to move forward. Since the motor will be attached to the bearing directly using a band, the right wheel motor also needs to turn clockwise.

Temporarily attach the black wire from the battery holder to one lead of the motor and the red lead from the battery holder to the other lead of the motor. Note which way it is spinning when viewed from the right side of the robot.

If it is spinning clockwise, mark the motor lead attached to the red wire with a ‘+’ and the motor lead attached to the black wire with a ‘-’.

If the motor is turning counter-clockwise, then you need to reverse the markings. Mark the motor lead attached to the red wire with a ‘-’, and mark the motor lead attached to the black wire with a ‘+’.

Now test the left motor. Repeat the above procedure, making sure the motor will turn counter-clockwise when viewed from the left side when you attach the battery leads.

Take your time with this step. As they say in carpentry, “Measure twice, cut once.”

Step 10: Connect the red wires

Preparation (refer to 1st picture)

Carefully strip about ¼ inch of insulation from one end of the red wire. Pinch the exposed conductors at the end of the wire between your thumb and forefinger, and twist the wire several times. This will help keep the individual conductors together while you work with them.

In the following steps, I will refer to this technique as ‘twisting the leads’. You’ll use this technique whenever you strip some insulation from the wire.

Next, use a clamp or other method to hold the exposed end of the red wire above your work surface, and tin the lead with your soldering iron. Use the smallest amount of solder you can. If you do not know how to tin your leads, look it up on the Internet or ask for help.

Now take the tinned end of the wire, and bend a little hook in it with the needle nose pliers.First Connection (refer to first picture)

First Connection (refer to 2nd picture)

 Wrap the hook of wire around pin 1 of the QRD-1114, and solder it in place. Be sure that the resistor is still soldered properly to pin 1 too.

You may now cut the extra leads of the resistor and QRD-1114 from pin 1 only . Leave the leads of the QRD-1114 pin 2 and 4 alone for now.

Second Connection (refer to 3rd picture)
 
Route the red wire back along the body of the SpurtBot toward the left motor. Avoid covering any of the holes or markings for the bc337 transistor.

Check the length you need to reach the ‘+’ lead of the left motor. Leave an extra ¼ inch and then cut the red wire. Strip about 1/8 inch from the end of the red wire, and ‘twist the leads’.

Insert the twisted end of the red wire through the left motor contact for the ‘+’ lead, but don’t solder it yet

Now take the remaining piece of red wire that you cut off earlier. Strip about 1/8 inch from the end and twist the leads.

Take the twisted end of this red wire and insert it into the same left motor ‘+’ lead as the other wire. It may be a tight fit. Get creative, but be sure you will have good electrical contact. Now solder both red wires to the left motor ‘+’ lead.

Check your solder joint carefully. Be sure both wires are firmly connected.

Third Connection (refer to 4th picture)

Now route the free end of the red wire between the two motors, towards the ‘+’ lead of the right motor. Once again, cut the wire about ¼ inch longer than the length needed to reach the contact. Then strip 1/8 inch from the end of the wire, and twist the leads.

Insert the twisted end of the red wire through the ‘+’ contact of the right motor, but don’t solder it yet.

Cut a 3 inch piece of red wire from what you have left. Strip both sides and twist the leads.

Now insert one end of this red wire into the same ‘+’ contact of the right motor, where you have already inserted the red wire coming from the left motor. Again, it may be a tight fit.

Solder both leads firmly in place.

Use your soldering iron to tin the end of the red wire. Then use the needle nose pliers to bend a hook in the end of the wire. 

Step 11: Install the bc337 transistor

Insert Transistor (refer to 1st picture)

It’s time to install the transistor. Insert the transistor from the top of the SprutBot. Be sure to align the body of the transistors as it is marked. The flat side of the transistor should be facing the front of the SpurtBot.

The center pin should be in the hole marked ‘b’; this is the base of the transistor. The right pin should be in the hole marked ‘c’; this is the collector. The left pin should be in the hole marked ‘e’; this is the emitter.

Be sure to leave a little of the transistor leads showing at the top side of the SpurtBot. You will need to solder to the emitter lead from the top.

Connect Transistor Base (refer to 2nd picture)


Turn the SpurtBot upside down, and bend the left and right leads of the bc337 transistor outward. This will help keep the transistor in place. Leave the center lead of the transistor (the base) standing straight.

Now, take the lead from pin 2 of the QRD-1114 and wrap it underneath the SpurtBot. Use the needle nose pliers to carefully route the lead so that it touches the base (center pin) of the transistor. Keep the lead as close to the underside of the SpurtBot as you can.

Be very careful that the base lead and the QRD-1114 pin 2 lead only touch each other and nothing else.

Next, solder the QRD-1114 pin 2 to the base of the transistor. Double check that you have a good connection, and that those two leads are not touching anything else.

Then cut the extra lead off the base of the transistor. It is important that none of the leads from the transistor end up longer than the body of the QRD-1114, or they will drag when the SpurtBot drives.

Connect Transistor Emitter (refer to 3rd picture)

Turn the SpurtBot back over right side up. Bend the lead from the QRD-1114 pin 4 back along the body of the SpurtBot towards the emitter lead of the bc337 transistor. Use the needle nose pliers to position the QRD-1114 pin 4 lead against the emitter of the transistor.

Be very careful that the pin 4 lead of the QRD-1114 is touching the lead of the emitter and nothing else.

Carefully solder the pin 4 lead of the QRD-1114 to the emitter of the transistor. Double check that you have a good connection, and that those two leads are not touching anything else. It is easy to accidently short against the base of the transistor.

Trim the extra wire from the lead of the QRD-1114.

Step 12: Connect the white wire

Preparation

Strip about ¼ inch from the end of the white wire. Twist the leads. Then tin the leads with your soldering iron using as little solder as possible.

Bend a little hook in the tinned end of the wire using the needle nose pliers.

First Connection (refer to 1st picture)

Now turn the SpurtBot upside down, and connect the hooked end of the white wire to the collector lead of the transistor. It is helpful to use the needle nose pliers to clamp the little hook shut onto the lead of the collector so it will stay in place while you work with it.

Be very careful that the white wire and the collector lead are not touching any other connections. 

Next, solder the white wire to the collector. Double check your connection.

Cut off the extra lead from the end of the collector.

Second Connection (refer to 2nd picture)

Now route the white wire along the underside of the SpurtBot, towards the right motor. The wire will cross the body of the SpurtBot to come up near the ‘-’ lead of the right motor.

Cut the white wire about ¼ inch past the length it needs to reach the ‘-’ contact of the right motor. Strip about 1/8 inch of insulation from the end of the white wire, and twist the leads.

Insert the stripped and twisted end of the white wire into the ‘-’ contact of the right motor and solder it in place.

Press the white wire against the underside of the SpurtBot so it is flush. Hold it in place with a dab or two of hot glue.

Step 13: Connect the black wire

Preparation

Strip about 1/8 inch of insulation from the end of the black wire. Twist the leads. Tin the end with as little solder as possible.
Use the needle nose pliers to bend a little hook into the tinned end of the black wire.

First Connection (refer to 1st picture)

Now turn the SpurtBot upside down, and connect the hooked end of the black wire to the emitter lead of the transistor. It is helpful to use the needle nose pliers to clamp the little hook shut onto the lead of the emitter so it will stay in place while you work with it.

Be very careful that the black wire and the emitter lead are not touching any other connections. 

Next, solder the black wire to the emitter. Double check your connection.

Cut off the extra lead from the end of the emitter.

Second Connection (refer to 1st and 2nd pictures)

Now route the black wire along the underside of the SpurtBot, towards the left motor. The wire will cross the body of the SpurtBot to come up near the ‘-’ lead of the left motor.

Cut the black wire about ¼ inch past the length it needs to reach the ‘-’ contact of the left motor. Strip about 1/8 inch of insulation from the end of the black wire, and twist the leads.

Insert the stripped and twisted end of the black wire into the ‘-’ contact of the left motor, but don’t solder it yet.

Remove the batteries from the battery holder. Strip and twist the end of the wires if they are not already so prepared.

Insert the black lead from the battery holder into the same left motor ‘-’ contact as you previously inserted the black wire from the transistor emitter. Once again, this may be a tight fit.

Solder both black wires to the ‘-’ contact of the left motor. Be sure you have a good connection to both wires.

Press the black wire leading to the transistor emitter against the underside of the SpurtBot so it is flush. Hold it in place with a dab or two of hot glue.

Route the black wire leading to the battery holder between the two motors.

If the red lead of the battery holder is not already stripped, twisted and tinned, do so now. Use the needle nose pliers to put a little hook in the end of the wire. You will use this hook and the hook on the end of the other red wire to connect the battery to the SpurtBot.


















Step 14: Quick motor test

We are getting close now. Time for a quick test to be sure we’ve got it all right so far.

Insert the two AA batteries into the motor case. Take the SpurtBot to a location with good lighting and have something with a bright white and dark black surface to test against.

Connect the hooked red wire from the battery holder to the hooked red wire coming from the ‘+’ contact of the right motor. The left motor should start to spin counter-clockwise when viewed from the left side of the SpurtBot.

Note that the wheels themselves will not spin, because we haven’t connected the traction bands yet. You can feel which way the motor is spinning by touching the shaft with your finger.

The right motor may not be spinning, which is fine. Place the SpurtBot on a bright white, well-lit surface. The right motor should now spin clockwise as viewed from the right side of the SpurtBot.

Place the SpurtBot on a black surface. The right motor should immediately stop spinning, while the left motor continues to spin.

If all works as described above, great! Move on to the next step.

If there’s a problem, check everything and test again.







Step 15: Attach the battery holder

Picture of Attach the battery holder
Now you can hot glue the battery holder to the top of the motors. Make sure to place the battery holder with the wires to the rear of the SpurtBot.

Place the battery holder as far forward as you can. This will keep the weight to the front of the SpurtBot, so the sensor maintains contact with the surface that it drives on. The battery holder should be balanced left to right along the central axis of the SpurtBot.



Step 16: Cut the traction bands

Using a pair of sharp scissors, cut the ridged edge from the neck of the balloon.

Now cut two bands from the end of the neck, about the width of the bearings. Try to keep the cuts nice and straight.

You can fit the traction band onto the left bearing and motor shaft now. Start by stretching one band over the bearing on the opposite side from the motor shaft. Extend the band around the motor shaft.

Now carefully rotate the bearing. The band should tend to align itself onto the bearing and motor shaft.




Step 17: Thicken the right motor shaft

The right wheel needs to spin faster than the left when it is running. Because there is a small voltage drop across the transistor, the voltage applied to the right motor will always be a bit less than the left, which is connected directly to the battery.

However, by thickening the right motor’s shaft, we change the ratio of the diameters of the bearing and the shaft.

Effectively, you are changing the gear ratio. This will make the right motor spin faster. It will also have a little less torque, but it will be enough to move the SpurtBot, so that is OK.

Refer to the 1st picture. Find the smallest size shrink wrap tube you can fit over the right motor shaft. Measure a length that is just a tiny bit shorter than the length of the motor shaft, and cut the tubing with a pair of sharp scissors. Make your cut nice and square.

Place the cut tubing over the end of the right motor shaft.

Now you are going to use a lighter or other heat source to shrink the tubing. You should be very careful not to burn yourself, or to melt any parts of the Spurtbot.

Refer to the 2nd picture. Bend all wires out of the way. Think about where the flame of the lighter will go, and be careful not to melt the battery holder, bearing or anything except the shrink tubing.

Hold the SpurtBot in one hand, and apply the flame from the lighter briefly to the shrink tubing. It is better to apply the heat for a short time, and then go back a few times than it is to keep it on a long time.

Allow the shrink tubing to cool, then rotate the shaft 180 degrees and apply heat again. You should now have a nice tight fit.

Refer to the 3rd picture. Now find the smallest size shrink tubing that will fit over the last layer of tubing. Cut it to size and shrink it as before. You will need 3-4 layers of tubing. You may be able to use the same size tubing more than once, depending on how much it shrinks.

Check for the right size each time.

It is a good idea to test the SpurtBot once you have 3 layers of shrink tubing. You can always put another layer on later if you need it, but they are difficult to remove.

Refer to the 4th picture. Once you have 3 layers on the shaft of the motor and the shrink tubing is cool, you can install the traction band the same way you did for the left motor. Then got to the next step and test the SpurtBot. If it doesn’t turn right fast enough and stay close to the line, add another layer.

Step 18:

Picture of
Use a bright white surface with black electrical tape to make lines in a closed loop shape. You may need 2-3 widths of black tape to give your SpurtBot enough time to react to the sensor.

Start by testing inside the loop. Set the SpurtBot inside the circle so that it will move around the loop in a clockwise direction. When the sensor is on the black, the right motor will stop, and the SpurtBot will turn to the right. Now the sensor will cross over to the white background, and the right motor will spin faster than the left, turning the SpurtBot back towards the black line.

It should follow the line pretty closely, but may cut some tight corners.

Now place the SpurtBot on the outside edge of the black loop, facing so it will go around counter-clockwise. Once again, when the sensor is on the black, the right motor turns off and the SpurtBot begins to turn away from the loop. As soon as it hits the white background the right motor spins faster than the left, and the SpurtBot should turn back towards the line. If it follows the line pretty closely, all is well. If it doesn’t turn quite fast enough, try going back to Step 17 and adding one more layer of shrink tubing.

As you add layers, the right motor spins faster, but you are also reducing torque. If you add too many layers, the right motor may not have enough torque to move the SpurtBot.

Have fun!





superbotboy5 months ago
I found 'm28S VHAR' and it works pretty well.Thanks a ton for the recomendation and its a great instructable you've made so keep up the good work.Thanks again.
ignoblegnome (author)  superbotboy2 months ago

Thanks for sharing that info! I'm glad it worked out for you.

mraghib1 year ago
Sir one more question. What's a datasheet and how to study them? Sir i really need you help as i have just started to take an interest in robotics. Sorry for the too many quesyions i ask.
ignoblegnome (author)  mraghib1 year ago
If you are getting into robotics, then you will most definitely have to learn to research things on your own. If I feed you all the answers, you don't challenge yourself.

Here's your homework: Go find out what a datasheet is. Google can help you more quickly than I.
A datasheet is a document summarizing the performance and other technical characteristics of a product, machine, component (e.g. an electronic component), material, a subsystem (e.g. a power supply) or software in sufficient detail to be used by a design engineer to integrate the component into a system.

SOURCE:http://en.wikipedia.org/wiki/Datasheet
ignoblegnome (author)  mraghib1 year ago
See? That was easy. I bet it was no more difficult to find the answer for yourself than it was to ask me. In fact, you get your answer quicker that way.

Now that you know what a datasheet is, hopefully you are already looking up the datasheets in question and studying them to learn what you need.

I'll even give you some advice. You will usually see something labeled 'Absolute Maximum Ratings' or similar. Don't design to those specifications. For example, if the maximum current rating of the IR LED in the CNY70 is 50mA, you want to operate it well below that.

Look lower down in the datasheet for more ratings that are more typical for normal operations.

One more hint, when you look at the pin diagrams for part, be sure you know if you are looking at the part from the top or from the bottom. That's an easy mistake to make.
You told that i need to adjust the connection with the pins.
So for example- Pin 4 in QRD1114 is cathode, and pin 2 in CNY70 is cathode. So the connection that goes to pin 4 in this instructable which uses QRD1114 will go to pin 2 if i'm using CNY70.Am i right?

Here are some images:
QRD1114 pin layout.PNGcny70.gif
ignoblegnome (author)  mraghib1 year ago
Thanks for posting this detail in your question. It will both makes your question clear and provides a reference for others in the future. Nice work.

And yes, you have it correct. Also, keep in mind the image on the right of the CNY70 is the bottom view, as though you are looking down at the pins.
Thank You very much sir for your help. I've also subscribed to your posts on fb. Please make future instructables.
GJ-ThankYou04.gif
rimo1 year ago
sir i want to built this robot with cny70 please have a look but what kind of motors sould i choose im confused pliz reply siir
rimo rimo1 year ago
this is the link http://spurt.uni-rostock.de/en/
ignoblegnome (author)  rimo1 year ago
This Instructable is based on the SpurtBot concept described on that university's web page, and one of the originators assisted me in adapting the design to my needs.

As I've said before, the CNY70 should work OK with this design (in fact I know it does). You just have to make some adjustments to the connections. Read through the other comments; there is some good info.

For the motors, if you cannot find the ones I specify, please read the notes on the picture in Step 1. If you hover your mouse over the motors, I provide some guidance on what to look for.
mraghib1 year ago
Sir,
QRD1114 is not available to me,so can i use one of the following optical reflective sensors as a substitute:

TCRT-5000
RPR 220

Thank You
ignoblegnome (author)  mraghib1 year ago
Electrically, both the RPR 220 and TCRT-5000 look like good choices. I like the RPR 220 better, because it specifically states that it has a daylight filter on it, while the datasheet for the TCRT-5000 did not.

The problem both of these devices have is the detection distance. The RPR 220 needs 6mm, and the TCRT-5000 needs 12mm. Compare that to the CNY70, which needs 0.3mm (less than a mm).

Since the SpurtBot uses the detector as its front wheel/slider, the detection distance is critical.

If you want to try it, use the RPR 220, but add a small bead or other object to act as a front wheel. Be sure that the detector rests 6mm above the surface of the floor.

Let me know how it comes out!
rimo1 year ago
thnk you sir for reply
when i finished the robot i connect it to the battery just the left one turn and the right one never turn but when i use the 9v battery the 2 motors turn
ignoblegnome (author)  rimo1 year ago
It is possible that it didn't work with 2AA batteries because there was not enough current with the 75ohm resistor for the IR LED to light brightly enough.

However, with the 9V battery, I'm concerned you will burn out the CNY70 with too much current. Also, your robot will move much faster with 9V, so it will be harder to keep it on track.

I suggest you go back to 2AA batteries, but reduce the resistor to something like 58ohms. This will make the IR LED brighter by increasing the current for the same voltage. Make sure you use alkaline batteries, not rechargeables. Rechargeables only have about 1.2V each, which will not be enough. Of if your AA batteries were a little worn down, it might not work well. You

If you want to stick with a 9V battery, increase your resistor before you damage your CNY70. Look at the datasheet and you will see the maximum current is 50 mA, but you want to stay well below that. Typical voltage drop is 1.25V, but could be as high as 1.6V.

So let's say it is dropping the max voltage (best case), You subtract this from the battery voltage.

9V - 1.6V = 7.4V

So your resistor has 7.4V across it. Using Ohm's Law (I = V / R) , we can get the current through the resistor and IR LED.

Current (I) = 7.4V / 75 ohms = 0.0987 amps or 98.7 mA.
Way too high, even for the best case.

To pick your resistor, decide on your desired current. Let's try 35mA. Now rearrange the calculation to find the best resistor.

Resistance (R) = 7.4V / 0.035 A = 211.4 ohms. That's not a resistor value you can get, but you can get a 220 ohm resistor.

Remember I said this was 'best case'? If the IR LED only drops its typical 1.25V, will a 220 ohm resistor be safe? Let's see:

Current (I) = (9V - 1.25V) / 220 ohms = 0.03522, = 35.2 mA,
Still safe.

So in summary, either:
1) Go with two new alkaline AA batteries and reduce your resistor to 58 ohms. You could go a little lower. Use the calculations above to figure out how low is safe.
2) Try the 9V with a higher value resistor. 220 ohms should work well. Your robot will go faster so it may not work as well.
osh1141 year ago
Do they sell these things in radio shack and can i use some small r/c motors?
ignoblegnome (author)  osh1141 year ago
They do not sell these anywhere. You have to buy the parts yourself.
I have a new instructable with a different version of the SpurtBot. I provide links where you can buy the components for that one.
http://www.instructables.com/id/Introduction-SpurtBot-ShadowRunner

If you hover over the picture in Step 1 of this Instructable, there are some notes on selecting the motors.
psrivastava2 years ago
thanx for the reply.i have one more question .reflective sensor that u have told about is not available in my locality.is it possible to use a combination of infrared LED and infrared phototransistor at the place of reflective sensor?
what will be the changes i would have to do in the circuit if i uses that combination.
please reply soon sir.
ignoblegnome (author)  psrivastava2 years ago
See if you can find the CNY70, which is another reflective sensor package that is similar to the QRD1114.

Alternately, you could use descrete infrared LED and phototransistors. The QRD1114 is just small versions of these components in a nice case. The case also provides some ambient light filtering.

So if you go with the descrete components, you may want to place a piece of shrink tubing over the phototransistor to help block some of the ambient light.

You would connect them just as shown in the schematic.

An extremely informative and interesting 'ible. The only problem i'm facing is that i'm not able to find either QRD1114 or CNY70 reflective sensor package.

As mentioned above,i understand that both QRD1114 & CNY70 packages contain a IR source & a two terminal Photo transistor(or Photo Diode maybe). So, it would be extremely helpful to me if you could mention the individual component number(e.g QRD1114 Reflective Sensor) of the combination of IR source & a two terminal Photo transistor that you say can replace the QRD1114 package.
ignoblegnome (author)  eltro2 years ago
The QRD and CNY packages are very nice because they not only hold the component in the correct position, they filter out interference from ambient light.

However, you can often find an IR emitter and detector sold as a pair. You may need to use some shrink tubing to enclose the detector and protect it from interference.

I don't have specific components to recommend, but see what you can find and use Ohm's Law and the values for the IR emitter forward voltage and the voltage of your supply (3V if you use two AA batteries as in this instructable) to calculate an appropriate current limiting resistor.

sir what if there is no supply of qrd 1114 ., what is your suggestion in the replacement of the sensor? im from philippines. im a student, and its hard for me to look for the qrd 1114 sensor., there is an electronic shop who sells ldr., i dont know if ldr and led are ok to be raplaced., sir help me., this robot of yours is my project in order to pass this subject., i am hoping for your early reply., thanks

superbotboy5 months ago
can i just use any other npn transistor ? Pls rply fast. Have to submit it this month.
instead of bc 337
ignoblegnome (author)  superbotboy5 months ago
You can certainly substitute a different npn transistor, but not just any npn transistor. Check the datasheet for the bc337 (look it up) and search for a transistor you have access to that has similar electrical characteristics. Make sure the transistor you choose has enough collector current capacity (Ic) to drive your motor. You also want a fairly low voltage drop from the collector to the emitter (Vce), low base-emitter turn on voltage (Vbe) and a decent DC current gain (hfe).
Also be aware that not all npn transistors have the same pin out, so you may need to adjust the wiring to be sure each pin (collector, emitter and base) are connected to your circuit correctly.
Good luck. Let me know if you find an alternative transistor that works well!
argha halder8 months ago
well done!bravo!fabulous!fantastic!magnificent!excellent!great!very best!
9876me8 months ago
Great idea thanks!
what is the alternative of the CNY70

IN MY AREA CNY80 ,, CNY 71 ,, CNY17 ETC ARE AVAILABLE


can i use any of these?
ignoblegnome (author)  altaf hussain1 year ago
The CNY80, CNY71 and CNY17 are all optocouplers. While there are some internal similarities to the CNY70, these devices allow you to have an out put that is electrically isolated from the input. There's no Infrared (IR) output and detection external to the package, so it will not due for detecting a line. You cannot use any of these devices as a replacement of the CNY70.

You are looking for something that has an IR emitter and and IR detector.

The QRD and CNY packages are very nice because they not only hold the IR emitter and detector in the correct position, they filter out interference from ambient light.

However, you can often find an IR emitter and detector sold as a pair. You may need to use some shrink tubing to enclose the detector and protect it from interference.

I don't have specific components to recommend, but see what you can find and use Ohm's Law and the values for the IR emitter forward voltage and the voltage of your supply (3V if you use two AA batteries as in this instructable) to calculate an appropriate current limiting resistor.
malucken1 year ago
Hey ignoblegnome
We tried to build the SPURTbot.
But now the right wheel is not running, whether on bright or on dark surfaces.
We tested the sensor with a camera, the LED is working.
Could the transistor in the sensor be broken, or the other transistor?
we lookin forward to your help :3
Hey again :)

Thank you very much for your incredible fast answer! :D
We'll try it soon! :) but first we have to buy new sensors. we broke ours as we tried to change the transistor. :\
btw. does it matter, if we are using the CNY70 sensor?
ignoblegnome (author)  malucken1 year ago
You can use the CNY70, but the pinout is different. There are several comments (and answers) about that in the comments, so take a read through.
ignoblegnome (author)  malucken1 year ago
Did the right wheel used to work, and it has now stopped working? Or did it never work?

Here are some troubleshooting steps to try:
1) Make sure your batteries are fresh and supplying full voltage.
2) Double check all of your connections. Look for shorts (stuff making contact where it shouldn't) or open circuits from breaks or cold solder joints.
3) Confirm the motor is OK by briefly applying battery voltage directly to the right motor.
4) With a volt meter, check the voltage relative to ground (the battery negative lead) of the point where the base of the BC337 is connected to the QRD-1114. When the sensor sees a reflective surface, this voltage should go HIGH (close to the battery + voltage). If this works, your QRD-1114 is fine.
5) Try applying battery + voltage at the base of the BC337. Does this turn the motor on? If it does, your BC337 is fine. If not, check the BC337's connections to the motor and to ground. If the connections are fine, but applying + voltage to the base didn't turn the transistor on, you probably have a bad transistor.
mraghib1 year ago
Sir, how to check whether the CNY70 and bc337 is working or not?
ignoblegnome (author)  mraghib1 year ago
If you have completed construction you can test as described in Step 18.

If you are still constructing, here are a few things to try.
1) If you own a digital camera, power on the robot and view the lenses of the sensor through your camera. The camera can see infrared light, even though your eye cannot see it directly. If you see a bluish light coming from the sensor, you know the IR LED is working.

2) The left wheel should always run. The right wheel should only run when the robot's sensor sees a reflection from a bright white surface. If the bc337 transistor is and the sensor are working, the right wheel should turn on when on a white surface, and turn off when on a dark surface or if there is no surface to reflect any IR.
rama8411 year ago
are its will be okay when i change QRD1114 to TCRT5000L???
reply please...
thanks :)
ignoblegnome (author)  rama8411 year ago
Looking at the datasheet (which is where you should look for your answer), I can see that the TCRT5000L is electrically similar. However, you will have to make some adjustments.
the TCRT5000L has a sensing distance of 12mm. There's a diagram in the datasheet that shows this pretty clearly. So you cannot use this device as the front slider for the SpurtBot. You could use a 12mm bead or other round-bottomed object as the slider, and then mount the TCRT5000L just in front or behind the bead.
You will also need to adjust the circuit to get the right amount of current through the IR LED. I think the TCRT5000L wants to operate at a higher current (60 mA max, so maybe aim for 45-50 mA). You increase the current by reducing the value of the resistor. I suggest a 33 ohm resistor.
mraghib1 year ago
Sir in your reply to @psrivastava you told that,"You would connect them as shown in the schematic" So with 'them' which thing did you refer to? The combination of infrared LED and infrared phototransistor or the CNY70?
ignoblegnome (author)  mraghib1 year ago
Yes.
mraghib1 year ago
Thank You Sir for replying
but what about the connections with the RPR 220? Do they need to change? Sir if it needs to change , sir then please tell me how to do it, as i cannot make changes on my own.

THANK YOU
Pro

Get More Out of Instructables

Already have an Account?

close

PDF Downloads
As a Pro member, you will gain access to download any Instructable in the PDF format. You also have the ability to customize your PDF download.

Upgrade to Pro today!