Log joystick data gathered via RemoteBlackBoard to console. More...

Public Member Functions | |
| JoystickBlackBoardLogger (ArgumentParser &argp, Logger *logger) | |
| Constructor. | |
| ~JoystickBlackBoardLogger () | |
| Destructor. | |
| virtual void | bb_interface_data_changed (Interface *interface) throw () |
| BlackBoard data changed notification. | |
| void | handle_signal (int signum) |
| Signal hanlding method. | |
| void | run () |
| Wait for quit signal from signal handler. | |
Log joystick data gathered via RemoteBlackBoard to console.
Definition at line 165 of file ffjoystick.cpp.
| JoystickBlackBoardLogger::JoystickBlackBoardLogger | ( | ArgumentParser & | argp, | |
| Logger * | logger | |||
| ) | [inline] |
Constructor.
| argp | argument parser | |
| logger | logger |
Definition at line 174 of file ffjoystick.cpp.
References fawkes::BlackBoardInterfaceListener::bbil_add_data_interface(), fawkes::Logger::log_debug(), fawkes::JoystickInterface::num_axes(), fawkes::JoystickInterface::num_buttons(), fawkes::BlackBoard::open_for_reading(), fawkes::ArgumentParser::parse_hostport(), fawkes::Interface::read(), and fawkes::BlackBoard::register_listener().
| JoystickBlackBoardLogger::~JoystickBlackBoardLogger | ( | ) | [inline] |
| virtual void JoystickBlackBoardLogger::bb_interface_data_changed | ( | Interface * | interface | ) | throw () [inline, virtual] |
BlackBoard data changed notification.
This is called whenever the data in an interface that you registered for is modified. This happens if a writer calls the Interface::write() method.
| interface | interface instance that you supplied to bbil_add_data_interface() |
Reimplemented from fawkes::BlackBoardInterfaceListener.
Definition at line 203 of file ffjoystick.cpp.
References fawkes::JoystickInterface::axis_x(), fawkes::JoystickInterface::axis_y(), fawkes::BlackBoard::is_alive(), fawkes::Logger::log_info(), fawkes::Logger::log_warn(), fawkes::JoystickInterface::pressed_buttons(), fawkes::Exception::print_trace(), fawkes::Interface::read(), and fawkes::BlackBoard::try_aliveness_restore().
| void JoystickBlackBoardLogger::handle_signal | ( | int | signum | ) | [inline, virtual] |
Signal hanlding method.
Implement this method with the action you want to perform on the registered signals.
| signum | signal number of triggered signal |
Implements fawkes::SignalHandler.
Definition at line 237 of file ffjoystick.cpp.
References fawkes::WaitCondition::wake_all().
| void JoystickBlackBoardLogger::run | ( | ) | [inline] |
Wait for quit signal from signal handler.
Definition at line 243 of file ffjoystick.cpp.
References fawkes::WaitCondition::wait().
1.6.1