Public Member Functions | Public Attributes | Private Member Functions | Private Attributes
irobot.create.Create Class Reference

List of all members.

Public Member Functions

def __del__
def __getattr__
def __init__
def brake
def clear
def clearAngle
def clearDistance
def demo
def forwardTurn
def leds
def left
def playSong
def reset
def right
def send
def start
def stop
def storeSong
def tank
def turn

Public Attributes

 angleLock
 distanceLock
 packetRef
 period
 port
 portLock
 queue
 queueLock
 runRef
 timeout
 update

Private Member Functions

def __addAngle
def __addDistance
def __convert
def __highLow
def __read
def __sendAll
def __sendNow
def __twos

Private Attributes

 __angle
 __distance

Detailed Description

Wrapper class for the iRobot Create

Definition at line 125 of file create.py.


Constructor & Destructor Documentation

def irobot.create.Create.__init__ (   self,
  tty = "/dev/ttyUSB0" 
)
constructor for the Create, takes in a single argument: the serial port

Definition at line 128 of file create.py.

Definition at line 261 of file create.py.


Member Function Documentation

def irobot.create.Create.__addAngle (   self,
  num 
) [private]

Definition at line 240 of file create.py.

def irobot.create.Create.__addDistance (   self,
  num 
) [private]

Definition at line 233 of file create.py.

def irobot.create.Create.__convert (   self,
  num 
) [private]

Definition at line 179 of file create.py.

def irobot.create.Create.__getattr__ (   self,
  name 
)

Definition at line 227 of file create.py.

def irobot.create.Create.__highLow (   self,
  num 
) [private]

Definition at line 182 of file create.py.

def irobot.create.Create.__read (   self,
  num,
  block = False 
) [private]

Definition at line 217 of file create.py.

def irobot.create.Create.__sendAll (   self) [private]

Definition at line 207 of file create.py.

def irobot.create.Create.__sendNow (   self,
  opcodes 
) [private]

Definition at line 200 of file create.py.

def irobot.create.Create.__twos (   self,
  num,
  bits = 16 
) [private]

Definition at line 185 of file create.py.

Stops the iCreate, takes no parameters

Definition at line 264 of file create.py.

Definition at line 257 of file create.py.

Definition at line 252 of file create.py.

Definition at line 247 of file create.py.

def irobot.create.Create.demo (   self,
  num 
)
Takes a single parameter, the number of the demo to begin. "Running" demo -1 will stop the demo. After using this function the iCreate must be reset.

Definition at line 268 of file create.py.

def irobot.create.Create.forwardTurn (   self,
  speed,
  radius 
)
Takes two parameters: speed and radius. Drives the iCreate at speed with enough of an angle that the iCreate will carve a circle with the given radius. Speed is in mm/s and can vary between -500 and 500. The radius can vary between -2000 and 2000 mm (with negative mm turning left).

Definition at line 311 of file create.py.

def irobot.create.Create.leds (   self,
  play,
  advance,
  color,
  intensity 
)
Controls the LEDs. Parameters are play: boolean (play on/off), advance: boolean (advance on/off), color: 0-255 (how much red in the power light), and intensity: 0-255 (how bright should the power light be.

Definition at line 277 of file create.py.

def irobot.create.Create.left (   self,
  speed 
)
Takes in a parameter: speed and turns counter-clockwise in place at speed mm/s.

Definition at line 339 of file create.py.

def irobot.create.Create.playSong (   self,
  num 
)
Plays a song. Takes one parameter, the song number.

Definition at line 296 of file create.py.

Reset the iCreate.

Definition at line 166 of file create.py.

def irobot.create.Create.right (   self,
  speed 
)
Takes in a parameter: speed and turns clockwise in place at speed mm/s.

Definition at line 335 of file create.py.

def irobot.create.Create.send (   self,
  opcodes 
)

Definition at line 190 of file create.py.

Start the iCreate after initialization or reset.

Definition at line 146 of file create.py.

def irobot.create.Create.stop (   self)
Stop the iCreate. Must be called before deletion of the iCreate object.

Definition at line 157 of file create.py.

def irobot.create.Create.storeSong (   self,
  num,
  song 
)
Store a song. First parameter is the song number, the remaming arguments are taken to be of the form: note, duration, note, duration, etc. See page 12 of the iRobot Create Open Interface Manual for numerical note definitions. Duration is interpreted as duration*1/64th of a second.

Definition at line 290 of file create.py.

def irobot.create.Create.tank (   self,
  left,
  right 
)
Drive the iCreate like a tank (i.e. left throttle, right throttle). Takes two parameters: left and right throttle. Each can be between -500 and 500 representing mm/s.  If either are outside of this range, both throttles will be linearly scaled to fit inside the range

Definition at line 301 of file create.py.

def irobot.create.Create.turn (   self,
  speed 
)

Definition at line 332 of file create.py.


Member Data Documentation

Definition at line 128 of file create.py.

Definition at line 128 of file create.py.

Definition at line 128 of file create.py.

Definition at line 128 of file create.py.

Definition at line 128 of file create.py.

Definition at line 128 of file create.py.

Definition at line 128 of file create.py.

Definition at line 128 of file create.py.

Definition at line 128 of file create.py.

Definition at line 128 of file create.py.

Definition at line 128 of file create.py.

Definition at line 128 of file create.py.

Definition at line 128 of file create.py.


The documentation for this class was generated from the following file:


irobot_create_2_1
Author(s): Graylin Trevor Jay, Brian Thomas
autogenerated on Fri Jan 3 2014 11:10:15