Public Member Functions | Private Member Functions | Private Attributes | List of all members
kobuki::BumpBlinkController Class Reference

#include <bump_blink_controller.hpp>

Inheritance diagram for kobuki::BumpBlinkController:
Inheritance graph
[legend]

Public Member Functions

 BumpBlinkController (ros::NodeHandle &nh, std::string &name)
 
bool init ()
 
 ~BumpBlinkController ()
 
- Public Member Functions inherited from yocs::Controller
 Controller ()
 
bool disable ()
 
bool enable ()
 
bool getState ()
 
virtual void spin ()
 
virtual ~Controller ()
 

Private Member Functions

void bumperEventCB (const kobuki_msgs::BumperEventConstPtr msg)
 Turns on/off a LED, when a bumper is pressed/released. More...
 
void disableCB (const std_msgs::EmptyConstPtr msg)
 ROS logging output for disabling the controller. More...
 
void enableCB (const std_msgs::EmptyConstPtr msg)
 ROS logging output for enabling the controller. More...
 

Private Attributes

ros::Publisher blink_publisher_
 
ros::Subscriber bumper_event_subscriber_
 
ros::Subscriber disable_controller_subscriber_
 
ros::Subscriber enable_controller_subscriber_
 
std::string name_
 
ros::NodeHandle nh_
 

Detailed Description

@ brief A simple bump-blink-controller

A simple nodelet-based controller for Kobuki, which makes one of Kobuki's LEDs blink, when a bumper is pressed.

Definition at line 65 of file bump_blink_controller.hpp.

Constructor & Destructor Documentation

kobuki::BumpBlinkController::BumpBlinkController ( ros::NodeHandle nh,
std::string &  name 
)
inline

Definition at line 68 of file bump_blink_controller.hpp.

kobuki::BumpBlinkController::~BumpBlinkController ( )
inline

Definition at line 69 of file bump_blink_controller.hpp.

Member Function Documentation

void kobuki::BumpBlinkController::bumperEventCB ( const kobuki_msgs::BumperEventConstPtr  msg)
private

Turns on/off a LED, when a bumper is pressed/released.

Parameters
msgincoming topic message

Definition at line 135 of file bump_blink_controller.hpp.

void kobuki::BumpBlinkController::disableCB ( const std_msgs::EmptyConstPtr  msg)
private

ROS logging output for disabling the controller.

Parameters
msgincoming topic message

Definition at line 123 of file bump_blink_controller.hpp.

void kobuki::BumpBlinkController::enableCB ( const std_msgs::EmptyConstPtr  msg)
private

ROS logging output for enabling the controller.

Parameters
msgincoming topic message

Definition at line 111 of file bump_blink_controller.hpp.

bool kobuki::BumpBlinkController::init ( )
inlinevirtual

Set-up necessary publishers/subscribers

Returns
true, if successful

Implements yocs::Controller.

Definition at line 75 of file bump_blink_controller.hpp.

Member Data Documentation

ros::Publisher kobuki::BumpBlinkController::blink_publisher_
private

Definition at line 90 of file bump_blink_controller.hpp.

ros::Subscriber kobuki::BumpBlinkController::bumper_event_subscriber_
private

Definition at line 89 of file bump_blink_controller.hpp.

ros::Subscriber kobuki::BumpBlinkController::disable_controller_subscriber_
private

Definition at line 88 of file bump_blink_controller.hpp.

ros::Subscriber kobuki::BumpBlinkController::enable_controller_subscriber_
private

Definition at line 88 of file bump_blink_controller.hpp.

std::string kobuki::BumpBlinkController::name_
private

Definition at line 87 of file bump_blink_controller.hpp.

ros::NodeHandle kobuki::BumpBlinkController::nh_
private

Definition at line 83 of file bump_blink_controller.hpp.


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


kobuki_controller_tutorial
Author(s): Marcus Liebhardt
autogenerated on Mon Jun 10 2019 13:45:01