Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Design a finite state machine that steers a car on a track. The track is colored as a very thick black line on a large

image text in transcribed

Design a finite state machine that steers a car on a track. The track is colored as a very thick black line on a large white paper. Under the normal conditions, the car would ride directly over the thick black line. The car has two optical sensors (LR) that can detect if the car is on the track, drifting to the left/right, or of the track completely. For each of the sensors, the value 0 indicates that the sensor can see the black track, and the value 1 indicates that it can't see the black track and off the track. So, for example, LR = 00 means that the car is directly over the black track. A value of LR=01 means that the left sensor can see the black track, but the right one cannot see the black track, which means the car is off to the right of track. Based on the two sensors, we can detect that there are four states for the car: 1) car on the track (OT), 2) off to the right of track (RT), 3) off to the left of track, and 4) totally off the track (FT). To steer the car with L and R inputs, you can control a 2-bit output, X and Y. However, the car can't drive backward. So, you only have 3 commands (00, 01, 10) with the following encodings/actions: Input LR Output Code( XY) 00 00 Action Drive straight Turn Left Turn Right Turn Right or Turn Left 10 01 (01 or 10) you decide 10 Draw the state diagram for a finite state machine (FSM) that uses the two inputs (LR) to determine how to steer the car within the four states. Then, use positive-edge triggering D FFs to design this FSM. Draw your circuit. You should consider the special case when the car first veers to the left or right) and then comes completely off the track. (Hint: Think of the easiest way to steer it back to the track). Design a finite state machine that steers a car on a track. The track is colored as a very thick black line on a large white paper. Under the normal conditions, the car would ride directly over the thick black line. The car has two optical sensors (LR) that can detect if the car is on the track, drifting to the left/right, or of the track completely. For each of the sensors, the value 0 indicates that the sensor can see the black track, and the value 1 indicates that it can't see the black track and off the track. So, for example, LR = 00 means that the car is directly over the black track. A value of LR=01 means that the left sensor can see the black track, but the right one cannot see the black track, which means the car is off to the right of track. Based on the two sensors, we can detect that there are four states for the car: 1) car on the track (OT), 2) off to the right of track (RT), 3) off to the left of track, and 4) totally off the track (FT). To steer the car with L and R inputs, you can control a 2-bit output, X and Y. However, the car can't drive backward. So, you only have 3 commands (00, 01, 10) with the following encodings/actions: Input LR Output Code( XY) 00 00 Action Drive straight Turn Left Turn Right Turn Right or Turn Left 10 01 (01 or 10) you decide 10 Draw the state diagram for a finite state machine (FSM) that uses the two inputs (LR) to determine how to steer the car within the four states. Then, use positive-edge triggering D FFs to design this FSM. Draw your circuit. You should consider the special case when the car first veers to the left or right) and then comes completely off the track. (Hint: Think of the easiest way to steer it back to the track)

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Data And Information Quality Dimensions, Principles And Techniques

Authors: Carlo Batini, Monica Scannapieco

1st Edition

3319241060, 9783319241067

More Books

Students also viewed these Databases questions

Question

3. You can gain power by making others feel important.

Answered: 1 week ago

Question

Write down the circumstances in which you led.

Answered: 1 week ago