Refactor from my_robot to raspbot-v2
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
# my_robot
|
||||
# raspbot_v2
|
||||
|
||||
ROS 2 package for the Yahboom Raspbot V2 platform — differential-drive motor control and pan/tilt camera orientation.
|
||||
|
||||
@@ -139,7 +139,7 @@ The [ansible/](ansible/) directory contains a playbook that handles the remainin
|
||||
The Raspberry Pi is `arm64`, so the image must be built for that platform. On an amd64 host use `docker buildx`:
|
||||
|
||||
```bash
|
||||
docker build --platform linux/arm64 -t my_robot:latest .
|
||||
docker build --platform linux/arm64 -t raspbot_v2:latest .
|
||||
```
|
||||
|
||||
`--load` exports the built image into the local Docker image store so it can be deployed with `docker save`.
|
||||
@@ -156,7 +156,7 @@ The build is split into two stages:
|
||||
Once the image is built, pipe it directly to the target over SSH — no intermediate file or registry needed:
|
||||
|
||||
```bash
|
||||
docker save my_robot:latest | ssh matt@raspbot-v2.local docker load
|
||||
docker save raspbot_v2:latest | ssh matt@raspbot-v2.local docker load
|
||||
```
|
||||
|
||||
Replace `matt` with the username configured in [ansible/inventory.ini](ansible/inventory.ini).
|
||||
@@ -172,7 +172,7 @@ docker run --rm \
|
||||
--network=host \
|
||||
--device /dev/i2c-1 \
|
||||
--env ROS_DOMAIN_ID=0 \
|
||||
my_robot:latest
|
||||
raspbot_v2:latest
|
||||
```
|
||||
|
||||
If your board exposes the controller on a different bus (check with `ls /dev/i2c-*` on the host), substitute the correct device node (e.g. `--device /dev/i2c-0`).
|
||||
@@ -186,8 +186,8 @@ docker run --rm \
|
||||
--network=host \
|
||||
--device /dev/i2c-1 \
|
||||
--env ROS_DOMAIN_ID=0 \
|
||||
my_robot:latest \
|
||||
ros2 launch my_robot robot.launch.py \
|
||||
raspbot_v2:latest \
|
||||
ros2 launch raspbot_v2 robot.launch.py \
|
||||
wheel_base:=0.25 max_speed:=0.8 tilt_center_deg:=45.0
|
||||
```
|
||||
|
||||
@@ -254,12 +254,12 @@ ros2 topic echo /joint_states
|
||||
├── Dockerfile # Two-stage production image
|
||||
├── docker-entrypoint.sh # Sources ROS overlays before exec
|
||||
├── src/
|
||||
│ └── my_robot/
|
||||
│ └── raspbot_v2/
|
||||
│ ├── package.xml # ROS package manifest
|
||||
│ ├── setup.py # ament_python build definition
|
||||
│ ├── launch/
|
||||
│ │ └── robot.launch.py # Starts both nodes together
|
||||
│ └── my_robot/
|
||||
│ └── raspbot_v2/
|
||||
│ ├── __init__.py
|
||||
│ ├── motor_controller_node.py # Differential-drive motor control
|
||||
│ └── camera_orientation_node.py # Pan/tilt servo control
|
||||
|
||||
Reference in New Issue
Block a user