#include "ros/ros.h"
#include <stdio.h>
#include <math.h>
#include "std_msgs/Float64.h"
#include "corobot_msgs/MoveArm.h"
#include "corobot_msgs/ServoPosition.h"
#include "corobot_msgs/ServoType.h"
Go to the source code of this file.
Classes | |
struct | servo |
Enumerations | |
enum | hardware_controller { arbotix, ssc32, phidget } |
enum | servo_type { base_rotation, shoulder, elbow, wrist_flex, wrist_rotation, gripper } |
Functions | |
void | init_servos_db (XmlRpc::XmlRpcValue dynamixels, ros::NodeHandle n) |
initialise the list of servos (variable servos) and the number of servos connected. It reads this from the yaml file. | |
int | main (int argc, char **argv) |
void | setServoPosition (const corobot_msgs::MoveArm &msg) |
Topic to move the arm of the Corobot. | |
Variables | |
ros::Publisher * | arbotix_publisher = NULL |
double | centerOffset = 0.0 |
hardware_controller | controller |
int | number_servo = 0 |
ros::Publisher | position_pub |
servo * | servos = NULL |
ros::Publisher | type_pub |
enum hardware_controller |
Definition at line 61 of file corobot_arm.cpp.
enum servo_type |
This node is used to control an arm on your corobot robot. It subscribes to a topic armPosition of type corobot_msgs/MoveArm. Then, it sends the necessary messages to the necessary node that interfaces with the hardware. This was necessary as many arms are available for the corobot, and the nodes interfacing the different hardware are made by different people and have different interfaces
Definition at line 50 of file corobot_arm.cpp.
void init_servos_db | ( | XmlRpc::XmlRpcValue | dynamixels, |
ros::NodeHandle | n | ||
) |
initialise the list of servos (variable servos) and the number of servos connected. It reads this from the yaml file.
Definition at line 149 of file corobot_arm.cpp.
int main | ( | int | argc, |
char ** | argv | ||
) |
Definition at line 257 of file corobot_arm.cpp.
void setServoPosition | ( | const corobot_msgs::MoveArm & | msg | ) |
Topic to move the arm of the Corobot.
Definition at line 99 of file corobot_arm.cpp.
ros::Publisher* arbotix_publisher = NULL |
Definition at line 93 of file corobot_arm.cpp.
double centerOffset = 0.0 |
Definition at line 81 of file corobot_arm.cpp.
Definition at line 90 of file corobot_arm.cpp.
int number_servo = 0 |
Definition at line 87 of file corobot_arm.cpp.
Definition at line 78 of file corobot_arm.cpp.
Definition at line 84 of file corobot_arm.cpp.
Definition at line 78 of file corobot_arm.cpp.