Recent Changes - Search:

TEAMS Academy Wiki

Explore TEAMS!
for visiting sophomores & juniors

Robotics

EnvBioTech

Bat Design

Assistive Tech


Students


Instructors

TEAMS Forum

TEAMS Calendar

TEAMS Web Site

Wiki Info

edit Student.SideBar

GarciaLab4Wimpmode

Results:

The purpose of this lab was to recreate wimp mode using WINAVR. The robot successfully minics wimp mode however, it was not very easy to do so because the coding was very tedious. Some things that I had diffuculty doing were:

  • Setting the create to wait 90 degrees when it senses a bump with in a bump
    • This was done through trial and error, debugging, and constant revising of the code.
  • Getting the create to spin continuously when one bumper is held with out stopping and restarting every 90 degrees.
    • This was corrected through the addition of a small loop while a bump is sensed with in a bump; the angle (and the distance) is set to zero.

Conclusions:

Although the wimp mode demo seems rather simple, it is very complex due to the fact that the create is constantly checking for bumps while monitoring its distance and while in safe mode. The code is very complex because there are many loops within loops. (This is also the reason for a complex flowchart!) The distance must be constantly reset to zero to continue looping the program. It is very important where the reset odometers are written in the program because they might interfere with the program working (because a condition will always be true. For example: if the create is doing a specific task while it has traveled a distance of zero and within that loop the odometers are set, that loop will continue forever and the rest of the code will not be processed). Even though the safety feature does not seem that significant when first experiencing wimp mode, it is essential for the create to be safe to carry out any of the code (true in almost every code written). The safety feature is not given enough credit until one must recreate it within a program!

Important Lessons:!!

  • It is important to know that == as “equals” while = sets that specific variable as that number
  • Time delays cannot be used with wimp mode (to measure an angle or distance) because if a time delay is used, the create will not respond to any bumps while it is carrying out that specific portion of the code. However, a small time delay after an update is necessary to give the create time to process the new information. A time delay is also needed when the create is told to stop driving to allow time to stop (otherwise the create will never reset and will only drive forward with a small pause every 57 cm).
  • It is very important to reset odometers at the beginning of the code so that the second time it runs through the create has a clean slate.
  • Sometimes the create will state an error when “making all” which is due to extra brackets (or not enough brackets) so be sure to check that before you modify your code.
  • It is necessary to always recharge the robot because it does not work very efficiently when not fully charged (specifically: Ox OD).

Lab 4 Code (text file) Δ

Lab 4 Flowchart (Microsoft Excel) Δ

Edit - History - Print - Recent Changes - Search
Page last modified on December 18, 2007, at 10:15 PM