28 #ifndef _SRH_MUSCLE_JOINT_POSITION_CONTROLLER_HPP_ 29 #define _SRH_MUSCLE_JOINT_POSITION_CONTROLLER_HPP_ 32 #include <sr_robot_msgs/JointMusclePositionControllerState.h> 51 virtual void getGains(
double &p,
double &i,
double &
d,
double &i_max,
double &i_min);
53 virtual bool resetGains(std_srvs::Empty::Request &req, std_srvs::Empty::Response &resp);
55 bool setGains(sr_robot_msgs::SetPidGains::Request &req, sr_robot_msgs::SetPidGains::Response &resp);
double position_deadband
the position deadband value used in the hysteresis_deadband
virtual void getGains(double &p, double &i, double &d, double &i_max, double &i_min)
A generic controller for the Shadow Robot EtherCAT hand's joints.
sr_deadband::HysteresisDeadband< double > hysteresis_deadband
We're using an hysteresis deadband.
boost::scoped_ptr< control_toolbox::Pid > pid_controller_position_
Internal PID controller for the position loop.
virtual bool resetGains(std_srvs::Empty::Request &req, std_srvs::Empty::Response &resp)
bool setGains(sr_robot_msgs::SetPidGains::Request &req, sr_robot_msgs::SetPidGains::Response &resp)
virtual void starting(const ros::Time &time)
boost::scoped_ptr< realtime_tools::RealtimePublisher< sr_robot_msgs::JointMusclePositionControllerState > > controller_state_publisher_
publish our joint controller state
virtual void update(const ros::Time &time, const ros::Duration &period)
Issues commands to the joint. Should be called at regular intervals.
SrhMuscleJointPositionController()
bool init(ros_ethercat_model::RobotStateInterface *robot, ros::NodeHandle &n)
int command_acc_
Command accumulator, time to keep the valves open/shut, sign gives the direction. ...
void read_parameters()
read all the controller settings from the parameter server
void setCommandCB(const std_msgs::Float64ConstPtr &msg)
set the position target from a topic