Server information packets, Erver, Nformation – Pioneer 2TM User Manual

Page 39: Ackets

Advertising
background image

ActivMedia Robotics

S

ERVER

I

NFORMATION

P

ACKETS

Like its PSOS and P2OS predecessors, AROS automatically and repeatedly sends a
packet of information over its HOST serial port to a connected client. The standard AROS

SIP informs the client about a number of operating states and readings, using the order

and data types described in the nearby Table.

Table 3. Standard Server Information Packet

NAME

VALUE

DESCRIPTION

HEADER

int

Exactly

0xFA,

0xFB

BYTE COUNT

byte

Number of data bytes + 2 (checksum), not including header or
byte-count bytes

STATUS

/

PACKET

0x3S =

Motors status

TYPE

2

Motors

stopped

3

Robot

moving

XPOS

int

Wheel-encoder integrated coordinates; platform-dependent units;
multiply by DistConvFactor

YPOS

int

to convert to millimeters.

THPOS

sint

Orientation in platform-dependent units—multiply by
AngleConvFactor

for degrees.

L VEL

sint

Wheel velocities in mm/sec (VelConvFactor

= 1.0)

R VEL

sint

BATTERY

byte

Battery charge in tenths of volts (101 = 10.1 volts, for example)

STALL AND

BUMPERS

int

Motor stall and bumper indicators. Bit 0 is the left wheel stall
indicator, set to 1 if stalled. Bits 1-7 correspond to the first bumper
I/O digital input states (accessory dependent). Bit 8 is the right
wheel stall, and bits 9-15 correspond the second bumper I/O
states, also accessory and application dependent.

CONTROL

sint

Setpoint of the server’s angular position servo—multiply by
AngleConvFactor

for degrees

FLAGS

sint

Bit 0 motors status; bits 1-4 sonar array status; bits 5,6 M-STOP;
bits 7,8 ledge-sense IRs; bit 9 joystick button; bit 10 auto—
charger power-good.

COMPASS

byte

Electronic compass accessory heading in 2-degree units

SONAR COUNT

byte

Number of new sonar readings included in SIP

NUMBER

byte

If Sonar Count>0, is sonar disc number 0-31; reading follows

RANGE

int

Sonar range value; multiply by RangeConvFactor

REST OF THE SONAR READINGS

GRIP

_

STATE

byte

Gripper

state

byte.

ANPORT

byte

Selected analog port number 1-5

ANALOG

byte

User Analog input (0-255=0-5 VDC) reading on selected port

DIGIN

byte

Byte-encoded User I/O digital input

DIGOUT

byte

Byte-endcoded User I/O digital output

CHECKSUM

integer

Packet-integrity

checksum

Client-side data-conversion factor. Consult the ARIA parameter file your robot.

Explicitly, a signed integer.

AROS also supports several additional SIP types. These include an “alternative” SIP that
currently is not supported by Saphira or ARIA.

15

See following sections in this chapter for a

description of the extended SIP types.

15

Indeed, if enabled, the alternative SIP apparently will “break” the client software. Read carefully.

33

Advertising
This manual is related to the following products:

3TM