0% found this document useful (0 votes)
89 views2 pages

Act 4

This document provides instructions for programming a model electric car to follow a line using two IR sensors and two continuous servos. The car will use the IR sensors to detect the line and the servos to steer left or right as needed. Programming involves checking that the microcontroller board and sensors are recognized, testing the IR sensors to understand their output values, functionally testing the servos at different positions, and then programming the final code to control the servos based on IR sensor input to follow the line.

Uploaded by

api-445959198
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
89 views2 pages

Act 4

This document provides instructions for programming a model electric car to follow a line using two IR sensors and two continuous servos. The car will use the IR sensors to detect the line and the servos to steer left or right as needed. Programming involves checking that the microcontroller board and sensors are recognized, testing the IR sensors to understand their output values, functionally testing the servos at different positions, and then programming the final code to control the servos based on IR sensor input to follow the line.

Uploaded by

api-445959198
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

The idea of this practice is to create a model electric car able to follow a line.

1.- Contextualization

What is a fossil fuel?


What are the fossil fuels?
What are the effects the fossil fuels produce?
Possible alternatives to fossil fuels.

2.- Programming.

Materials. For doing this practice, you will need:

• Motherboard + blue wire.


• 2 IR sensors
• 2 Continous servo
• small wires for connecting the components

Initical checks

• Check that the computer recognizes the motherboard and the serial port (blue
wire).

IR sensor

• Is it analog or digital?
• Read its values through the serial port (using Arduino code if necessary)
• What does it mean if its value is 0?
• And i it is 1?
Servo
• To know how the servo works, you have to do different functional testings.

In a loop forever In a loop forever In a loop


- Fixed it at 90º - Fixed it at 90º forever - Fixed it
If it's not - wait 3 seconds at 0º - wait 3
stopped tell it to -Fixed it at 0º seconds -Fixed
your teacher - wait 3 seconds it at 180º -
because your - Fixed it at 90º wait 3 seconds -
servo needs to - wait 3 seconds Fixed it at -90º -
- Fixed it at 180º wait 3 seconds
- wait 3 seconds - Fixed it at 180º

Final programming
• Now you know how the components work and what you want to do in each range of
values, you are ready to program.

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy