You are on page 1of 13

I.

PROBLEM DESCRIPTION
We decided to show how the controller of a black line following robot which can avoid obstacles
(preferably not to be used on black /dark surfaces) would function. For our inputs, we used 4 sensors,
namely the L(Left Sensor), F(Forward Sensor), R(Right Sensor), and O(Obstacle Sensor). These sensors
would either detect the presence of the black line it is programmed to follow(L,F,R ) or an obstacle to
which it must avoid. After detection of a line, a specific motor — either the S(Sinistral)/ Left Motor,
D(Dextral)/ Right Motor, or both— which we used as our outputs activates and begins to move as long
as it is able to detect the black line. For cases when the O sensor detects an obstacle, it initiates a
sequence of moves, which is the following: Short Forward motion, Turn Right, Short Forward motion,
Turn Left until it detects a line. Though, there may be cases when there is an obstacle to where the
robot is programmed to turn(example: left). For these scenarios, the robot is programmed to prioritize
execution of the direction it is supposed to head, then begin to initiate the Avoidance Sequence. An
example would be when the L sensor detects a line at the left direction and the O sensor detects an
obstacle as well. In this case, the robot will turn left then immediately begin the avoidance sequence.
(The course is designed so that there is a sufficient amount of allowance for the robot to move into a
direction and activate the sequence. The last output, the accelerator, activates when the robot is
moving forward and detects no obstacle, but then immediately turns off if otherwise. Additionally, we
gave a default instruction for the robot to follow when more than 1 sensor detects a black line.

II. INPUT AND OUTPUT VARIABLES


L, F, R and O are the sensors, set to 1 if they detect a black line, 0 if otherwise
S and Dare the motors, set to 1 if they turn on/activate, 0 if otherwise
A is the accelerator, set to 1 if turns on, 0 if otherwise

III. TRUTH TABLES


Inputs Outputs Movement of Robot
L F R O S D A

0 0 0 0 0 0 0 Stop/Halt

0 0 0 1 0 0 0 Initiates Avoidance Sequence


(Short Forward motion, Turn
Right, Short Forward motion,
Turn Left until it detects a
line)

0 0 1 0 0 1 0 Go Right

0 0 1 1 0 1 0 Go Right then initiate


avoidance sequence

0 1 0 0 1 1 1 Go forward and accelerate

0 1 0 1 1 1 0 Go Forward then initiate


avoidance sequence

0 1 1 0 1 1 1 Go Forward and accelerate

0 1 1 1 1 1 0 Go Forward then initiate


avoidance sequence

1 0 0 0 1 0 0 Go Left

1 0 0 1 1 0 0 Go Left then initiate


avoidance sequence

1 0 1 0 0 1 0 Go Right

1 0 1 1 0 1 0 Go Right then initiate


avoidance sequence

1 1 0 0 1 1 1 Go Forward and accelerate

1 1 0 1 1 0 0 Go Forwardthen initiate
avoidance sequence

1 1 1 0 1 1 1 Go Forward and accelerate

1 1 1 1 1 1 0 Go Forward then initiate


avoidance sequence

IV. K-MAPS

LF LF
00 01 11 10 00 01 11
RO
RO

0 1 1 1 0 1 1 0
00 00

0 1 1 1 0 1 0 0
01 01

11 0 1 1 0 11 1 1 1 1

10 0 1 1 0 10 1 1 1
1

S=F+LR’
D=R+L’F+FO’

LF
00 01 11
RO

0 1 1 0
00

01 0 0 0 0

11 0 0 0 0

10 0 1
1 0

A=FO’

V. BLOCK DIAGRAM

S(inistral) Block
F(orward) Sensor
L(eft) Sensor S (Motor)
R(ight) Sensor

The S Block depends on the inputs from The Forward Sensor(detects a


forward line), Left Sensor(Detects a Left line), and Right Sensor(Detects a
right line) to determine if the S-motor/Left Motor would activate to generate
movement. This block may function simultaneously with another block like
the D block to perform a specific motion like moving forward.Therefore, the
robot may either be moving to the left or moving forward when this block
initiates and activates

D(extral) Block
D Motor
O(bstacle) Sensor

The D Block depends on the inputs from The Forward Sensor(detects a


forward line), Left Sensor(Detects a Left line), Right Sensor(Detects a right
line), and O(bstacle) Sensor(Detects if an obstacle exists) to determine if the
D-motor/Right Motor would activate to generate movement. This block may
function simultaneously with another block like the S block to perform a
specific motion like moving forward.Therefore, the robot may either be
moving to the right or moving forward when this block initiates and activates

A(ccelerator) Block
Accelerator

The A Block depends on the inputs from the Forward Sensor and Obstacle
Sensor to determine if the Accelerator activates. It kicks in under 2
conditions: 1.) When the robot’s F sensor detects a forward line and 2.) The
O sensor detects no obstacle. This block can function simultaneously with
the other 2 blocks.
BLOCK ASSIGNMENT
S-Block -Alliyah Suyo
D-Block- Raquel Villarivera
A-Block- Sophia Dela Cruz

