1 / 13

Programming a Wheel System

Programming a Wheel System. By Joshua Shaw. From the last Power Points. We have previously added a While Loop We are now going to use it for programming the robot We have also added two motor programs An analog program A digital program We have also added two servo programs as well

deanna
Download Presentation

Programming a Wheel System

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Programming a Wheel System By Joshua Shaw

  2. From the last Power Points • We have previously added a While Loop • We are now going to use it for programming the robot • We have also added two motor programs • An analog program • A digital program • We have also added two servo programs as well • An analog program • A digital program

  3. Creating a Program for Wheels • One of the most commonly used wheel configurations is a wheel on each side of the robot • To avoid spinning in circles, the motors need to spin in opposite directions • The wheels need to work in unison, as well as being independent of each other • This can be achieved in an Arcade Program

  4. Arcade Programming-Channels • Go back to Joystick under the Functions Blocks • Click and drag the Arcade - 2 motor anywhere on the vertical line of the While Loop • Click the down arrow on the Forward\Reverse Channelto choose the channel that will operate the forward and backwards motion of the robot (select “3” for this program) • Do this for the Rotate Channel (select “4”)

  5. Arcade Programming-Motors • Click the down arrow on theLeft Motor and select a motor to operate the wheels • For this example select “6” • Do this for the Right Motor except with a different motor • For this example select “8”

  6. Arcade Programming - Invert Direction of Motors • To operate the wheels properly we will need to invert the direction of one of the motors • We will Invert Direction for Left Motor “6” by clicking the down arrow of Invert Direction and selecting “1” • If the robot goes backwards than we will return Invert Direction of Left Motor “6” to “0” and select “1” under Invert Direction for Right Motor “8” • Finally click OK

  7. Completed Arcade Program • This is what the program for the Arcade – 2 motor will look like

  8. Using the Joystick Controller – Channel 3 and 4 • You will use the Channels 3 & 4on the Joystick Controller • Move the left Joystick in any direction to control the two motors • Both motors will run simultaneously

  9. Tank programs • Another type of wheel system is the tank • Uses two independent wheel systems • Drag and Drop Tank – 2 motor into the While Loop • As you can see it looks similar to the Arcade – 2 motor

  10. Tank programs –v- Arcade program • The primary difference between the Arcade program and the Tank • Arcade runs of one joystick • Tank runs of two joysticks • Each has an advantage • Arcade acts more like a computer game and is usually easier to operate • Tank allows for more variation in turning capability and precision of turns • You can only use one or the other • For this tutorial we will only use the Arcade program for the wheels

  11. Noise Pollution • As you have probably notice, the motors of your robot give off a high pitch whining sound • This is due to the slight push on the joysticks from any number of forces • Slight breeze • Gravity • Slight push from the fingers • It is able to be fixed fairly easily

  12. Reducing Noise for Channel 3 and Channel 4 Motors • You need one for each of the analog channels that where used • In this example we used Channels 3 and 4 • Drag and drop the Joystick Analog Deadbandbetween the Variable box and the While box • Since we have a motor that is controlled by Channel 3 set the Analog Channel to “3” • Set both the Positive and Negative Deadband to “20” • Click OK • Drag and drop the Joystick Analog Deadbandbetween the Variable box and the While box • Since we have a motor that is controlled by Channel 4 set the Analog Channel to “4” • Set both the Positive and Negative Deadbandsto “20” • Click OK

  13. Next PowerPoint • The next PowerPoint is Downloading and Testing the Program

More Related