K Force The Kristin Robotics Team Introductory Programming Tutorial 2014 For use with the teams squarebot training robots.
|
|
- Godfrey Nathan Joseph
- 5 years ago
- Views:
Transcription
1 K Force The Kristin Robotics Team Introductory Programming Tutorial 2014 For use with the teams squarebot training robots.
2 K Force Squarebot Programming Course Robot moves forward for two seconds #pragma config(motor, port1, leftwheel, tmotorvex393highspeed, openloop,) #pragma config(motor, port2, rightwheel, tmotorvex393highspeed, openloop, reversed ) //botgear robot no controller move forwards for 2 seconds //designates start of the programme { //programme start bracket and white space It s good to start the programme with a comment briefly describing what it does wait1msec(3000); //allows time to switch the robot on and put it on the ground motor[leftwheel]=60; //sets the left motor to 60 motor[rightwheel]=60; wait1msec(2000); //sets the right motor to 60 - robot starts going forward //wait 2 seconds - robot moves forwards for 2 seconds motor[leftwheel]=0; //sets the left motor to 0 motor[rightwheel]=0; //sets the right motor to 0 - robots stops } //programme end bracket and white space Use white space, comments and indents. This makes it easier to fault find, amend and understand your programme. Important tips The programme could be written as below with no structuring, white space or comments and it would still work. As you can see it is much harder to read and very difficult to fault find. #pragma config(motor, port1, leftwheel, tmotorvex393highspeed, openloop,) #pragma config(motor, port2, rightwheel, tmotorvex393highspeed, openloop,, reversed ) {motor[leftwheel]=60; motor[rightwheel]=60;wait1msec(2000);motor[leftwheel]=0;motor[rightwheel]=0;} You are advised to lay your programme out with structure, white space, comments for each line of code and a logical file name. /* A forward slash followed by an asterisk will isolate all the text after them in a paragraph so they are not read as code. Use these to make comments on your code and finish the paragraph with an asterisk and forward slash to complete the statement*/ // Two forward slashes will isolate the remaining text on one line only. No closing statement is required Save your programmes regularly!! Suggested file name structure: robot_programme_type_date_number Examples botgear_nc_fwd2secs_200214_2 (Botgear robot, no controller, forward for 2 seconds 20 Feb 2014, version 2) 2919a_kiwi chall_210514_8 (Team 2919A, Kiwi Challenge Competition, 21 st May 2014, version 8) marvin_3 sens_linetrk_ (Marvin, 3 sensor line tracking, 30 August 2012, version 12) When you have completed your programme compile and down load it using the F5 key. (Your programme must be correct!! All colons brackets and commands must be right. The compiler will give you suggestions for errors and corrections) Use the robot on and off switch to start your program or you can also use the start button in the Programme Debug window. Try using the stepping function which works through your programme step by step. This is very handy for fault finding.
3 Safety 1. Ensure all wires are properly tied up before operating a robot (Wires can get caught in gears and mechanisms which can cut them or cause short circuits resulting in expensive damage) 2. Ensure you and your team mates are clear before operating your robot (Fingers can get crushed in gears and mechanisms as well as eye hazards which can occur with moving parts such as lifts) 3. Do not operate your robot on a bench where it can possibly fall (If you are testing your robot on a bench ensure that someone is restraining it or it is on blocks. Robots can automatically go into autonomous routines on switch on. Falling onto the floor will almost certainly result in serious damage) Robot moves forward continuously #pragma config(motor, port1, leftwheel, tmotorvex393highspeed, openloop) #pragma config(motor, port2, rightwheel, tmotorvex393highspeed, openloop, reversed ) //botgear robot no controller continuous forward //designates start of the programme { //programme start bracket and white space wait1msec(3000); while(true) //allows time to switch the robot on and put it on the ground //While true, which is continuously, loop around between the brackets { //loop start motor[leftwheel]=60; //sets the left motor to 60 motor[rightwheel]=60; //sets the right motor to 60 } //loop end go back to the start of the loop } //designates end of the programme Loops are very powerful tools in programming. The while(true) loop will continue looping around indefinitely as there is nothing to make it false. As a result the programme is continually setting the motor speeds to the joystick settings with every loop. It does this thousands of times every second Do not let your robot bash into anything
4 Robot moves forward when switched #pragma config(sensor, in2, bumpswitch, sensortouch) #pragma config(motor, port1, leftwheel, tmotorvex393highspeed, openloop) #pragma config(motor, port2, rightwheel, tmotorvex393highspeed, openloop, reversed) //botgear no controller forward and stop controlled by a bumper switch connected to A/D port 1 //designates start of the programme { //designates start of programme int state=0; //creates and stores an integer called state which equals zero //this is used to determine whether the motors are to be switched on or off //when state=1 the robot will be running, when state=0 the robot will be stopped int value=0; //creates and stores an integer called value which equals zero //this is used to record an activation of the bumper switch //when switch contact is made (switch being held down)value will equal one int oldvalue=0; //creates and stores an integer called oldvalue which equals zero //this variable is used to determine if the switch operation is changing the state while(true) //while true (continuous loop) { //start of while bracket - programme continuously loops to here value=(sensorvalue(bumpswitch)); //sets 'value' to 1 if bump switch is pressed if(value==1 && oldvalue==0) //bumpswitch is depressed and old value equals zero { //start of if statement //switch was not pressed during the previous loop state = (1-state); wait1msec(300); //change state to 1 or 0 so motors switch on or off (state changes) //this is to 'debounce' the switch (ask your teacher about this) } //end of if statement oldvalue = value; //this will stop the state changing if the bumpswitch is pushed and held down if((state)==1) //if state equals 1 { //start of if statement
5 motor[leftwheel]=60; //sets the left motor to 60 motor[rightwheel]=60; //sets the right motor to 60 - robot starts going forward } //end of if statement else { //start of else statement motor[leftwheel]=0; //sets the left motor to 0 motor[rightwheel]=0; //sets the right motor to 0 - robots stops } //end of else statement } //end of while loop - programme repeats } //end of programme This programme uses variables which we set at the beginning. Variables are very powerful tools in programming. We can use them to name things and remember things. If we were controlling the robot with a simple on and off switch we could control the robot using a simple loop but because we are using a pushbutton switch we need to know whether the previous activation of the switch was to turn the robot on or off. We can use variables for this. Do not let your robot bash into anything. Turn it off and on using the switch..
6 Robot moves forward controlled by a switch and potentiometer #pragma config(sensor, in1, pot, sensorpotentiometer) #pragma config(sensor, in2, bumpswitch, sensortouch) #pragma config(motor, port1, leftwheel, tmotorvex393highspeed, openloop) #pragma config(motor, port2, rightwheel, tmotorvex393highspeed, openloop, reversed) //botgear no controller forward and stop controlled by a bumper switch connected to A/D port 2 //potentiometer connected to A/D port 1 controls robot speed and forward and reverse { //designates start of programme int state=0; //creates and stores an integer called state which equals zero //this is used to determine whether the motors are to be switched on or off //when state=1 the robot will be running, when state=0 the robot will be stopped int value=0; //creates and stores an integer called value which equals zero //this is used to record an activation of the bumper switch //when switch contact is made (switch being held down)value will equal one int oldvalue=0; //creates and stores an integer called oldvalue which equals zero //this variable is used to determine if the switch operation is changing the state while(true) //while true { //start of while bracket - programme continuously loops back to this point value=(sensorvalue(bumpswitch)); //sets 'value' to 1 if bump switch is pressed if(value==1 && oldvalue==0) //bumpswitch is depressed { //start of if statement //switch was not pressed during the previous loop state = (1-state); wait1msec(300); //change state to 1 or 0 so motors switch on or off (state must change) //this is to 'debounce' the switch (ask your teacher about this) } //end of if statement oldvalue = value; //this will stop the state changing if the bumpswitch is pushed and held down if((state)==1) //if state equals 1
7 { //start of if statement if(sensorvalue(pot)<512) //if the potentiometer (1-1024) is less than half way (512) { //start of if statement motor[leftwheel]=-128+((sensorvalue(pot))/4); //left motor set to increasing -ve setting motor[rightwheel]=-128+((sensorvalue(pot))/4);//right motor set to increasing -ve setting } //end of if statement else { //start of else statement motor[leftwheel]=-128+((sensorvalue(pot))/4); //left motor set to increasing +ve setting motor[rightwheel]=-128+((sensorvalue(pot))/4);//right motor set to increasing +ve setting } //end of else statement } //end of if statement else { //start of else statement motor[leftwheel]=0; //sets the left motor to 0 motor[rightwheel]=0; //sets the right motor to 0 - robots stops } //end of else statement } //end of while loop - programme repeats } //end of programme} This programme uses a potentiometer connected to Analogue/Digital input 2. This program also shows us how we can use basic maths in our programming to use an analogue sensor whose value is from and convert it to an analogue value from which we can use to control the motors forward and in reverse. Connect a potentiometer to A/D port 1 and put your robot on blocks so the wheels can spin freely.. A potentiometer has a limited range of rotation less than 360 degrees. It is used most commonly to measure angles. Do not connect a potentiometer on to a motor shaft or shaft that rotates more than 270 degrees otherwise you could destroy it.
8 Robot turns to the right #pragma config(motor, port1, leftwheel, tmotorvex393highspeed, openloop) #pragma config(motor, port2, rightwheel, tmotorvex393highspeed, openloop, reversed) //botgear robot no controller move forwards and turns right in increasingly sharper turns //designates start of the programme { //programme start bracket and white space wait1msec(3000); //wait for 3 seconds after switch on for programme to start motor[leftwheel]=60; //sets the left motor to 60 motor[rightwheel]=60; wait1msec(2000); //sets the right motor to 60 - robot starts going forward //wait 2 seconds - robot moves forwards for 2 seconds motor[leftwheel]=80; //sets the left motor to 80 motor[rightwheel]=40; wait1msec(2000); //sets the right motor to 40 - robots turns gently to the right //wait 2 seconds - robot gently turns to the right for 2 second motor[leftwheel]=80; //sets the left motor to 80 motor[rightwheel]=00; wait1msec(2000); //sets the right motor to 00 - robot turns on its right wheel for 2 seconds //wait 2 seconds - robot turns on its right wheel for 2 seconds motor[leftwheel]=80; //sets the left motor to 80 motor[rightwheel]=-80; wait1msec(2000); //sets the right motor to robots spins on axis to the right //wait 2 seconds - robot spins to the right on its axis for 2 seconds } //programme end bracket This programme shows how we can control the robots direction using the power to the two motors. The robot turns gently of on its axis using reverse power settings. Do not let your robot bash into anything as it turns in increasingly tight turns.
9 Robot controlled by a controller #pragma config(motor, port1, leftwheel, tmotorvex393highspeed, openloop) #pragma config(motor, port2, rightwheel, tmotorvex393highspeed, openloop, reversed) //botgear robot tank drive contol //designates start of the programme { //programme start bracket while(true) //programme continually loops back to while statement { //start of loop bifiautonomousmode = false; motor[leftwheel]=vexrt(ch3); motor[rightwheel]=vexrt(ch2); //no autonomous mode //set the left motor to the left joystick vertical channel //set the right motor to the right joystick vertical channel } //end of loop } //end of programme You can assign any channel or button on the controller to any motor or servo. The channel allocations can be found in the inventors guide or on line. Do not let your robot bash into anything as you drive it around.
10 Robot controlled by a controller with autonomous routine #pragma config(sensor, in2, bumpswitch, sensortouch) #pragma config(motor, port1, leftwheel, tmotorvex393highspeed, openloop) #pragma config(motor, port2, rightwheel, tmotorvex393highspeed, openloop, reversed) //botgear competition control simulation { //programme start bracket bifiautonomousmode = false; int auton=0; //no automatic autonomous mode //creates and stores an integer called auton which equals zero //records whether the autonomous bumpswitch has been pressed //when pressed the robot excecutes 20 seconds of autonomous code int drivercont=0; //creates and stores an integer called drivercont which equals zero //used to start the 1 minute 40 second driver control period //the robot will stop at the end of this period while(auton<1) //while autonomous button is not pressed { //start of while statement ClearTimer(T1); //timer T1 is set to zero auton=(sensorvalue(bumpswitch));//autonomous bumpswitch is checked } //end of while statement while(time100[t1]<200) //while timer is less than 20 seconds(time100=time in 100msec intervals) { //start of while statement - place your autonomous code in here motor[leftwheel]=60;//sets the left motor to 60 motor[rightwheel]=20;//sets the right motor to 20 - robot turns to the right for 20 seconds } //end of while statement while(drivercont==0) //while right button (Ch 6) on controller is not pressed { //start of while loop motor[leftwheel]=0; //sets the left motor to 0 motor[rightwheel]=0; //sets the right motor to 0 - robot stopped
11 ClearTimer(T2); drivercont=vexrt(ch6); //timer T2 is set to zero //driver control switch is checked (right switch) } //end of while loop //either right switches will activate driver control while(time100[t2]<1000) //while the timer is less than 100 seconds (1 minute 40 seconds) //time100=time in 100msec intervals { //start of while bracket motor[leftwheel]=vexrt(ch3);//set the left motor to the left joystick vertical channel motor[rightwheel]=vexrt(ch2);//set the right motor to the right joystick vertical channel } //end of while statement while(true) //while true - programme will remain in this loop { //start of while statement motor[leftwheel]=0; //sets the left motor to 0 motor[rightwheel]=0; //sets the right motor to 0 - robot stops - end of driver control } //end of while statement } //end of programme Use this programme template to simulate competition control in a match. You can place your autonomous code in the highlighted area and it will run for 20 seconds when you press the push switch. When either right button on the controller is pressed the robot will operate for 1 minute and 40 seconds simulating driver control after which it will stop. The robot will need to be turned off and back on to play further games.
12 Using quadrature shaft encoders
13 Using servomotors #pragma config(motor, port8, servo, tmotorservostandard, openloop) { while (true) { motor[servo] = 127; wait1msec(2000); motor[servo] = 0; wait1msec(2000); motor[servo] = -127; wait1msec(2000); //sets the servo to full deflection right //wait 2 second //sets the servo to centre //wait 2 second //sets the servo to full deflection left //wait 2 second } Servo motors only rotate through a fixed angle. They are good for controlling things and are not used for heavy loads. Servos use a value from -127 through to +127 to position the servo either side of centre.
14 Botgear Challenge Programme #pragma config(motor, port1, leftwheel, tmotorvex393highspeed, openloop) #pragma config(motor, port2, rightwheel, tmotorvex393highspeed, openloop, reversed) #pragma config(motor, port8, servo, tmotorservostandard, openloop) //botgear challenge programme { bifiautonomousmode = false; while(true) //programme start bracket //no autonomous mode //programme continually loops back to while statement { //start of loop motor[leftwheel]=vexrt(ch3); motor[rightwheel]=vexrt(ch2); //set the left motor to the left joystick vertical channel //set the right motor to the right joystick vertical channel motor[servo]=-(vexrt(ch3)-vexrt(ch2))/2; //set servo to difference between motors } //end of loop } //end of programme
15 Tile Trial Programme Template #pragma config(sensor, in2, bumpswitch, sensortouch) #pragma config(motor, port1, leftwheel, tmotorvex393highspeed, openloop) #pragma config(motor, port2, rightwheel, tmotorvex393highspeed, openloop, reversed) #pragma config(motor, port8, servo, tmotorservostandard, openloop) //botgear competition control simulation { //programme start bracket bifiautonomousmode = false; int auton=0; //no automatic autonomous mode //creates and stores an integer called auton which equals zero //records whether the autonomous bumpswitch has been pressed //when pressed the robot excecutes 20 seconds of autonomous code int drivercont=0; //creates and stores an integer called drivercont which equals zero //used to start the 1 minute 40 second driver control period //the robot will stop at the end of this period while(auton<1) //while autonomous button is not pressed { //start of while statement ClearTimer(T1); //timer T1 is set to zero auton=(sensorvalue(bumpswitch));//autonomous bumpswitch is checked } //end of while statement while(time100[t1]<200) //while timer is less than 20 seconds(time100=time in 100msec intervals) { //start of while statement - place your autonomous code in here motor[leftwheel]=60;//sets the left motor to 60 motor[rightwheel]=20;//sets the right motor to 20 - robot turns to the right for 20 seconds } //end of while statement while(drivercont==0) //while right button (Ch 6) on controller is not pressed { //start of while loop motor[leftwheel]=0; //sets the left motor to 0
16 motor[rightwheel]=0; ClearTimer(T2); drivercont=vexrt(ch6); //sets the right motor to 0 - robot stopped //timer T2 is set to zero //driver control switch is checked (right switch) } //end of while loop //either right switches will activate driver control while(time100[t2]<1000) //while the timer is less than 100 seconds (1 minute 40 seconds) //time100=time in 100msec intervals { //start of while bracket motor[leftwheel]=vexrt(ch3);//set the left motor to the left joystick vertical channel motor[rightwheel]=vexrt(ch2);//set the right motor to the right joystick vertical channel motor[servo]=-(vexrt(ch3)-vexrt(ch2))/2; //set servo to difference between motors } //end of while statement while(true) //while true - programme will remain in this loop { //start of while statement motor[leftwheel]=0; //sets the left motor to 0 motor[rightwheel]=0; //sets the right motor to 0 - robot stops - end of driver control } //end of while statement } //end of programme Use this programme template to simulate competition control in a match. You can place your autonomous code in the highlighted area and it will run for 20 seconds when you press the push switch. When either right button on the controller is pressed the robot will operate for 1 minute and 40 seconds simulating driver control after which it will stop. The robot will need to be turned off and back on to play further games.
RobotC for VEX. By Willem Scholten Learning Access Institute
RobotC for VEX By Willem Scholten Learning Access Institute 1 RobotCgetStarted.key - February 5, 2016 RobotC for VEX Section 1 - RobotC How to switch between VEX 2.0 Cortex and VEX IQ Section 2 - RobotC
More informationRobotC. Remote Control
RobotC Remote Control Learning Objectives: Focusing on Virtual World with Physical Examples Understand Real-Time Joystick Mapping Understand how to use timers Understand how to incorporate buttons into
More informationActivity Basic Inputs Programming - VEX Clawbot
Activity 3.1.3 Basic Inputs Programming - VEX Clawbot Introduction Inputs are devices which provide a processor with environmental information to make decisions. These devices have the capacity to sense
More information2
1 2 3 4 5 6 7 8 9 Robot C Settings for Programming in VEX IQ Text Mode Setup the software for Vex IQ: Platform Tab: Platform Type [Vex Robotics] [VEX IQ] Quick
More informationRobotC Basics. FTC Team 2843 SSI Robotics October 6, 2012 Capitol College FTC Workshop
RobotC Basics FTC Team 2843 SSI Robotics October 6, 2012 Capitol College FTC Workshop Agenda The Brick Sample Setup Template Multi Click Program Cancel Configuration (Pragmas) Joystick Data (get data)
More informationActivity Inputs and Outputs VEX
Activity 3.1.1 Inputs and Outputs VEX Introduction Robots are similar to humans if you consider that both use inputs and outputs to sense and react to the world. Most humans use five senses to perceive
More informationActivity Basic Inputs Programming VEX
Activity 3.1.3 Basic Inputs Programming VEX Introduction Inputs are devices which provide a processor with environmental information to make decisions. These devices have the capacity to sense the environment
More informationTETRIX Getting Started Guide FTC Extension
Introduction In this guide, code created with the FTC templates will be explored and then run using the Field Control Software (FCS). An FTC game begins with an autonomous period where only autonomous
More information2. Within your four student group, form a two student team known as Team A and a two student team known as Team B.
Introduction Inputs are devices which provide a processor with environmental information to make decisions. These devices have the capacity to sense the environment in a variety of ways such as physical
More informationThe Power Turtle Drivetrain
The Power Turtle Drivetrain Before you start, make sure you have the right parts available. Set these parts on a table, and put all other parts away for now. Brain & Battery 4 small gears 1 4x8 plate 4
More informationActivity Basic Inputs Programming Answer Key (VEX)
Activity 1.2.4 Basic Inputs Programming Answer Key (VEX) Introduction Inputs are devices which provide a processor with environmental information to make decisions. These devices have the capacity to sense
More informationAdvanced RobotC. Sensors and Autonomous Coding Teams 5233 Vector and 5293 Rexbotics
Advanced RobotC Sensors and Autonomous Coding Teams 5233 Vector and 5293 Rexbotics jcagle@chapelgateacademy.org Setup Select platform NXT + TETRIX/MATRIX Create New Autonomous Configure Robot with your
More informationTETRIX Getting Started Guide FTC Extension. Programming Guide (ROBOTC ) Autonomous Programming
Introduction In this guide, a TETRIX with LEGO MINDSTORMS robot with an arm and gripper extension will be programmed to move forward until it detects an object, slow down as it approaches the object, and
More informationActivity Inputs and Outputs VEX
Activity 3.1.1 Inputs and Outputs VEX Introduction Robots are similar to humans if you consider that both use inputs and outputs to sense and react to the world. Most humans use five senses to perceive
More informationBEST Generic Kit Notes GMKR00002 Revision 7; August 2011
GMKR00002 Revision 7; August 2011 1.0 Introduction This document is for information only. Although it is consistent with the rules, please see the Generic Game Rules document for the official rules. All
More informationActivity Basic Inputs Programming VEX
Activity 3.1.3 Basic Inputs Programming VEX Introduction Inputs are devices which provide a processor with environmental information to make decisions. These devices have the capacity to sense the environment
More informationProgramming Preset Heights in ROBOTC for VEX Robotics By George Gillard
Programming Preset Heights in ROBOTC for VEX Robotics By George Gillard Introduction Programming a button that lifts an arm (or other mechanism for that matter) to a specific preprogrammed point can be
More information! Before you start, make sure you have the right parts available. Set these parts on a table, and put all other parts away for now.
Tank Tread Drivetrain Before you start, make sure you have the right parts available. Set these parts on a table, and put all other parts away for now. Brain & Battery 4 1x standoffs 4 2x2 black connectors
More informationBEST Generic Kit Usage Guide GMKR00002 Revision 9; August 2013
GMKR00002 Revision 9; August 2013 1.0 Introduction This document is for information only. Although it is consistent with the rules, please see the Generic Game Rules document for the official rules. All
More informationVEX ARM Cortex -based Microcontroller and VEXnet Joystick User Guide
1. VEX ARM Cortex -based Microcontroller and VEXnet Joystick Pairing Procedure: a. The Joystick must first be paired to the VEX ARM Cortex -based Microcontroller before they will work using VEXnet Keys.
More informationAutonomy/Encoders Forward for Distance
nomy/encoders Forward for Distance In this lesson, you will learn how to use an Encoder to more accurately control the distance that the robot will travel. 1. Your robot should have one encoder hooked
More informationBlock Programming Guide
f Block Programming Guide FIRST Global Block Programming Guide - Rev 1 Copyright 2018 REV Robotics, LLC TABLE OF CONTENTS 1 Getting Started... 1 1.1 Prerequisites... 1 2 Introduction... 2 2.1 What is an
More informationElectronics Workshop. Jessie Liu
Electronics Workshop Jessie Liu 1 Return Kit Servos Servo Extensions Controller Analog USB/Tether Serial WiFi key (2) (2) Digital i/o Servo Power Adaptor AAA Battery Charger motors/ servos (4) Servo Mounting
More informationSix Omni Wheel Chain Drivetrain
Six Omni Wheel Chain Drivetrain Before you start, make sure you have the right parts available. Set these parts on a table, and put all other parts away for now. [Note, this can be built with only 4 omni
More informationEV3 Programming Workshop for FLL Coaches
EV3 Programming Workshop for FLL Coaches Tony Ayad 2017 Outline This workshop is intended for FLL coaches who are interested in learning about Mindstorms EV3 programming language. Programming EV3 Controller
More informationFinal Report. [Establish User Requirements] User must be able to press the run button on the robot, as well as use the NQC software.
Team 3 David Letteer Greg Broadwell Kathryn della Porta BE 1200 Basic Engineering Final Report Final Report [Clarify Objectives] Design, build, and program a robot that will acknowledge the presence of
More informationlogic table of contents: squarebot logic subsystem 7.1 parts & assembly concepts to understand 7 subsystems interfaces 7 logic subsystem inventory 7
logic table of contents: squarebot logic subsystem 7.1 parts & assembly concepts to understand 7 subsystems interfaces 7 logic subsystem inventory 7 7 1 The Vex Micro Controller coordinates the flow of
More informationTETRIX Getting Started Guide FTC Extension
TeleOp Programming TETRIX Getting Started Guide FTC Extension Introduction In this guide, a TETRIX with LEGO MINDSTORMS robot with an arm and gripper extension will be programmed to be controlled by a
More informationActivity While Loops and If-Else Structures VEX
Activity 3.1.4 While Loops and If-Else Structures VEX Introduction One of the powerful attributes of a computer program is its ability to make decisions. Although it can be argued that only humans are
More informationMovement using Shaft Encoders
Movement using Shaft Encoders Configure (Motors and Sensors Setup) We will look at the following in this section SensorValue[] while Conditions (, =,!=, ==) Quadrature/Shaft/Rotation Encoder 360
More information16-311: Getting Started with ROBOTC and the. LEGO Mindstorms NXT. Aurora Qian, Billy Zhu
16-311: Getting Started with ROBOTC and the LEGO Mindstorms NXT Aurora Qian, Billy Zhu May, 2016 Table of Contents 1. Download and Install 2. License Activation 3. Wireless Connection 4. Running Programs
More informationActivity While Loops and If-Else Structures Answer Key (VEX) Introduction
Activity 1.2.5 While Loops and If-Else Structures Answer Key (VEX) Introduction One of the powerful attributes of a computer program is its ability to make decisions. Although it can be argued that only
More informationThe Beginners Guide to ROBOTC. Volume 2, 3 rd Edition Written by George Gillard Published: 18-July-2016
The Beginners Guide to ROBOTC Volume 2, 3 rd Edition Written by George Gillard Published: 18-July-2016 Introduction ROBOTC is an application used for programming robots. There are many different versions
More informationBEST Control System. Dave Wilkerson. September 12, 2015
BEST Control System BEST Robotics, Inc. Dave Wilkerson September 12, 2015 Copyright 2012 BEST Robotics, Inc. All rights reserved. 1 Servos Joystick Return Kit AAA Battery Charger Analog WiFi key USB/Tether
More informationAutonomous Programming FTC Challenge Workshops VCU School of Engineering September 24, 2016 Presented by: Team 8297 Geared UP!
Autonomous Programming 2016-2017 FTC Challenge Workshops VCU School of Engineering September 24, 2016 Presented by: Team 8297 Geared UP! Autonomous in VELOCITY VORTEX The Match starts with a 30 second
More informationRemoval and Installation8
8 Screw Types 8-4 Top Cover Assembly 8-5 Left Hand Cover 8-6 Right Hand Cover 8-10 Front Panel Assembly 8-14 Left Rear Cover 8-15 Right Rear Cover 8-16 Extension Cover (60" Model only) 8-17 Media Lever
More informationThumb Joystick Retail. Tools and parts you'll need. Things you'll want to know. How does it work? Skill Level: Beginner. by MikeGrusin March 22, 2011
Thumb Joystick Retail Skill Level: Beginner by MikeGrusin March 22, 2011 Thank you for purchasing our Thumb Joystick! Whether you're blasting aliens or driving a robot, you'll find it a very useful addition
More informationPart A: Monitoring the Rotational Sensors of the Motor
LEGO MINDSTORMS NXT Lab 1 This lab session is an introduction to the use of motors and rotational sensors for the Lego Mindstorm NXT. The first few parts of this exercise will introduce the use of the
More informationTWO PLAYER REACTION GAME
LESSON 18 TWO PLAYER REACTION GAME OBJECTIVE For your final project for this level for the course, create a game in Python that will test your reaction time versus another player. MATERIALS This lesson
More informationSPARTAN ROBOTICS FRC 971
SPARTAN ROBOTICS FRC 971 Controls Documentation 2015 Design Goals Create a reliable and effective system for controlling and debugging robot code that provides greater flexibility and higher performance
More informationECGR 4101/5101, Fall 2016: Lab 1 First Embedded Systems Project Learning Objectives:
ECGR 4101/5101, Fall 2016: Lab 1 First Embedded Systems Project Learning Objectives: This lab will introduce basic embedded systems programming concepts by familiarizing the user with an embedded programming
More informationAutonomous Parking. LEGOeducation.com/MINDSTORMS. Duration Minutes. Learning Objectives Students will: Di culty Beginner
Autonomous Parking Design cars that can park themselves safely without driver intervention. Learning Objectives Students will: Understand that algorithms are capable of carrying out a series of instructions
More informationActivity Variables and Functions VEX
Activity 3.1.5 Variables and Functions VEX Introduction A program can accomplish a given task in any number of ways. Programs can quickly grow to an unmanageable size so variables and functions provide
More informationWIRELESS VEHICLE WITH ANIMATRONIC ROBOTIC ARM
WIRELESS VEHICLE WITH ANIMATRONIC ROBOTIC ARM PROJECT REFERENCE NO. : 37S0918 COLLEGE : P A COLLEGE OF ENGINEERING, MANGALORE BRANCH : ELECTRONICS & COMMUNICATION GUIDE : MOHAMMAD RAFEEQ STUDENTS : CHARANENDRA
More information2011 FIRST Robotics Competition Sensor Manual
2011 FIRST Robotics Competition Sensor Manual The 2011 FIRST Robotics Competition (FRC) sensors are outlined in this document. It is being provided as a courtesy, and therefore does not supersede any information
More informationROBOTC Basic Programming
ROBOTC Basic Programming Open ROBOTC and create a new file Check Compiler Target If you plan to download code to a robot, select the Physical Robot opbon. If you plan to download code to a virtual robot,
More information//#define HTIRS2_DSP_MODE = 1200;
#pragma config(hubs, S1, HTMotor, HTMotor, HTMotor, HTMotor) #pragma config(hubs, S2, HTServo, none, none, none) #pragma config(sensor, S1,, sensori2cmuxcontroller) #pragma config(sensor, S2,, sensori2cmuxcontroller)
More informationRCX Tutorial. Commands Sensor Watchers Stack Controllers My Commands
RCX Tutorial Commands Sensor Watchers Stack Controllers My Commands The following is a list of commands available to you for programming the robot (See advanced below) On Turns motors (connected to ports
More informationTETRIX Getting Started Guide. Harvester and Transporter Programming Guide (ROBOTC )
Introduction: In this guide, the Ranger Bot will be programmed to follow a line, pick up an object using the harvester, and put the object into the transporter. It will also count the number of objects
More informationFTC Control Systems + Java The Gifted Gears
FTC Control Systems + Java 101 Outline Control Systems REV Modern Robotics Phones and Phone Setup Programming Options and Setup Navigating Android Studios Java! OpModes Basics Actuators Teleop What Am
More informationGetting Started in RobotC. // Comment task main() motor[] {} wait1msec() ; = Header Code Compile Download Run
Getting Started in RobotC // Comment task main() motor[] {} wait1msec() ; = Header Code Compile Download Run Understand Motion Learning Objectives Motors: How they work and respond. Fuses: Understand why
More informationRoof Truss Roller Press, Tables and Jigging
RoofTracker II Roof Truss Roller Press, Tables and Jigging August 2015 Page 1 Table of Contents Equipment Introduction to the Equipment Restricted Zone Truss Terminology Parts of a Truss Important Notes
More informationCreating a robot project
Creating a robot project Liquid error: No route matches {:action=>"show", :controller=>"spaces/chapters", :space_id=>"3120", :manual_id=>"7952", :id=>nil} Launching WindRiver Workbench WindRiver Workbench
More informationBEST Generic Kit Notes GMKR00002 Revision 5; August 2010
GMKR00002 Revision 5; 1.0 Introduction All Returnable Kit items, including boxes and packing, must be returned at the conclusion of the contest. This equipment will be used again next year; so do not modify
More informationCORTEX Microcontroller and Joystick User Guide
This is a User Guide for using the VEX CORTEX Microcontroller and VEX Joystick. Refer to the VEX Wiki (http://www.vexforum.com/wiki/index.php/vex_cortex_microcontroller) for updates to this document. 1.
More informationStuduino Block Programming Environment Guide
Studuino Block Programming Environment Guide [DC Motors and Servomotors] This is a tutorial for the Studuino Block programming environment. As the Studuino programming environment develops, these instructions
More informationColin Harman and Jonathan Kim
Colin Harman and Jonathan Kim 2-6-10 Getting RobotC 1. Go to robotc.net/robofest 2. Enter coach information including Robofestteam ID 3. The coach will get an email with a link to download RobotC(90-day
More informationBEST Generic Kit Usage Guide GMKR00002 Revision 13; August 2017
GMKR00002 Revision 13; 1.0 Introduction This document is for information only. Although it is consistent with the rules, please see the Generic Game Rules document for the official rules. All Returnable
More informationVariables and Functions. ROBOTC Software
Variables and Functions ROBOTC Software Variables A variable is a space in your robots memory where data can be stored, including whole numbers, decimal numbers, and words Variable names follow the same
More informationINTRODUCTION TABLE OF CONTENTS 1 INTRODUCTION WELCOME TO THE 2009 FRC CONTROL SYSTEM Suggestions for Getting Started 2
Section 1 INTRODUCTION TABLE OF CONTENTS 1 INTRODUCTION 2 1.1 WELCOME TO THE 2009 FRC CONTROL SYSTEM 2 1.1.1 Suggestions for Getting Started 2 1.2 TECHNICAL SUPPORT FOR THE 2009 FRC CONTROL SYSTEM 2 1.3
More informationHUB-ee BMD-S Arduino Proto Shield V1.1
HUB-ee BMD-S Arduino Proto Shield V1.1 User guide and assembly instructions Document Version 0.5 Introduction & Board Guide 2 Schematic 3 Quick User Guide 4 Assembly Guide 6 Kit Contents 7 1) Diodes and
More informationActivity Basic Outputs Programming Answer Key (VEX) Introduction
Activity 1.2.3 Basic Outputs Programming Answer Key (VEX) Introduction Computer programs are used in many applications in our daily life. Devices that are controlled by a processor are called outputs.
More informationEP486 Microcontroller Applications
EP486 Microcontroller Applications Topic 6 Step & Servo Motors Joystick & Water Sensors Department of Engineering Physics University of Gaziantep Nov 2013 Sayfa 1 Step Motor http://en.wikipedia.org/wiki/stepper_motor
More informationOmni-Directional Drive and Mecanum: Team 1675 Style. Jon Anderson FRC Mentor
Omni-Directional Drive and Mecanum: Team 1675 Style Jon Anderson jon.c.anderson@gmail.com FRC Mentor Omni-Directional Drive Omni-Directional Drive is Holonomic The controllable degrees of freedom is equal
More informationActivity Basic Outputs Programming VEX
Activity 3.1.2 Basic Outputs Programming VEX Introduction Computer programs are used in many applications in our daily life. Devices that are controlled by a processor are called outputs. These devices
More informationCHAPTER 3B: ELECTRONIC POWER STEERING
Electronic Power Steering CHAPTER 3B: ELECTRONIC POWER STEERING NOTE: The basic steering system, such as the tie rod ends, drag links axles, etc., is covered in Chapter 3A: Steering. In 2012, Cub Cadet
More informationDEFAULT SCREEN. Button and Screen Layout DRILLING WIDTH TARGET RATE HOPPER NUMBER CROP NAME DRILLING ACTION CROP NUMBER. HOPPER selection POWER On/Off
DEFAULT SCREEN Button and Screen Layout DRILLING WIDTH TARGET RATE CROP NAME HOPPER NUMBER DRILLING ACTION CROP NUMBER HOPPER selection POWER On/Off AREA / DISTANCE TARGET RATE Increase CROP Scroll / Up
More informationFSXThrottle All Quadrants (all models) Notes*
FSXThrottle All Quadrants (all models) Notes* * Please note that not all features and options described or listed in these notes may apply to your model. Table of Contents Introduction:...3 Our Commitment:...3
More informationRobot Design Workshop: VEX Hardware & Robot Building Basics
Robot Design Workshop: VEX Hardware & Robot Building Basics Nik Kukert Bison BEST Robotics 1 Basics Only use parts supplied in the consumable and returnable kits (or approved optional items) Robots containing
More informationVEX U Robotics. Old Dominion University
VEX U Robotics Old Dominion University Mechanical & Aerospace Engineering Department MAE 435 - Project Design & Management II Spring 2017 February 27, 2017 Midterm Report Michael Cataldo Martin Garcia
More informationustepper S Datasheet Microcontroller, stepper driver and encoder in an ultra-compact design! By ustepper ApS
ustepper S Datasheet Microcontroller, stepper driver and encoder in an ultra-compact design! By ustepper ApS Product: ustepper S Document revision: 1.1 Author: MGN Approved by: THO Approval date: January
More informationSphero Lightning Lab Cheat Sheet
Actions Tool Description Variables Ranges Roll Combines heading, speed and time variables to make the robot roll. Duration Speed Heading (0 to 999999 seconds) (degrees 0-359) Set Speed Sets the speed of
More informationLEGO MINDSTORMS NXT Lab 4
LEGO MINDSTORMS NXT Lab 4 This lab session is an introduction to wireless communication using the Lego Mindstorm NXT software. Two Tribots will speak to each other using a machine language or protocol
More informationCopyright White Box Robotics Inc. and Frontline Robotics Inc
Disclaimer Working with electronics and installing the plastics will require care and patience. PROPER GROUNDING PROCEDURES before handling the electronics. Touching the robot chassis (which is common
More informationTETRIX Getting Started Guide. Launcher Programming Guide (ROBOTC )
Introduction: In this guide, the Ranger Bot will be programmed to follow a line while carrying a ball. Upon sensing a bin with its ultrasonic sensor, it will launch the ball into the bin. This guide is
More informationCreate Open Interface Scripts: Using the Create Without an XBC
Create Open Interface Scripts: Using the Create Without an XBC Jeremy Rand Norman High School jeremy@asofok.org Create Open Interface Scripts: Using the Create Without an XBC 1 Introduction When the irobot
More informationCommand and Control Tutorial
Command and Control Tutorial Introduction Command and Control is a new LabVIEW template added for the 2016 season which organizes robot code into commands and controllers for a collection of robot-specific
More informationIntroduction to Internet of Things Prof. Sudip Misra Department of Computer Science & Engineering Indian Institute of Technology, Kharagpur
Introduction to Internet of Things Prof. Sudip Misra Department of Computer Science & Engineering Indian Institute of Technology, Kharagpur Lecture - 23 Introduction to Arduino- II Hi. Now, we will continue
More informationDual 10A RC Relay MK2
Dual 10A RC Relay MK2 Stockist:- Scale Warship 5 Beechwood Avenue New Milton Hants BH25 5NB 07855 941117 john@scalewarship.com 1 INTRODUCTION This unit allows the signal from a standard radio control receiver
More informationExperimental Procedure
1 of 14 9/10/2018, 11:38 AM https://www.sciencebuddies.org/science-fair-projects/project-ideas/robotics_p028/robotics/obstacle-avoiding-robot (http://www.sciencebuddies.org/science-fair-projects /project-ideas/robotics_p028/robotics/obstacle-avoiding-robot)
More informationControl Systems Laboratory Manual Hardware and Software Overview. 2 Hardware Equipment. 2.1 Analog Plant Simulator (EE357 Only)
1 Introduction Control Systems Laboratory Manual Hardware and Software Overview The undergraduate Control Systems Lab is located in ETLC E5-006. In the lab, there are 15 PCs equipped with data acquisition
More informationExperiment 4.A. Speed and Position Control. ECEN 2270 Electronics Design Laboratory 1
.A Speed and Position Control Electronics Design Laboratory 1 Procedures 4.A.0 4.A.1 4.A.2 4.A.3 4.A.4 Turn in your Pre-Lab before doing anything else Speed controller for second wheel Test Arduino Connect
More informationA Simple Introduction to Omni Roller Robots (3rd April 2015)
A Simple Introduction to Omni Roller Robots (3rd April 2015) Omni wheels have rollers all the way round the tread so they can slip laterally as well as drive in the direction of a regular wheel. The three-wheeled
More informationCBM-105FP Troubleshooting
CBM-105FP Troubleshooting SPECIFICATIONS SUBJECT TO CHANGE WITHOUT NOTICE Page 1 of 8 Section 1: Symptom Checking Page Power Moller does not run------------------------------------------------------------------
More informationA.U.R.A.S Autonomous Ultrasonic Robot for Area Scanning
A.U.R.A.S Autonomous Ultrasonic Robot for Area Scanning Project Presentation ECE 511 Fall 2014 George Mason University 12/05/2014 Group: 2 Team Members: DevarajDhakshinamurthy Krishna Nikhila Kalinga Gagandeep
More informationGetting Started with FTC Using RobotC
Oregon Robotics Tournament and Outreach Program Getting Started with FTC Using RobotC 2008 Opening doors to the worlds of science and technology for Oregon s s youth Instructors Coordinator Robot C for
More informationVEX Robotics A Primer
2015 Andrew Dahlen andrew.dahlen@northlandcollege.edu VEX Robotics A Primer 2015 HI-TEC Conference Workshop July 27 th 2015 Portland Oregon Background VEX Robotics Overview 360 VEX Robotics Competition
More informationAlteraBot Self-Test User Manual A Hardware Evaluation Guide for ECE 2031
AlteraBot Self-Test User Manual A Hardware Evaluation Guide for ECE 2031 Prepared For ECE 2031 Students Prepared By Shane Connelly May 2, 2005 1 Table of Contents Section 1: Scope 3 Introduction 3 System
More informationHauptwerk Hardware 2016
Hauptwerk Hardware Interface Board for the Universal Midi Encoder User Manual Page 1 Release 1.2 February 2016 Table of Contents Introduction...3 Board Overview...4 IMPORTANT PLEASE READ...5 Mounting...6
More informationActivity Basic Outputs Programming VEX
Activity 3.1.2 Basic Outputs Programming VEX Introduction Computer programs are used in many applications in our daily life. Devices that are controlled by a processor are called outputs. These devices
More informationInstructions For Constructing A Braitenberg Vehicle 2 Robot From LEGO Mindstorms Components
Instructions For Constructing A Braitenberg Vehicle 2 Robot From LEGO Mindstorms Components Michael R.W. Dawson, Biological Computation Project, University of Alberta, Edmonton, Alberta September, 2003
More information26 27 //m8 (6u, two values, 127 for released button and +127 for pressed button, was m7) (suggest servo only)
1 //ReadMe.txt 2 3 //BEST WarpXX (2012 Game) 4 5 //Default code, jg revision 7/16/2012 6 7 //Motor (control) Description 8 9 //Port (joystick or buttons) 10 11 //m2 (+j3) m2 and m9 are opposing analog
More informationmanual industrial sectional door operator. INSTALLATION / MAINTENANCE All rights reserved. FlexiForce, 2010 FF-MANUAL force90ac
force140ac industrial sectional door operator. GB INSTALLATION / MAINTENANCE All rights reserved. FlexiForce, 2010 FF-MANUAL force90ac www.flexiforce.com GB INDEX 1 SAFETY INSTRUCTIONS...1 1.1 ELECTRICAL
More informationIf you note any errors, typos, etc. with this manual or our software libraries, let us know at
Oregon State University Robotics Club ORK 2011 Programming Guide Version 1.0 Updated: 10/28/2011 Note: Check back for more revisions and updates soon! If you note any errors, typos, etc. with this manual
More informationHow-To #3: Make and Use a Motor Controller Shield
How-To #3: Make and Use a Motor Controller Shield The Arduino single-board computer can be used to control servos and motors. But sometimes more current is required than the Arduino can provide, either
More informationLine tracking sensors and algorithms
Line tracking sensors and algorithms Posted on February 28, 2008, by Ibrahim KAMAL, in Robotics, tagged Line tracking is a very important notion in the world of robotics as it give to the robot a precise,
More informationChapter 20 Assembly Model with VEX Robot Kit - Autodesk Inventor
Tools for Design Using AutoCAD and Autodesk Inventor 20-1 Chapter 20 Assembly Model with VEX Robot Kit - Autodesk Inventor Creating an Assembly Using Parts from the VEX Robot Kit Understand and Perform
More informationECE-320 Lab 3: Utilizing a dspic30f6015 to model a DC motor and a wheel
ECE-320 Lab 3: Utilizing a dspic30f6015 to model a DC motor and a wheel Overview: In this lab we will utilize the dspic30f6015 to model a DC motor that is used to control the speed of a wheel. Most of
More informationThe "Hello world" of FRC robot programming
The "Hello world" of FRC robot programming Here's how to create the shortest possible robot program that actually does something useful. In this case, it provides tank steering in teleop mode and drives
More informationChapter 19 Assembly Modeling with the TETRIX by Pitsco Building System Autodesk Inventor
Tools for Design Using AutoCAD and Autodesk Inventor 19-1 Chapter 19 Assembly Modeling with the TETRIX by Pitsco Building System Autodesk Inventor Create and Use Subassemblies in Assemblies Creating an
More information