C - Smoother Line Following

Similar documents
Graphing Your Motion

INTERMEDIATE PROGRAMMING LESSON

LEGO MINDSTORMS PROGRAMMING CAMP. Robotics Programming 101 Camp Curriculum

Perform in the spotlight

HS-509 VIBRATION TRIP MODULE

Lecture 12: State Machines

EDL8 Race Dash Manual Engine Management Systems

Working with CSWin32 Software

istep STEPPER MOTOR PUMP

Lego Robotics Module Guide

istep STEPPER MOTOR PUMP

Trial version. Analogue to Digital Conversion in Distance Measurement

Instruction Manual for Electronic Blowers and Flashboards

Variable Frequency Drive (VFD) Control Lab

A Motor can be in many groups, by assigning additional channel# on it.

o The 9S12 has a 16-bit free-running counter to determine the time and event happens, and to make an event happen at a particular time

o The 9S12 has a 16-bit free-running counter to determine the time and event happens, and to make an event happen at a particular time

Tiptop audio z-dsp.

Introduction. The Clock Hardware. A Unique LED Clock Article by Craig A. Lindley

Technology Control Technology

YAYUMA AWARENESS LINE PROCESSOR

BASCOM-TV. TV Code Features: ICs supported: BASCOM versions:

Topic D-type Flip-flops. Draw a timing diagram to illustrate the significance of edge

THEATRE DESIGN & TECHNOLOGY MAGAZINE 1993 WINTER ISSUE - SOUND COLUMN WHITHER TO MOVE? By Charlie Richmond

CARLO GAVAZZI Automation Components

Meet Edison. This is Edison, the programmable robot. What is a robot? A robot is a machine that can be made to do a task on its own.

Session 1 Introduction to Data Acquisition and Real-Time Control

Q Light Controller+ Positions and EFX explained

(Skip to step 11 if you are already familiar with connecting to the Tribot)

M5-H002. Multiview T-35. DVB-T to PAL / 5 channels on all TV s

Conversations with Logo (as overheard by Michael Tempel)

KNX Dimmer RGBW - User Manual

SetEditGalaxis for Galaxis Easy World and compatible

Configuring Monitors for FMS. A user guide

Laser Ultra-Short Throw Projector

Herzlich Willkommen Bienvenue Welcome. General Basics JUMO Screen Recorders. Manfred Schleicher

SYSTEM DESCRIPTION 2.1 MAIN DISPLAY SCREEN 2.2 SYSTEM DIAGNOSTIC MENU 2.6 SETTING AND OPERATING INSTRUCTIONS 2.10 TO SET DEFAULT PARAMETERS 2.

Writing Programs INTRODUCING THE BASIC STAMP EDITOR 2 SCRIBBLER HARDWARE PROGRAMMING CONNECTIONS 8 BLINKING THE LIGHTS WITH PROGRAM LOOPS 9

Video SystemVideo System

Basic, cost-effective motor control in one unit: MOVITRAC 07.

Introducing IMPACKT Transitions for Final Cut Pro X

SkyLink - Refers to "Sky magic eyes" such as tvlink, SLxLink, DigiLink, Digital Link, VisionLink, Triax Link and all the rest.

TIPS for using this Cello-Method

ORM0022 EHPC210 Universal Controller Operation Manual Revision 1. EHPC210 Universal Controller. Operation Manual

Bookletmaking. Versatile. Flexible. Efficient. We create a professional impression. Nagel Foldnak Compact

PC/HDTV to PC/HDTV converter (CP-251F)

The Micropython Microcontroller

Bookletmaking. Versatile. Flexible. Efficient. Making printings alive. NAGEL Foldnak Compact Line with Robo-Feeder and Collection Bridge

Informatics Enlightened Station 1 Sunflower

Casambi App User Guide

Sony 4K Cameras - Setup Guide. Manual Version: v3.0

High Speed Counter. Table of Contents

17.2 Setting the slow speed Important advice on ABC Push-pull (shuttle) train control Push-pull operation without

NETWORK COMPASS USER MANUAL CONTENTS

technology T05.2 teach with space MEET THE SENSE HAT Displaying text and images on the Sense HAT LED matrix

PART 4 - INSTALLATION INFORMATION

Fully Automatic Satellite TV System

Casambi App FAQ. Version Casambi Technologies Oy.

Activity P27: Speed of Sound in Air (Sound Sensor)

9.5 Add or Remove Samples in Single Access Mode

Zimano The unique LED Downlight with revolutionary Sunset Dim technology

Analogue output module DAO 081

Specifications. End-Point Linearity - ±5% F.S., when used with HACO SCR-speed control

Robe Launches another 7 New Environmentally Friendly products at PLASA

Fully Automatic Satellite TV System

Computer Coordination With Popular Music: A New Research Agenda 1

FRONT PANEL FUNCTIONAL SPECIFICATIONS

RCP Manual. Congratulations! RCP Version 1.0

Airborne series CONTENTS. General important information This short section must be read for proper operation

AAW TOTAL EXPERIENCE VIDEOS

New Products and Features on Display at the 2012 IBC Show

Experiment 0: Hello, micro:bit!

Owners Manual PERREAUX

SetEditUFD for Kathrein UFD/Hyundai. Contents:

Polyend Poly Polyphonic MIDI to CV Converter User Manual

