74 TriggerController::~TriggerController()
99 active = fmod(tick, 1) <
config_.duty_cycle;
153 ROS_DEBUG(
"LOADING TRIGGER CONTROLLER NODE");
160 ROS_DEBUG(
"TriggerController::init starting");
165 ROS_ERROR(
"TriggerController was not given an actuator.");
172 ROS_ERROR(
"TriggerController could not find digital out named \"%s\".",
183 #define bparam(name, var, val) \ 186 n.param(name, tmp, val);\ 204 ROS_DEBUG(
"TriggerController::init completed successfully" 205 " rr=%f ph=%f al=%i r=%i p=%i dc=%f.",
213 ethercat_trigger_controllers::SetWaveform::Response &resp)
218 config_.rep_rate = req.rep_rate;
220 config_.duty_cycle = req.duty_cycle;
221 config_.active_low = !!req.active_low;
223 config_.running = !!req.running;
225 ROS_DEBUG(
"TriggerController::setWaveformSrv completed successfully" 226 " rr=%f ph=%f al=%i r=%i p=%i dc=%f.",
config_.rep_rate,
config_.phase,
boost::scoped_ptr< realtime_tools::RealtimePublisher< std_msgs::Header > > falling_edge_pub_
pr2_hardware_interface::DigitalOutCommand * digital_out_command_
pr2_hardware_interface::HardwareInterface * hw_
ros::NodeHandle node_handle_
ros::ServiceServer set_waveform_handle_
ServiceServer advertiseService(const std::string &service, bool(T::*srv_func)(MReq &, MRes &), T *obj)
DigitalOut * getDigitalOut(const std::string &name) const
boost::scoped_ptr< realtime_tools::RealtimePublisher< std_msgs::Header > > rising_edge_pub_
pr2_mechanism_model::RobotState * robot_
PLUGINLIB_EXPORT_CLASS(pr2_mechanism_model::PR2BeltCompensatorTransmission, pr2_mechanism_model::Transmission) namespace pr2_mechanism_model
bool param(const std::string ¶m_name, T ¶m_val, const T &default_val) const
bool init(pr2_mechanism_model::RobotState *robot, ros::NodeHandle &n)
std::string actuator_name_
trigger_configuration config_
ethercat_trigger_controllers::SetWaveform::Request trigger_configuration
bool getParam(const std::string &key, std::string &s) const
DigitalOutCommand command_
#define bparam(name, var, val)
bool setWaveformSrv(trigger_configuration &req, ethercat_trigger_controllers::SetWaveform::Response &resp)