VI. LOGIC GATE DESIGN OF BLOCKS

Logic Gate Implementation-Whole Circuit


S-Block

D-Block

A-Block
VII. DECODER/MULTIPLEXER DESIGN OF BLOCKS
Complete

S-Multiplexer
D-Multiplexer

A-Multiplexer
F- Forward Sensor
O-Obstacle Sensor
IX. Timing Delay Comparison of Logic Gate and Decoder/Multiplexer Implementations
S-Block
Logic Gate: Tg1+Tg2+Tg2=1+1.5+1.5=4 ns
Multiplexer: 3(Tg1)+10(Tg4)+(Tg2)=3(1)+10(3)+1.5=34.5 ns
D-Block
Logic Gate: Tg1+Tg1+Tg2+Tg2+Tg3=1+1+1.5+1.5+2.5=7.5ns
Multiplexer:4(Tg1)+21(Tg4)+16(Tg2)=4(1)+21(3)+16(1.5)=91ns
A-Block
Logic Gate: Tg1+Tg2=1+1.5=2.5 ns
Multiplexer:2(Tg1)+4(Tg3)+Tg4=2(1)+4(2.5)+3=15ns

X. Power Comparison of Logic Gate and Decoder/Multiplexer


S-Block
Logic Gate: P1+P2+P2=1+2+2=5 nW
Multiplexer:3(P1)+10(P4)+(P2)=3(1)+10(4)+2=45nW

D-Block
Logic Gate: P1+P1+P2+P2+P3= 1+1+2+2+3=9 nW
Multiplexer:4(P1)+21(P4)+16(P2)=4(1)+21(4)+16(2)=104nW

A-Block
Logic Gate: P1+P2= 1+2=3 nW
Multiplexer:2(P1)+4(P3)+P4=2(1)+4(3)+4=18 nW
XI. Conclusion
One of our conclusions is that the A-Block is considerably the best of the three blocks by
standards of efficiency - it consumes the least amount of power and has the shortest time delay. Its
simple design is the core of its efficiency.

Bouncing off this, we also concluded that the more inputs you add, the greater the total time
delay and power consumption. This can be clearly seen between the A and D blocks.

The A-Block has 2 inputs, a logic-gate-delay of 2.5 nanoseconds, and a power consumption
value of 3 nanowatts. The D-Block, on the other hand, has 4 inputs. It has a delay of 7.5 nanoseconds
and a power consumption of 9 nanowatts. [state actual difference (5ns, 6nW) if necessary]

In addition to this, multiplexers will always produce greater sums of time delay and power
consumption (same as input). For example, in the S-Block, the delay for a logic-gate circuit is 4
nanoseconds. In comparison, the delay for a multiplexer circuit is 34.5 nanoseconds - more than 8
times larger than the first set-up.

The S-Block's power consumptions are 5 and 45 nanowatts for logic gate and multiplexer
implementations respectively. This multiplexer consumes nine times more power than its logic gate
implementation.

Lastly, we learned that electronics is complex in the sense that it takes time to fully carry out.
Its set-up and implementation both have to be organized and correct. The process of building circuits
isn't one that's derived from memorization - which is why committing errors in this area is not fun.
One has to understand what they intend to do.

You might also like