Spinner- an exercise in UI development. Spin a record Clicking

The modules were designed for in-house use in dry places, but the LEDs (if suited) might also be used in wet environments or outdoor.

5U Oakley Modular Series

Instructions For Using Kindle Fire Hd 8.9 Camera

WAVES Cobalt Saphira. User Guide

Analog input and output

and Re:system MR-Slave Module Dominating Entertainment. Revox of Switzerland.

American DJ. Show Designer. Software Revision 2.08

This document is a reference document that shows the menus in the 5500sc, 9610sc and 9611sc analyzers. There are 3 top-level menus:

Chapter 40: MIDI Tool

LED Lighting for Retail Displays

FRONT PANEL FUNCTIONAL

Show Designer 3. Software Revision 1.15

Is this the end of the Digital Panel Meter as we know it?

World s smallest 5MP stand-alone vision system. Powerful Cognex vision tool library including new PatMax RedLine and JavaScript support

Digital TV Troubleshooting Tips

The NXT Big Thing #14

Modular Memory System

of t of and Re:connect M300 / M301 Video switch Dominating Entertainment. Revox of Switzerland.

EAN-Performance and Latency

VLC-3 USER'S MANUAL. Light Program Controller. M rev. 04 K rev. 00 & ( ( 5, 352*5$0 1 : $ 2 ' 6(77,1*6 )81&7,216

Additional Instructions for the Arlec Energy Cost Meter PC222

McCROMETER. RE100 Electronic Register. Programming Guide

minipointe is a tiny agile air cutter specifically designed to produce sharp beam and aerial effects especially in venues constrained by size.

QTI Line Follower AppKit for the Boe-Bot (#28108)

Transcription:

C - Smoother Line Following Learn about analogue inputs to make an even more sophisticated line following robot, that will smoothly follow any path. 2017 courses.techcamp.org.uk/ Page 1 of 6

INTRODUCTION Learn about analogue inputs to make an even more sophisticated line following robot, that will smoothly follow any path. Step 1 Setup Your Robot We just need the line sensor for now - make sure your robot is setup like the picture. Step 2 Digital Analogue and To make a smoother, better line follower, we need to use the line sensor in analogue mode. So far, we have been using it as a digital sensor - it can only be ON or OFF (HI or LO). Analogue inputs (and outputs) can have any value - think about the difference between a digital and an analogue clock A digital clock must display a whole number of minutes But on an analogue clock, the minute hand can be anywhere - even halfway between two minutes! Step 3 2017 courses.techcamp.org.uk/ Page 2 of 6

Step 3 Sensor Analogue Line Build the simple test program in the picture. You can find the analogue block in the Input/Output menu Program your robot, and keep it plugged in. Try moving the robot slowly from one side of the line to the other, whilst watching the value of t in the variables menu. See how it changes gradually as you approach the line? Step 4 2 Analogue Sensors We can use this gradual change to smoothly change the amount the robot turns as it get further from the line! Add two new variables to the program called L and R (left and right). Let L = the analogue value of the left sensor, and R = the analogue value of the right sensor. Program the robot and try moving it slowly across the track again whilst still plugged in - make sure L and R behave how you expect them to! Step 5 2017 courses.techcamp.org.uk/ Page 3 of 6

Step 5 How much to turn? The larger the difference between L and R, the further the robot is from the line so the more we need to turn. For example, if both sensors are on the line, we don't need to turn at all and L and R will have the same value. Add a new variable called turn. After getting the values of L and R, set turn equal to the difference between L and R. Step 6 Using the Turn Program your robot and watch what happens to the value of turn as you move it across the line. It should be 0 when the robot is exactly on the line! Let's use the turn variable to set the speeds of the motors. Change the motor blocks so they use the turn variable to set the speed like the picture. Test it out - this should follow the line really smoothly! Do you understand how the code works? (hint: turn is positive when we need to turn right, and negative when we need to turn left) If you robot can't do the really tight turns, try multiplying turn by 2! Step 7 2017 courses.techcamp.org.uk/ Page 4 of 6

Step 7 Maximum Speed You might have noticed that while the new program is smooth, it isn't as fast as the old two sensor digital program. To make it faster, we need to make sure 1 wheel is always going 100% forwards, and then change the speed of the other wheel only based on how large turn is to follow the line. So, if turn is positive, we should be turning right, so motor 1 should be at 100% If turn is negative, we should be turning left so motor 2 should be at 100% Add an IF/ELSE block to check if turn is positive or not, and set the correct motor to 100%. Step 8 Proportional line follower Now its over to you! Add two more motor blocks into the IF/ELSE block to set the other motor's speed using the turn variable, for turning left and right Test the program really well - experiment with multiplying turn by different amounts to get a reliable line following program. Here's a hint if you're confused - for the first part where motor 1 is at 100%, motor 2 should be set to forwards at a speed of 100 - turn. Step 9 2017 courses.techcamp.org.uk/ Page 5 of 6

Step 9 Proportional Sparkles If you're feeling really advanced, add the Sparkle module back in and set the colours of the LEDs proportionally based on how far away from the line the robot is! Your robot can also get lost and now has no way of finding the line again - try and add the code you wrote previously back in so the robot can't get lost, or at least stops if it loses the line completely. 2017 courses.techcamp.org.uk/ Page 6 of 6