vb.net read barcode from camera COMPUTER CONTROLLED LINE FOLLOWING in Software

Maker Denso QR Bar Code in Software COMPUTER CONTROLLED LINE FOLLOWING

33.2.1 COMPUTER CONTROLLED LINE FOLLOWING
Recognizing QR Code ISO/IEC18004 In None
Using Barcode Control SDK for Software Control to generate, create, read, scan barcode image in Software applications.
Denso QR Bar Code Generation In None
Using Barcode creator for Software Control to generate, create QR Code 2d barcode image in Software applications.
It is quite easy to add and program computer control for a line-following robot. The following program was written for a three sensor line following robot with the distance between
Read QR Code JIS X 0510 In None
Using Barcode recognizer for Software Control to read, scan read, scan image in Software applications.
QR-Code Generator In C#
Using Barcode drawer for VS .NET Control to generate, create QR Code 2d barcode image in Visual Studio .NET applications.
R2 10K R1 270 4 IC1 339 (1/4) LED1 Q1 R3 10K 5+ 2
Quick Response Code Printer In .NET Framework
Using Barcode printer for ASP.NET Control to generate, create QR image in ASP.NET applications.
Paint QR Code In .NET Framework
Using Barcode drawer for VS .NET Control to generate, create QR-Code image in VS .NET applications.
R4 10K Output
Creating QR Code In Visual Basic .NET
Using Barcode creator for .NET framework Control to generate, create QR Code JIS X 0510 image in Visual Studio .NET applications.
Draw USS-128 In None
Using Barcode drawer for Software Control to generate, create GS1-128 image in Software applications.
FIGURE 33-4 Connecting the LED and phototransistor to an LM339 quad comparator IC. The output of the comparator switches between HIGH and LOW depends on the amount of light falling on the phototransistor. Note the addition of the 10K pull-up resistor on the output of the comparator. This is needed to assure proper HIGH/LOW action.
Bar Code Printer In None
Using Barcode encoder for Software Control to generate, create bar code image in Software applications.
Bar Code Generator In None
Using Barcode drawer for Software Control to generate, create barcode image in Software applications.
NAVIGATION
Creating Data Matrix ECC200 In None
Using Barcode printer for Software Control to generate, create DataMatrix image in Software applications.
Drawing GTIN - 12 In None
Using Barcode generation for Software Control to generate, create UPC Symbol image in Software applications.
R1 270
Encoding ISSN - 10 In None
Using Barcode drawer for Software Control to generate, create ISSN image in Software applications.
Draw Barcode In None
Using Barcode generator for Font Control to generate, create barcode image in Font applications.
R2 10K 4 3 IC1 339 (1/4) 2
Barcode Recognizer In .NET
Using Barcode Control SDK for ASP.NET Control to generate, create, read, scan barcode image in ASP.NET applications.
Code 128 Code Set C Creator In None
Using Barcode printer for Office Excel Control to generate, create Code 128B image in Office Excel applications.
R8 10K
Barcode Drawer In Objective-C
Using Barcode generator for iPad Control to generate, create barcode image in iPad applications.
Code 128 Code Set C Generation In None
Using Barcode creation for Font Control to generate, create Code 128C image in Font applications.
IC3 7400 (1/4)
Recognizing Bar Code In Visual C#.NET
Using Barcode Control SDK for Visual Studio .NET Control to generate, create, read, scan barcode image in .NET applications.
Print EAN-13 Supplement 5 In Objective-C
Using Barcode maker for iPad Control to generate, create EAN 13 image in iPad applications.
14 3 To Relay #1
LED1
R3 10K
14 IC2 7486 (1/4) +5V +5V 1 2 7 3
R4 270
R5 10K 6 -
3 IC1 339 (1/4)
R7 10K 1
IC3 7400 (1/4) 4 5
6 To Relay #2
LED2
R6 10K
FIGURE 33-5 Wiring diagram for the line-tracing robot. The outputs of the 7400 are routed to the relays in Fig. 33-6.
the sensors being about 75 percent of the width of the line which means that as the line changes, two sensors are active at any given time, allowing the robot to slow down on that side rather than turn off the motor completely. Slowing down a side of the robot is accomplished by decreasing the PWM duty cycle on that side s motor by 50 percent you will see that the turn logic is replicated twice in the following program, with differing values for the slow turns to run the motors more slowly than if a hard turn is required.
' ' ' ' ' ' ' ' ' ' ' ' ' BS2 Line Follow - Line Following Software This software takes the inputs from three infrared detectors to control a robot following a white line on a black surface. A simple 30 Hz PWM has been created for the robot with the following responses to the inputs: Left IR 1 0 0 1 Middle IR 0 0 1 0 Right IR 1 1 1 0 Left Motor Full Half Zero Full Right Motor Full Full Full Half
33.2 FOLLOWING A PREDEFINED PATH: LINE TRACING
Ground
Ground
+5V D1 1N4003
+5V D2 1N4003
From Detector # 1
From Detector# 2
FIGURE 33-6 Motor direction and control relays for the line-tracing robot. You can substitute the relays for purely electronic control; refer to Chap. 18.
TABLE 33-1 IC1 IC2 IC3 Q1, Q2 R1, R4 R2, R5, R7, R8 R3, R6 LED1, LED2 Misc.
Parts List for Line Tracer LM339 quad comparator 7486 quad exclusive OR gate IC 7400 quad NAND gate IC Infrared-sensitive phototransistors 270 resistors 10k resistors 10k potentiometers Infrared LEDs Infrared filter for phototransistors (if needed)
TABLE 33-2 RL1, RL2 D1, D2
Parts List for Relay Control DPDT fast-acting relay; contacts rated 2 A or more 1N4003 diodes
NAVIGATION
' ' ' ' ' ' ' ' ' ' '
1 0 1
1 0 1
0 0 1
Full Zero Zero
Zero Zero Zero
A white line perpendicular to the following line (all three Sensors 0) is the "Stop" line, and the robot will stop at this position. When the robot loses the line (all three Sensors 1) the robot stops myke predko 05.08.29
'{$STAMP BS2} '{$PBASIC 2.5} ' Mainline LeftIR PIN MiddleIR PIN RightIR PIN LeftMotor PIN RightMotor PIN
0 1 2 4 5 ' Motors Output/Stop
LOW LeftMotor LOW RightMotor do
IF (LeftIR = 0) then IF (MiddleIR = 0) then IF (RightIR = 0) then LeftMotor = 0 ' At Stop Line RightMotor = 0 else LeftMotor = 0 ' Slow Turn Left RightMotor = 1 endif ELSE ' Only Left Sensor on Line LeftMotor = 0 ' Hard Turn Left RightMotor = 1 ENDIF ELSE IF (RightIR = 0) THEN IF (MiddleIR = 0) then LeftMotor = 1 ' Slow Turn Right RightMotor = 0 else LeftMotor = 1 ' Hard Turn Right RightMotor = 0 endif ELSE ' Only Left Sensor on Line IF (MiddleIR = 0) then LeftMotor = 1 ' Straight Down the Middle RightMotor = 1 else LeftMotor = 0 ' Lost Line, Stop RightMotor = 0 ENDIF ENDIF endif
33.3 WALL FOLLOWING
PAUSE 15
Hold Motor State for 1/60th s
IF (LeftIR = 0) THEN IF (MiddleIR = 0) THEN IF (RightIR = 0) THEN LeftMotor = 0 ' At Stop Line RightMotor = 0 ELSE LeftMotor = 1 ' Slow Turn Left RightMotor = 1 ENDIF ELSE ' Only Left Sensor on Line LeftMotor = 0 ' Hard Turn Left RightMotor = 1 ENDIF ELSE IF (RightIR = 0) THEN IF (MiddleIR = 0) THEN LeftMotor = 1 ' Slow Turn Right RightMotor = 1 ELSE LeftMotor = 1 ' Hard Turn Right RightMotor = 0 ENDIF ELSE ' Only Left Sensor on Line IF (MiddleIR = 0) THEN LeftMotor = 1 ' Straight Down the Middle RightMotor = 1 ELSE LeftMotor = 0 ' Lost Line, Stop RightMotor = 0 ENDIF ENDIF ENDIF PAUSE 15 LOOP ' ' Hold Motor State for 1/60th Second Repeat
The resulting motion is surprisingly smooth and follows the line very accurately with very few excursions to the hard turn required. To help you see the operation of the robot, you might want to add some LEDs to the BS2 s I/O pins to parrot the IR line sensor inputs and the motor control outputs.
Copyright © OnBarcode.com . All rights reserved.