VEX Robotics Design System - PowerPoint PPT Presentation

About This Presentation
Title:

VEX Robotics Design System

Description:

Title: VEX Robotics Design System Author: Joshua Gabrielse Last modified by: Joshua M. Gabrielse Created Date: 7/5/2006 4:59:06 PM Document presentation format – PowerPoint PPT presentation

Number of Views:330
Avg rating:3.0/5.0
Slides: 39
Provided by: JoshuaGa7
Category:
Tags: vex | design | motor | robotics | system

less

Transcript and Presenter's Notes

Title: VEX Robotics Design System


1
VEX Robotics Design System
Simple EasyCProgram
2
Outline
  • The Programming Kit
  • The Joystick
  • Your 1st EasyC Program
  • Common Problems

3
The Programming Kit
  • EasyC V4 for Cortex
  • only works with the new controllers in your kits
  • USB to serial port adapter
  • connects a computer to the dongle
  • dongle
  • connects a telephone cable to a serial cable (or
    USB to serial adapter)
  • telephone cable
  • plugs into the programming port of your joystick

EasyC CD
USB to serial adapter
dongle
telephone cable
4
VEXnet Joystick
  • 8 channels
  • x-axis of right joystick
  • (-127 to 127)
  • y-axis of right joystick
  • (-127 to 127)
  • y-axis of left joystick
  • (-127 to 127)
  • x-axis of left joystick
  • (-127 to 127)
  • left trigger buttons
  • Up (0 or 1)
  • Down (0 or 1)
  • right trigger buttons
  • Up (0 or 1)
  • Down (0 or 1)
  • left buttons
  • Up (0 or 1)
  • Down (0 or 1)
  • Left (0 or 1)

? Top View ? ? Front View ?
? Front View ?
5
Sample Program in EasyC
6
Start a New Competition Project
7
Select Field Control Competition Project
8
Select the Controller Configuration (F5)
9
Type in descriptions of what youre going to
plug into each port.
10
Type in descriptions of what youre going to
plug into each port.
11
Select the OperatorControl tab.
12
Expand Joystick
13
Pick Tank or Arcade mode.
Modes Arcade 1 joystick drive (simpler) Tank
2 joystick drive (better control) The number of
motors should match your robot (2 for the
protobot).
14
Drag Tank 2 motor onto the flow chart.
Modes I will use Tank 2 motor since driving
with two joysticks gives the driver more control.
You can use Arcade 2 motor if you prefer to
drive with one joystick.
15
Drag Tank 2 motor into the WHILE loop.
WHILE Loops Any statement placed in a while loop
will execute over and over again (if the
expression equals 1). We drag the joystick
block into the while loop so the program will get
commands from the joystick over and over again.
16
For Tank drive set the Left Channel to 3 (the
y-axis of your left joystick)
Tank Drive The y-axis of the left joystick should
control the left wheels and the y-axis of the
right joystick should control the right wheels.
17
For Tank drive set the Right Channel to 2 (the
y-axis of your right joystick)
Tank Drive The y-axis of the left joystick should
control the left wheels and the y-axis of the
right joystick should control the right wheels.
18
For Arcade set the Forward/Reverse Channel to 2
(the y-axis of the right joystick).
Arcade Drive The y-axis of your right joystick
(if youre right-handed) should control the speed
(forward/reverse) of the robot.
19
For Arcade set the Rotate Channel to 1 (the
x-axis of the right joystick).
Arcade Drive The x-axis of your right joystick
(if youre right-handed) should control the
rotation (turning) of the robot.
20
Select the motor number for your Left Motor.
Motor Numbers The number of the slot/port on the
robot controller that a motor is plugged into is
its Motor Number. Labels from the Controller
Configuration automatically appear in green.
21
Select the motor number for your Right Motor.
Motor Numbers The number of the slot/port on the
robot controller that a motor is plugged into is
its Motor Number. Labels from the Controller
Configuration automatically appear in green.
22
Arm
23
(No Transcript)
24
Gripper
25
Gripper
26
You are done writing your first program.
Congratulations!
27
Build Download your program.
28
Build Download your program.
29
Your program is finished downloading whenthe bar
goes down (erases old code)and goes back again
(loads new code).
30
Save your program even if it didnt work.
31
My code wont download!(Is your robot on?)
The POWER switch should be ON.
  • The ROBOT light should be green (charged
    battery).
  • The VEXnet light should be green (connected).

Make sure to turn your joystick on too.
32
My code wont download!(Did you use a fresh
battery?)
  • What color is the ROBOT light on the controller?
  • green okay battery
  • red dead battery

33
My code wont download!(Is the robot connected
to the computer?)
USB A-A cable
computer
joystick
remove the VEXnet key
robot controller
  • The USB A-A cable should be plugged into the
    robot controller in the USB port where the VEXnet
    key normally plugs in.
  • The other end of the USB A-A cable should be
    plugged into a USB port on the computer.

34
My code wont download!(You can use the
programming cord instead of the USB A-A cable)
USB to serial adapter
telephone cable
dongle
computer
joystick
  • The telephone cord should be plugged into the
    port labeled PROGRAM on the joystick.
  • The other end of the telephone plug should be
    plugged into the dongle.
  • The other end of the dongle should be attached to
    the computer (either by the USB to serial adapter
    or a serial cable).

35
My robot doesnt drive right!(Are the motors
plugged in correctly?)
Everything should be plugged in according to the
Controller Configuration
36
My robot doesnt drive right!(Did you use
servos instead of motors?)
  • check the label
  • motors spin continuously (360 of rotation)
  • the controller sets the speed (-127 to 127)
  • servos spin back and forth (120 of rotation)
  • the controller sets the location (-127 to 127)

37
My robot doesnt drive right!(Do you need to
invert any of your motors?)
  • Test drive your robot with all its wheels off
    the ground
  • Look to see if any motors need to spin in the
    other direction
  • Check Invert Direction to make a wheel spin in
    the other direction.
  • Build Download your modified code

38
(No Transcript)
Write a Comment
User Comments (0)
About PowerShow.com