Skip to content

JoachimPerrin/implem

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Implementation Project

OS ROS 2 Build

Summary

Project Overview

This project is an advanced coursework aiming to control a 1-DoF robot equipped with an IMU sensor. The goal is to implement two mutually exclusive control modes on embedded hardware:

  1. Compass Mode (IMU driven): Velocity control to steadily point towards magnetic North.
  2. Ariane Mode (Camera driven): Force control to follow a visible line on the ground.

These modes are designed to work both in simulation (Gazebo) and on the physical hardware.

This project relies mainly on two packages: maquette_hardware targetting the embedded micro-controller, and maquette_control setting the upper logic on the remote machine. architecture_class

Once launched, this architecture provides a solid FSM style to switch between modes. sequence_switch

Another mode was implemented for PID tuning

And we made sure to allow quick imu calibration

Hardware

The platform is a custom 1-DoF robotic system relying on:

Software Stack

  • OS: Ubuntu 24.04 (Noble Numbat)
  • Middleware: ROS 2 Jazzy Jalisco
  • Control: ros2_control framework
  • Languages: C++17, Python 3.12

Prerequisites

Before installing the project, ensure you have the necessary tools.

System Dependencies

Optional Development Tools

To maintain code quality (formatting), we use clang-format and black. You can install them via apt:

sudo apt install clang-format python3-black

Note: These are optional but recommended if you plan to modify the code.


Installation

  1. Clone the repository:

    git clone git@gitlabsu.sorbonne-universite.fr:Joachim.Perrin/implem.git
    cd implem
  2. Install ROS dependencies:

    cd ros2_ws
    rosdep update
    rosdep install --from-path src --ignore-src -r -y

Usage

This project uses a Makefile to simplify common tasks.

1. Build Locally (Simulation/Dev)

To build the project for your current machine (x86/64):

make build-local

2. Build for Raspberry Pi (Cross-compilation)

To cross-compile the project inside Docker and deploy it to the Raspberry Pi:

  1. Build the builder image (only needed once):

    docker build -t rpi-builder docker
    Advanced: Fix permission issues

    If you encounter permission issues with the generated artifacts, build the image with your user ID:

    docker build --build-arg USER_UID=$(id -u) --build-arg USER_GID=$(id -g) -t rpi-builder docker
  2. Compile and Deploy: Replace <RASPBERRY_IP> with the actual IP of your robot.

    make build-rpi IP=<RASPBERRY_IP>

Development & Formatting

To ensure code consistency, please format the code before pushing changes. This will apply Google Style to C++ files and Black formatting to Python files.

make format

To clean all build artifacts (local and cross-compiled):

make clean

Package Documentation

Each package contains its own detailed documentation:

  • maquette_bringup: Launch files and configurations.
  • maquette_control: Control logic nodes.
  • maquette_description: URDF and simulation descriptions.
  • maquette_hardware: Hardware interface plugins.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors