34 #include <geometry_msgs/Twist.h> 35 #include <sensor_msgs/Joy.h> 36 #include <svenzva_msgs/GripperAction.h> 56 void joyCallback(
const sensor_msgs::Joy::ConstPtr& joy);
98 geometry_msgs::Twist twist;
112 int main(
int argc,
char** argv)
114 ros::init(argc, argv,
"svenzva_6axis_controller");
118 bool gripper_open =
true;
120 while(svenzva_joy.
valid ==
false){
129 svenzva_msgs::GripperGoal goal;
131 goal.target_action = goal.CLOSE;
132 goal.target_current = 200;
133 gripper_open =
false;
136 goal.target_action = goal.OPEN;
sensor_msgs::Joy last_cmd
bool waitForServer(const ros::Duration &timeout=ros::Duration(0, 0)) const
actionlib::SimpleActionClient< svenzva_msgs::GripperAction > gripperClient
void publish(const boost::shared_ptr< M > &message) const
Subscriber subscribe(const std::string &topic, uint32_t queue_size, void(T::*fp)(M), T *obj, const TransportHints &transport_hints=TransportHints())
ROSCPP_DECL void init(int &argc, char **argv, const std::string &name, uint32_t options=0)
void joyCallback(const sensor_msgs::Joy::ConstPtr &joy)
bool param(const std::string ¶m_name, T ¶m_val, const T &default_val) const
SimpleClientGoalState sendGoalAndWait(const Goal &goal, const ros::Duration &execute_timeout=ros::Duration(0, 0), const ros::Duration &preempt_timeout=ros::Duration(0, 0))
Publisher advertise(const std::string &topic, uint32_t queue_size, bool latch=false)
int main(int argc, char **argv)
ROSCPP_DECL void spinOnce()