Skip to content


Subversion checkout URL

You can clone with
Download ZIP
Tree: f8c4e45c8b
Fetching contributors…

Cannot retrieve contributors at this time

48 lines (37 sloc) 1.191 kB
Written by Cruz Monrreal II
Created on 06-26-2012
Updates can be found here:
#ifndef Sphero_h
#define Sphero_h
#include <stdint.h>
#include <SoftwareSerial.h>
class Sphero{
// public methods
Sphero( SoftwareSerial &serial );
// Set
//void boost(uint16_t heading, uint8_t duration);
void roll( short heading, char speed );
//void stop();
void setRGBColor( char red, char green, char blue );
void getRGBColor( void );
void setBackLED( char intensity);
//void setRotationRate(uint8_t rate);
void rotateHeadingBy( short heading );
//void setMotionTimeout();
//void setRawMotorValues(uint8_t l_mode, uint8_t r_mode, uint8_t l_pwr, uint8_t r_pwr); // Special note. See Datasheet.
// Get
//void getHeading(uint16_t* data);
String readRawResponse( void );
String readResponseData( void );
void sendSynchronousPacket( char DID, char CID, char SEQ, char DLEN, ... );
void readResponsePacket( void );
SoftwareSerial *bluetooth;
String response;
Jump to Line
Something went wrong with that request. Please try again.