mbasedriverMotorPacket Class Reference

Copyright (C) 2010 Ana Teresa Hernández Malagón Movirobotics Player - One Hell of a Robot Server Copyright (C) 2000 Brian Gerkey, Kasper Stoy, Richard Vaughan, & Andrew Howard. More...

#include <motorpacket.h>

Collaboration diagram for mbasedriverMotorPacket:
Collaboration graph

Detailed Description

Copyright (C) 2010 Ana Teresa Hernández Malagón Movirobotics Player - One Hell of a Robot Server Copyright (C) 2000 Brian Gerkey, Kasper Stoy, Richard Vaughan, & Andrew Howard.

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA Movirobotic's mBase robot driver for Player 3.0.1 based on erratic driver developed by Brian Gerkey, Kasper Stoy, Richard Vaughan, & Andrew Howard. Developed by Ana Teresa Herández Malagón.

Public Member Functions

bool Parse (unsigned char *buffer, int length)
 Parse -Parses and absorbs a standard packet from the robot. More...
 
void Print ()
 Copyright (C) 2010 Ana Teresa Hernández Malagón Movirobotics Player - One Hell of a Robot Server Copyright (C) 2000 Brian Gerkey, Kasper Stoy, Richard Vaughan, & Andrew Howard. More...
 
void Fill (player_mbasedriver_data_t *data)
 Fill. More...
 
 mbasedriverMotorPacket (int idx)
 

Public Attributes

bool lwstall
 
bool rwstall
 
int battery
 
short angle
 
short lvel
 
short rvel
 
int xpos
 
int ypos
 

Private Attributes

int param_idx
 

Member Function Documentation

◆ Fill()

void mbasedriverMotorPacket::Fill ( player_mbasedriver_data_t *  data)

Fill.

  • Spits out information that was previously parsed

De momento el IOM no devuleve voltios si no un valor que hay que transformar

References PLAYER_POWER_MASK_PERCENT, and PLAYER_POWER_MASK_VOLTS.

Referenced by mbasedriver::ReceiveThread().

◆ Parse()

bool mbasedriverMotorPacket::Parse ( unsigned char *  buffer,
int  length 
)

Parse -Parses and absorbs a standard packet from the robot.

Descomentar cuando el IOM este preparado para dar un valor correcto de stall lwstall = buffer[cnt] & 0x01; cnt += sizeof(unsigned char); rwstall = buffer[cnt] & 0x01; cnt += sizeof(unsigned char);

Referenced by mbasedriver::ReceiveThread().

◆ Print()

void mbasedriverMotorPacket::Print ( )

Copyright (C) 2010 Ana Teresa Hernández Malagón Movirobotics Player - One Hell of a Robot Server Copyright (C) 2000 Brian Gerkey, Kasper Stoy, Richard Vaughan, & Andrew Howard.

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA Movirobotic's mBase robot driver for Player 3.0.1 based on erratic driver developed by Brian Gerkey, Kasper Stoy, Richard Vaughan, & Andrew Howard. Developed by Ana Teresa Herández Malagón. Print


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