https://github.com/quantumxt/waypointgen
A waypoint generator (using InteractiveMarkers in Rviz) and a waypoint server for playback.
https://github.com/quantumxt/waypointgen
interactive-markers path ros rviz waypoint waypoint-generator yaml
Last synced: over 1 year ago
JSON representation
A waypoint generator (using InteractiveMarkers in Rviz) and a waypoint server for playback.
- Host: GitHub
- URL: https://github.com/quantumxt/waypointgen
- Owner: quantumxt
- Created: 2019-10-31T07:46:10.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2023-01-05T03:02:52.000Z (over 3 years ago)
- Last Synced: 2024-10-24T15:39:19.963Z (over 1 year ago)
- Topics: interactive-markers, path, ros, rviz, waypoint, waypoint-generator, yaml
- Language: C++
- Homepage:
- Size: 214 KB
- Stars: 0
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# waypointgen
[](https://github.com/quantumxt/waypointgen/actions/workflows/ros_ci.yml)
A waypoint generator (using InteractiveMarkers in Rviz) and a waypoint server for waypoint playback. The waypoints are saved as a **YAML** file.
## Compilation
Git clone the ROS Package into the relevant workspace.
```bash
cd ~/catkin_ws/src
git clone https://github.com/quantumxt/waypointgen.git
```
Compile the package.
```bash
cd ~/catkin_ws
catkin_make
```
or
```bash
cd ~/catkin_ws
catkin build waypointgen
```
## Setpoint Markers

> Utilizing interactive markers for a more visual approach in generating waypoints.
Launch the Waypoint Generator via *roslaunch*, which would launch the program and rviz:
```bash
$ roslaunch waypointgen setpoint_marker.launch
```
Next, add the InteractiveMarker in Rviz. (Topic name: */setpoint_marker/update*)

> Alternatively, load `wp_markers.rviz` into Rviz via `rviz -d wp_markers.rviz`.
There are 3 options available in the context menu (when the marker is _right-clicked_):
- **Get Location**: Get current location of marker selected.
- **Waypoint**
- **Add**: Add new waypoint.
- **Remove**: Remove selected waypoint.
- **Generate Waypoint List**: Generate waypoint list to be used in waypoint playback.
## Waypoint Server
The waypoint server would load the YAML which is specified in the *roslaunch* file, which would then publish the various navigation goals.
> **Note:** The setpoint_server node subscribes to */move_base/TebLocalPlanner/GlobalPath*, so change it accordingly if TebLocalPlanner Plugin is not used!
### Playback
Launch the playback server via *roslaunch*:
```bash
$ roslaunch waypointgen setpoint_server.launch
```
The path of the waypoint list is specified via the `list_path` param, and is set through the `list_path` arguement.
```xml
```
**Starting the server playback**
A ROS Service call would be used to start the playback of the points, call the `/trigger_play` service.
```bash
rosservice call /trigger_play
```
For example, triggering the playback after 3s.
```bash
rosservice call /trigger_play 3
```
## Unit Testing
To run the unit test, ensure that the wayointgen package has been compiled previously.
```bash
catkin build waypointgen
```
After that, compile the test.
```bash
catkin test waypointgen
```
## Changelog
### v0.1.0
- Initial commit.
### v0.1.1
- Convert functions to classes.
- Refactored code.
- Replace ros topic subscription to ros service to trigger playback.
- Add ROS CI.
### v0.1.2
- Add benchmark metrics.
- Split into seperate ROS nodes.
- Refactored code.
- Removed custom msg.
- Update launch files.
### v0.1.3
- Add unit tests & rostest for utils.