Labs

From Laramie Robotics Club
Jump to: navigation, search

Exercises

Overview: There are many potential tracks. The most complete track is the Lab track, which in the future will be renamed the SimulatedRobot track. There is also a Graphics track, Music track, and soon a Game track. The tracks are shown below.

Regardless of which track you wish to pursue you have to complete Lab01. Once Lab01 is completely you can move onto Lab02, Graphics02, or Music02. Within a section, exercises are numbered and can be followed sequentially.

ExerciseFlowChart1.png

If you are not working on the Exercises in the LRC room you will have to setup Calico. For more information on Calico, Dropbox (file sharing), or the computers and robots we will be using jump to the end of this page.


Simulated Robot

The following Labs relate to the Calico and the simulated robot. The commands for the simulated robot and the real robot are the same. Once you get good at programming the simulated robot you can take your code and have it control the real robot.

Lab01 - Scripts, Functions, and Drawing

Overview: This is essentially the first exercise you will do regardless of the track you wish to pursue. The first part of this lessons goes over how to use the Calico shell as well as how to write, save, and load simple scripts. The second part of the lessons goes over how to send motor commands to the simulated robot, writing functions, and drawing simple shapes.

Instructions and code: Lab01

Developmental: Gauntlet

Lab 2 - Variables and Passing Parameters

Overview Lab 2 introduces variables, and how they can be passed into functions.

Instructions and code: Lab02

Lab2a - Further Variable Practice

Overview Lab 2a is a small lab that reinforces the concepts of variables by using them to store information from the simulated scribbler's sensors. This lab also introduces the scribbler's sensors.

Instructions and code: Lab02a

Lab2b

Overview Lab 2b is a small lab that reinforces the concepts of variables by using them to create songs using the beep() command. Note that this is an old lab and needs to be revised. If you wish to give it a try use the file Lab3.pdf to guide you.

Instructions and code: Lab02b

Lab 3 - Conditional Statements

Overview Lab 3 diverges from the normal robot simulator and instead allows you to build your own branching story. The focus of this lab is to gain familiarity with conditional statements. A powerful concept in programming and something that will be heavily used in later lessons and robot challenges.

Instructions and code: Lab03

Lab 4 - Loops

Overview Lab 4 returns to the idea of creating fractals, but this time with loops. Loops are another very powerful programming concept that will be heavily used in future lessons and robot challenges.

Instructions and code: Lab04

Lab 5 - Challenges

Overview Lab 5 has students program a robot to follow a light. Lab 5 combines storing variables, conditional statements, and while loops. The controllers built in Lab 5 will be simply reflexive controllers modeled after Braintenberg vehicles.

Instructions and code: Lab05

Lab 6 - Challenges

Overview Lab 6 presents no new material. Instead a number of simulated worlds are presented that students must solve. These simulated worlds include navigating a maze, following/avoiding a light, and simple blob detection. These are the same challenges that students will be doing on the real robot.

Instructions and code: Lab06

Graphics

The following Exercises use Calico's Graphics library.

Graphics01

There is no initial Graphics Exercise. To learn how to use Calico, shell commands, basic scripting, and simple functions please see Lab01.

Graphics02 - Variables and Passing Parameters

Overview Introduces Calico's Graphics library. Draws a simple scene.

Instructions and code: Graphics01

Future Graphics

There will be more Graphics exercises to come including exercises that use mouse and key events, and incorporate animations.

Music

The following Exercises use the beep() command to play notes and compose songs.

Music 01

There is no initial Music Exercise. To learn how to use Calico, shell commands, basic scripting, and simple functions please see Lab01.

Music02

Overview Introduces the beep() command and goes through the create of a few songs. Warning This lab needs some to be polished up and is kind of rough around the edges.

Instructions and code: Music02

Games

Coming Soon.

Logic

The LogicControl gui is not an exercise, but rather a cool programming interface.

LogicControl


Template file to help transition from logic control.

template

Tools

The following sections detail some of the tools used in the LRC including Calico, dropbox, and the University's computers. The following sections also provide a brief description and link to all the Labs. Note if you are working on the Labs at home you will have to go through the Setup/Getting Started guide in order to install the proper software. The setup guide can be found here: http://cobi.cs.uwyo.edu/lrc/index.php/Setup_Guide

Calico

Calico is the main program that we will be using to control the robot, both simulated and real. It is a free program and is easily installed. If you are working on the LRC material in the LRC room at the University of Wyoming you don't have to worry about installing Calico. It should already be installed on the machines. If you want to install Calico at home you will have to set it up yourself. For more information on Calico and the LRC specific modifications made to it please see the LRC wiki Calico Page.

For the Labs we will predominantly using the Calico simulator, shown below.

CalicoSimulator.png

Dropbox

Dropbox is a free site that allows users to make an account and save files to a server. This means that as long as you have an internet connection you can save and upload files. We will be using dropbox as a place for students to save the code they've worked on in the LRC. This means they can work on an exercise during the LRC meeting, save their code to dropbox, and then download their code at home and continue the work they were doing.

The Laramie Robotics Club has a dropbox account, which we use for students. If you are a student or parent and wish to know the username and password for the dropbox account please email Roby Velez (rvelez@uwyo.edu).

Also as a student or parent you can make your own dropbox account and use that instead of the LRC account.

Computers and Robots

For the Laramie Robotics Club meetings we will be using the University of Wyoming's computers. You do not have to bring your own laptop, but if you wish to you can use it and we can help you set up the LRC software on it.

Fall 2014 For fall 2014 the LRC will meeting in room EN4045 in the engineering building from 4-6PM on Wednesdays.

We will also provide the robots for the club. We currently have six scribbler robots and a hexapod. Information regarding the LRC robots can be found on the LRC wiki page for Robots and Software.

Ideas for Future Labs

  • Fix Music lab (Lab2b) and incorporate the playSong() command. Also using the doTogether() command have the speak() and beep() commands go at the same time so that you can add lyrics to your song.
  • Using the Graphics library build a lesson where students can get practice with loops to generate animations.
  • Using the Graphics library build a simple game that incorporates events, mouse clicks, and objects moving based on their own rules. Essentially build a lab that present all the basic tools needed for someone to build a cool game of their own devising.