[Home]Line Follower Carts

HomePage | RecentChanges | Preferences | My Website home page

Showing revision 9

Line follower Cart

eBay had a line follower cart kit.

It has two motors and a two light sensors and LEDS and a LM393 comparator.

It has a circuit:

There are two comparators, one for each motor, but the + and - inputs are wired contral making it look like a comparator with an inverter on the output.

If they are comparators, then only one motor would be powered up, but when the Light Dependent Resistors are dark, both motors are running!

This means it is more that a comparator.

We can put together this truth table.

sensor1 sensor2 motor1 motor2
dark dark on on
bright brighter off on
brighter bright on off

The comparator needs the inputs to be about 1.5V below the positive supply.

It is important to consider the comparator circuit.

https://www.ti.com/product/LM393

The LM393 uses an open collector output that sinks current to turn on the motor.

The comparator needs the inputs to be about 1.5V below the positive supply.

When the Light Dependent Resistors are dark, both motors are running.

The +ve and -ve inputs rise to within 2V of the Positive rail.

When the LM393 is powered up on a breadboard, with a 5V supply, and and +ve and -ve inputs floating, the output pin sinks about 25mA limited by the 80uA and gain of the ouput transistor. This is enough to turn on the motors using the drive transistor.

I swapped the 10 Ohm resistors to 220 Ohm as I was worried that 3V / 10ohms would be 300mA, but I did not understand the circuit of the LM393 comparator at the time.

Adjustments

We can put together this truth table.

sensor1 sensor2 motor1 motor2
dark dark on on
bright brighter off on
brighter bright on off

There are two trim pots to adjust for battery voltages, and ambient light levels.

Make sure it turns in circles on a bright surface, and goes straight on dark surface.

Now the fun starts!

You do not need to follow a line.

I found a picture frame with a strong graphic contact and it had a lot of fun exploring the dark blue areas and going around in circles on the white borders.

Modifications.

The two iluminating LEDs could be more robustly attached. I welded / soldered them to the PCB and knocked them and lifted the PCB tracks.

If I have put a blob of solder on the top of the PCB, or bent the LED leads over it would be more robust. You may need to adjust the height. It comes with a bolt with a shiny round nut that can be used to trip the height.

Conclusions

I soldered the kit and it worked and followed the test track on the A4 instruction sheet.

All the instructions were in Chinese.

An iPad was used to translate the Chinese. iPads Translate App came to the rescue.

You can scan the instructions with the camera and used OCR to read the Chineese characters.

Well worth the money. It could be entertaining and fun.

References

https://www.ebay.co.uk/itm/143755630164

eBay Listing:- https://www.ebay.co.uk/itm/134026221306?_trkparms=amclksrc%3DITM%26aid%3D111001%26algo%3DREC.SEED%26ao%3D1%26asc%3D20160908105057%26meid%3Dc8edfac1ab0f45af9da9be12bfc937e6%26pid%3D100675%26rk%3D1%26rkt%3D15%26sd%3D134026221306%26itm%3D134026221306%26pmt%3D1%26noa%3D1%26pg%3D2380057%26brand%3DUnbranded&_trksid=p2380057.c100675.m4236&_trkparms=pageci%3A3d800370-bdc1-11ec-8468-f25ba14129cb%7Cparentrq%3A33ff6f6a1800a0acada7a94dfffdf9c2%7Ciid%3A1

https://www.ti.com/product/LM393

7.3 Feature Description The comparator consists of a PNP darlington pair input, allowing the device to operate with very high gain and fast response with minimal input bias current. The input Darlington pair creates a limit on the input common mode voltage capability, allowing the comparator to accurately function from ground to VCC– 1.5 V input. Allow for VCC– 2 V at cold temperature. The output consists of an open drain NPN (pull-down or low side) transistor. The output NPN sinks current when the negative input voltage is higher than the positive input voltage and the offset voltage. The VOL is resistive and scales with the output current. See Figure 6-3 for VOL values with respect to the output current.

https://www.ti.com/lit/ds/symlink/lm393.pdf?ts=1650101404322&ref_url=https%253A%252F%252Fwww.ti.com%252Fproduct%252FLM393%253Futm_source%253Dgoogle%2526utm_medium%253Dcpc%2526utm_campaign%253Dasc-null-null-GPN_EN-cpc-pf-google-wwe%2526utm_content%253DLM393%2526ds_k%253DLM393%2BDatasheet%2526DCM%253Dyes%2526gclid%253DEAIaIQobChMIwZjezKKY9wIV2IjVCh38cgZMEAAYASAAEgKjmPD_BwE%2526gclsrc%253Daw.ds


HomePage | RecentChanges | Preferences | My Website home page
This page is read-only | View other revisions | View current revision
Edited April 16, 2022 8:48 pm by dougrice.plus.com
Search: