Iowa State University

CPRE 288 Laboratory


Lab 2: iRobot Open Interface and Movement

Lecture - Lab Connection

In lecture, you have continued an overview of C programming and have started learning about structures. In this lab, we are using the TI Launchpad microcontroller board to control the iRobot Create. The TM4C123G processor has been wired so communication between the iRobot Create and the processor is streamlined. The Open Interface files provided below hides the communication over serial so that you can be a more productive programmer working with functions at a higher level of abstraction.

Prelab

  • Read through the lab description, including the linked documents.
  • Skim the reference documents below; in particular, you should read the iRobot Create - Open Interface (pages 23-32) specification and gain a good basic understanding of the commands you are able to send the iRobot and the sensor packets it returns to the processor.

Reference Documents

All reference documents are also available on the Resources page of the course website.

Reference Files

Download the following files to a single folder your U: drive. (Right-click and select 'Save Target As')

  • open_interface.c: The API functions for the most basic Open Interface functions
  • open_interface.h: The header file for open_interface.c
  • lcd.c: A program file with a number of LCD functions
  • lcd.h: The header file for lcd.c
  • Timer.c: A program file with a number of time functions
  • Timer.h: The header file for timer.c
  • cyBot_uart.h: Header for pre-compiled CyBot/Human UART communication
  • libcybotUART.lib: Pre-compiled Library for CyBot/Human UART communication (Note: Must change extension from .txt to .lib after copying, Do not try to open file as it will corrupt the file causing a Linker error)

Lab 2 Description

  • Lab 2 Manual: A detailed description of the objectives to complete for Lab 2

Cautions

Turn the power to the cyBOT platform off before charging. The Launchpad board consumes power and the battery will not charge if the robot is in full_mode (which it enters after calling oi_init, turning the power LED yellow). You will have to turn off open interface. The robot is charging when the robot's power LED is pulsing red and both green LEDS on the dock are lit.

Reference Files

Files Description
iRobot Open Interface Datasheet Information about the iRobot Create Open Interface
Online Feedback Form Tell us what you think of the lab (feedback forms)