arche/ros2-rover
ROS 2 rover
A rover as ROS 2 nodes: a lidar driver, a planner that slows and stops before an obstacle, and the motors; a simulated world closes the loop, so the test plan runs in the simulator. The nodes are generated as rclcpp packages for colcon.
ros2robotroverlidarplannermotorscolconstarter
Partir de ce modèle
archec new my-project --template arche/ros2-roverUne copie devient votre projet, à vous de la modifier : ses fichiers dans un nouveau dossier, prêts pour archec build.
▶ Essayer Ouvrir dans le Playground { } Voir le code son modèle tourne dans votre navigateur, rien à installer
Paquet
| Type | modèle de projet |
|---|---|
| Version | 0.1.0 |
| Licence | Apache-2.0 |
| Contrôle export | none |
| Compatible avec | archec >=0.10 |
| Édition | 0.12 |
| Handlers | Python d’après son code |
| Site | https://github.com/arche-lang/arche-lang |
Modèle
| Systèmes | Robot |
|---|---|
| Composants | Lidar Planner Motors World |
| Exigences | 3 |
| Messages | 4 |
Code fourni
| Emplacement | Langage | Lignes |
|---|---|---|
main.arche · Lidar.on_raw.body | arche | 3 |
main.arche · Planner.on_obstacle.body | arche | 12 |
main.arche · Motors.on_cmd.body | arche | 1 |
main.arche · World.on_wheels.body | arche | 2 |
main.arche · World.main.body | arche | 6 |
tests/ros2_check.py | python | 135 |
Ce que c’est
Robot · ses parties et leurs liensROS 2 rover
A rover as ROS 2 nodes. The lidar driver checks each reading (0.1 to 12 m, or not valid), the planner drives toward what is ahead at 1.5 × (distance − 0.3 m), at most 0.5 m/s, and stops 0.3 m before it, and the motor driver turns the speed into the two wheel speeds. The world moves the rover by them and gives the lidar the distance left: 3 m to a wall at the start.
| | | |---|---| | Nodes | lidar, planner, motors (with --kind ros2, a process each on a Linux computer, packaging ros2) | | Plant | world (kind plant): simulated with the model, not a node | | Requirements | REQ-RV-STOP (stop no closer than 0.25 m, within 10 s), REQ-RV-SPEED, REQ-RV-BLIND (not valid: 0 m/s) | | Test plan | TP-RV: it stops, within the speed limit, blind it stops |
archec new my-robot --kind ros2 a project from it, its nodes in src/
archec test main.arche the test plan, in the simulator
python3 tests/ros2_check.py --static the ROS 2 package files, without ROS
python3 tests/ros2_check.py with ROS 2 and the workspace built: the nodes, live
In the simulator the rover stops 0.32 m from the wall at 6.6 s.
Fichiers 4 · 12,5 Ko
archec add le vérifie.
Utilise
N’utilise aucun autre paquet.
Utilisé par
Aucun paquet du store ne l’utilise encore.
Versions
★ 0 étoile↓ 0 téléchargement
| Version | Publiée le | archec | État | Changements | Téléchargements |
|---|---|---|---|---|---|
0.1.0 | 12 nov. 2026 | >=0.10 | publique | 0 |
Signature
Signé par arche avec la clé e660d0a8851875b9. Fichiers : 4, empreinte sha256-1c9f34a1188ffda99af6…. archec add vérifie les deux avant d’écrire quoi que ce soit.
Discussion
Chargement…