Implement the mapping API - #8
Closed
glennswagner wants to merge 1 commit into
Closed
glennswagner wants to merge 1 commit into
glennswagner wants to merge 1 commit into
Conversation
Adds commands for -getting hovermap status -setting scan name prefix -starting/stopping scans -fetching the name of all completed scans -downloading specified scan
There was a problem hiding this comment.
Pull request overview
This PR introduces a ROS-facing “mapping API” layer that bridges ROS topics to the Hovermap’s HTTP endpoints, adds a dedicated message package for API status/scan metadata, and updates launch/docker/docs to support scan control and scan download workflows.
Changes:
- Added
http_interface_nodeto expose start/stop scan, scan prefix, scan listing, scan download, and status polling via ROS topics. - Introduced new
hovermap_api_msgsmessage package for status and scan list payloads. - Updated launch, build/install, Docker, and README to wire up and document the new API topics and download directory mount.
Reviewed changes
Copilot reviewed 12 out of 13 changed files in this pull request and generated 7 comments.
Show a summary per file
| File | Description |
|---|---|
| src/hovermap_api/scripts/http_interface_node | New ROS node that calls Hovermap HTTP endpoints and publishes status/scan list/download outcomes. |
| src/hovermap_api/scripts/configure_perception | One-shot publisher script for sending perception YAML configuration. |
| src/hovermap_api/package.xml | Adds dependency on the new hovermap_api_msgs package. |
| src/hovermap_api/launch/api.launch | Launches the new http_interface_node under the cortex namespace. |
| src/hovermap_api/CMakeLists.txt | Adds hovermap_api_msgs dependency and installs the new Python node. |
| src/hovermap_api_msgs/package.xml | New message package manifest. |
| src/hovermap_api_msgs/msg/ScanInformationList.msg | New message for returning scan lists. |
| src/hovermap_api_msgs/msg/ScanInformation.msg | New message for per-scan metadata. |
| src/hovermap_api_msgs/msg/HovermapStatus.msg | New message for Hovermap status publication. |
| src/hovermap_api_msgs/CMakeLists.txt | Message generation configuration for hovermap_api_msgs. |
| README.md | Documents new topics and how scan download works in Docker. |
| docker/run_docker | Adds optional host bind-mount for /data/downloads. |
| docker/Dockerfile | Refactors pip install step to be cached via BuildKit bind-mount. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
+6
to
+7
| import urllib.request | ||
| import urllib.error |
Comment on lines
+159
to
+161
| except urllib.error.URLError as e: | ||
| rospy.logerr(f"Download failed for '{scan_name}': {e.reason}") | ||
| self._scan_download_successful_pub.publish(result_msg) |
Comment on lines
+163
to
+164
| def _on_set_scan_prefix(self, msg): | ||
| self._get(f"/setprefix?prefix={msg.data}") |
Comment on lines
+29
to
+39
| EXTRA_MOUNTS="" | ||
| if [[ $# -ge 1 ]]; then | ||
| DOWNLOAD_DIR="$(realpath "$1")" | ||
| mkdir -p "$DOWNLOAD_DIR" | ||
| EXTRA_MOUNTS="--mount type=bind,src=$DOWNLOAD_DIR,dst=/data/downloads" | ||
| fi | ||
|
|
||
| docker run -it --rm --network=host \ | ||
| --mount type=bind,src="$REPO_ROOT/src",dst=/ros_ws/src \ | ||
| $EXTRA_MOUNTS \ | ||
| "${IMAGE_NAME}" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds commands for
-getting hovermap status
-setting scan name prefix
-starting/stopping scans
-fetching the name of all completed scans
-downloading specified scan