![]() |
Autonomous Racing
1
f1tenth Project Group of Technical University Dortmund, Germany
|
#include <SDL2/SDL.h>#include <SDL2/SDL_keycode.h>#include <algorithm>#include <array>#include <drive_msgs/drive_param.h>#include <ros/package.h>#include <ros/ros.h>#include <signal.h>#include <std_msgs/Int32.h>#include <stdexcept>#include <dynamic_reconfigure/server.h>#include <teleoperation/keyboard_controllerConfig.h>

Go to the source code of this file.
Classes | |
| class | KeyboardController |
Enumerations | |
| enum | Keycode : int { Keycode::SPACE = SDLK_SPACE, Keycode::A = SDLK_a, Keycode::B = SDLK_b, Keycode::D = SDLK_d, Keycode::S = SDLK_s, Keycode::W = SDLK_w } |
| enum | KeyIndex : size_t { KeyIndex::ACCELERATE = 0, KeyIndex::DECELERATE = 2, KeyIndex::STEER_LEFT = 1, KeyIndex::STEER_RIGHT = 3, KeyIndex::ENABLE_MANUAL = 4, KeyIndex::ENABLE_AUTONOMOUS = 5 } |
| enum | DriveMode : int { DriveMode::LOCKED = 0, DriveMode::MANUAL = 1, DriveMode::AUTONOMOUS = 2, DriveMode::LOCKED = 0, DriveMode::MANUAL = 1, DriveMode::AUTONOMOUS = 2 } |
Variables | |
| constexpr const char * | TOPIC_DRIVE_PARAMETERS = "input/drive_param/keyboard" |
| constexpr const char * | TOPIC_HEARTBEAT_MANUAL = "/input/heartbeat_manual" |
| constexpr const char * | TOPIC_HEARTBEAT_AUTONOMOUS = "/input/heartbeat_autonomous" |
| constexpr const char * | TOPIC_DRIVE_MODE = "/commands/drive_mode" |
| constexpr double | PARAMETER_UPDATE_FREQUENCY = 90 |
| constexpr int | SCREEN_EDGE_MARGIN = 20 |
|
strong |
| Enumerator | |
|---|---|
| LOCKED | |
| MANUAL | |
| AUTONOMOUS | |
| LOCKED | |
| MANUAL | |
| AUTONOMOUS | |
Definition at line 42 of file keyboard_controller.h.
|
strong |
| Enumerator | |
|---|---|
| SPACE | |
| A | |
| B | |
| D | |
| S | |
| W | |
Definition at line 22 of file keyboard_controller.h.
|
strong |
| Enumerator | |
|---|---|
| ACCELERATE | |
| DECELERATE | |
| STEER_LEFT | |
| STEER_RIGHT | |
| ENABLE_MANUAL | |
| ENABLE_AUTONOMOUS | |
Definition at line 32 of file keyboard_controller.h.
| constexpr double PARAMETER_UPDATE_FREQUENCY = 90 |
Definition at line 49 of file keyboard_controller.h.
| constexpr int SCREEN_EDGE_MARGIN = 20 |
Definition at line 50 of file keyboard_controller.h.
| constexpr const char* TOPIC_DRIVE_MODE = "/commands/drive_mode" |
Definition at line 20 of file keyboard_controller.h.
| constexpr const char* TOPIC_DRIVE_PARAMETERS = "input/drive_param/keyboard" |
Definition at line 17 of file keyboard_controller.h.
| constexpr const char* TOPIC_HEARTBEAT_AUTONOMOUS = "/input/heartbeat_autonomous" |
Definition at line 19 of file keyboard_controller.h.
| constexpr const char* TOPIC_HEARTBEAT_MANUAL = "/input/heartbeat_manual" |
Definition at line 18 of file keyboard_controller.h.