Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft: Preparing for v2 hardware interface #129

Draft
wants to merge 30 commits into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
30 commits
Select commit Hold shift + click to select a range
3af3eba
Refactoring: Remove legacy localization (#128)
ClemensElflein Jul 24, 2024
af64cf7
wip
ClemensElflein Jul 24, 2024
0f5c796
wip
ClemensElflein Jul 25, 2024
85f9f79
extracted emergency into its own message
ClemensElflein Jul 25, 2024
dc1fd2a
wip
ClemensElflein Jul 26, 2024
60696db
wip
ClemensElflein Sep 9, 2024
beb3ebd
removed dependencies
ClemensElflein Sep 9, 2024
db9d770
wip
ClemensElflein Sep 9, 2024
a9d6cc6
allow specifying bind_ip
ClemensElflein Sep 10, 2024
fd05572
wip
ClemensElflein Sep 10, 2024
f96e951
update xbot_framework
ClemensElflein Sep 10, 2024
fe5d4fa
add v2 comms to launch file
ClemensElflein Sep 10, 2024
46b997e
update xbot_framework
ClemensElflein Sep 10, 2024
e0c717a
added wheel ticks to status messages
ClemensElflein Sep 10, 2024
fbe4f5e
added params for Lubluelu robot
ClemensElflein Sep 10, 2024
ff64e15
fixed launch file
ClemensElflein Sep 10, 2024
ff4b7f0
wip lidar comms
ClemensElflein Sep 10, 2024
541e37f
fixed lidar
ClemensElflein Sep 11, 2024
3256fc5
wip lidar
ClemensElflein Sep 11, 2024
5a5f028
very much wip
ClemensElflein Nov 13, 2024
f8b91f9
update xbot_positioning
ClemensElflein Nov 29, 2024
7d7cb47
Merge branch 'main' into refactoring/mower-comms-rework
ClemensElflein Nov 29, 2024
01a240d
fixed build
ClemensElflein Nov 29, 2024
51c4a67
fixed build
ClemensElflein Nov 29, 2024
06f4033
Implemented robot simulation using v2 protocol
ClemensElflein Nov 30, 2024
046ba75
Removed old robot simulator
ClemensElflein Nov 30, 2024
dc6b1be
SimRobot now not moving when emergency is active
ClemensElflein Nov 30, 2024
1c4a95d
fixed Dockerfile
ClemensElflein Nov 30, 2024
8a42fe2
wip
ClemensElflein Nov 30, 2024
18a1184
Updated xbot_framework
ClemensElflein Dec 12, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -59,3 +59,4 @@ CATKIN_IGNORE

cmake-build-debug/
.vscode
.venv
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -25,3 +25,6 @@
[submodule "src/lib/xbot_remote"]
path = src/lib/xbot_remote
url = https://github.com/ClemensElflein/xbot_remote
[submodule "src/lib/xbot_framework"]
path = src/lib/xbot_framework
url = https://github.com/ClemensElflein/xbot_framework.git
6 changes: 3 additions & 3 deletions docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ ENV DEBIAN_FRONTEND=noninteractive
# - nginx (remove default site to free up port 80)
RUN apt-get update && apt-get install --yes \
git \
mosquitto \
mosquitto python3.8-venv \
nginx && rm -rf /var/www /etc/nginx/sites-enabled/* \
rm -rf /var/lib/apt/lists/*

Expand Down Expand Up @@ -43,7 +43,7 @@ COPY --link --from=fetch /opt/open_mower_ros/src/lib/slic3r_coverage_planner /op
WORKDIR /opt/slic3r_coverage_planner_workspace
RUN rosdep install --from-paths src --ignore-src --simulate | \
sed --expression '1d' | sort | tr -d '\n' | sed --expression 's/ apt-get install//g' > apt-install_list && \
apt-get update && apt-get install --no-install-recommends --yes $(cat apt-install_list) && \
apt-get update && apt-get install --no-install-recommends --yes $(cat apt-install_list) libasio-dev && \
rm -rf /var/lib/apt/lists/* apt-install_list
RUN bash -c "source /opt/ros/$ROS_DISTRO/setup.bash && catkin_make"
RUN bash -c "source /opt/ros/$ROS_DISTRO/setup.bash && source /opt/slic3r_coverage_planner_workspace/devel/setup.bash && catkin_make -DCMAKE_INSTALL_PREFIX=/opt/prebuilt/slic3r_coverage_planner install"
Expand Down Expand Up @@ -77,7 +77,7 @@ COPY --link --from=slic3r /opt/prebuilt/slic3r_coverage_planner /opt/prebuilt/sl
#Fetch the list of packages, this only changes if new dependencies have been added (only sometimes)
COPY --link --from=dependencies /apt-install_list /apt-install_list
RUN apt-get update && \
apt-get install --no-install-recommends --yes $(cat /apt-install_list) && \
apt-get install --no-install-recommends --yes $(cat /apt-install_list) libasio-dev && \
rm -rf /var/lib/apt/lists/*

# This will already have the submodules initialized, no need to clone again
Expand Down
65 changes: 65 additions & 0 deletions services/diff_drive_service.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
{
"inputs": [
{
"id": 0,
"name": "Control Twist",
"type": "double[6]"
}
],
"outputs": [
{
"id": 0,
"name": "Actual Twist",
"type": "double[6]"
},
{
"id": 1,
"name": "Left ESC Status",
"type": "uint8_t"
},
{
"id": 2,
"name": "Left ESC Temperature",
"type": "float"
},
{
"id": 3,
"name": "Left ESC Current",
"type": "float"
},
{
"id": 4,
"name": "Right ESC Status",
"type": "uint8_t"
},
{
"id": 5,
"name": "Right ESC Temperature",
"type": "float"
},
{
"id": 6,
"name": "Right ESC Current",
"type": "float"
},
{
"id": 7,
"name": "Wheel Ticks",
"type": "uint32_t[2]"
}
],
"registers": [
{
"id": 0,
"name": "Wheel Ticks Per Meter",
"type": "double"
},
{
"id": 1,
"name": "Wheel Distance",
"type": "double"
}
],
"type": "DiffDriveService",
"version": 1
}
24 changes: 24 additions & 0 deletions services/docking_sensor_service.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
{
"inputs": [],
"outputs": [
{
"id": 0,
"name": "Detected Sensors Left",
"type": "uint8_t"
},
{
"id": 1,
"name": "Detected Sensors Right",
"type": "uint8_t"
}
],
"registers": [
{
"id": 0,
"name": "Sensor Timeout Ms",
"type": "uint32_t"
}
],
"type": "DockingSensorService",
"version": 1
}
29 changes: 29 additions & 0 deletions services/emergency_service.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
{
"inputs": [
{
"id": 0,
"name": "Set Emergency",
"type": "uint8_t"
}
],
"outputs": [
{
"id": 0,
"name": "Emergency Active",
"type": "uint8_t"
},
{
"id": 1,
"name": "Emergency Latch",
"type": "uint8_t"
},
{
"id": 2,
"name": "Emergency Reason",
"type": "char[255]"
}
],
"registers": [],
"type": "EmergencyService",
"version": 1
}
13 changes: 13 additions & 0 deletions services/imu_service.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"inputs": [],
"outputs": [
{
"id": 0,
"name": "Axes",
"type": "double[9]"
}
],
"registers": [],
"type": "ImuService",
"version": 1
}
53 changes: 53 additions & 0 deletions services/lidar_service.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
{
"type": "LidarService",
"version": 1,
"inputs": [],
"outputs": [
{
"id": 0,
"name": "AngleMinRad",
"type": "double"
},
{
"id": 1,
"name": "AngleMaxRad",
"type": "double"
},
{
"id": 2,
"name": "TimeIncrementSeconds",
"type": "float"
},
{
"id": 3,
"name": "ScanTimeSeconds",
"type": "float"
},
{
"id": 4,
"name": "RangeMinM",
"type": "float"
},
{
"id": 5,
"name": "RangeMaxM",
"type": "float"
},
{
"id": 6,
"name": "Ranges",
"type": "float[100]"
},
{
"id": 7,
"name": "Intensities",
"type": "float[100]"
},
{
"id": 8,
"name": "NewScan",
"type": "uint8_t"
}
],
"registers": []
}
49 changes: 49 additions & 0 deletions services/mower_service.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
{
"inputs": [
{
"id": 0,
"name": "MowerEnabled",
"type": "uint8_t"
}
],
"outputs": [
{
"id": 0,
"name": "Mower Status",
"type": "uint8_t"
},
{
"id": 1,
"name": "Rain Detected",
"type": "uint8_t"
},
{
"id": 2,
"name": "Mower Running",
"type": "uint8_t"
},
{
"id": 3,
"name": "Mower ESC Temperature",
"type": "float"
},
{
"id": 4,
"name": "Mower Motor Temperature",
"type": "float"
},
{
"id": 5,
"name": "Mower Motor Current",
"type": "float"
},
{
"id": 6,
"name": "Mower Motor RPM",
"type": "float"
}
],
"registers": [],
"type": "MowerService",
"version": 1
}
60 changes: 60 additions & 0 deletions services/mower_ui_service.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
{
"inputs": [
{
"id": 0,
"name": "State ID",
"type": "uint8_t"
},
{
"id": 1,
"name": "State Name",
"type": "char[100]"
},
{
"id": 2,
"name": "Gps Quality",
"type": "float"
},
{
"id": 3,
"name": "Battery Percent",
"type": "float"
}
],
"outputs": [
{
"id": 8,
"name": "Left ESC Temperature",
"type": "uint8_t"
},
{
"id": 9,
"name": "Right ESC Temperature",
"type": "uint8_t"
},
{
"id": 10,
"name": "Mow ESC Temperature",
"type": "uint8_t"
},
{
"id": 11,
"name": "Mow Motor Temperature",
"type": "uint8_t"
}
],
"registers": [
{
"id": 0,
"name": "Wheel Ticks Per Meter",
"type": "double"
},
{
"id": 1,
"name": "Wheel Distance",
"type": "double"
}
],
"type": "MowerUiService",
"version": 1
}
Loading
Loading