• Stars
    star
    254
  • Rank 160,241 (Top 4 %)
  • Language
    C
  • License
    Apache License 2.0
  • Created about 4 years ago
  • Updated about 1 month ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

micro-ROS ESP32 IDF component and sample code

banner banner

micro-ROS component for ESP-IDF

This component has been tested in ESP-IDF v4.3, v4.4, and v5.0 with ESP32, ESP32-S2, ESP32-S3 and ESP32-C3.

Dependencies

This component needs colcon and other Python 3 packages inside the IDF virtual environment in order to build micro-ROS packages:

. $IDF_PATH/export.sh
pip3 install catkin_pkg lark-parser empy colcon-common-extensions

Middlewares available

This package support the usage of micro-ROS on top of two different middlewares:

In order to select it, use idf.py menuconfig and go to micro-ROS Settings > micro-ROS middleware

Usage

You can clone this repo directly in the components folder of your project.

If you encounter issues during the build process, ensure that you are running in a clean shell environment without the ROS 2 setup script sourced.

Example

In order to test a int32_publisher example:

. $IDF_PATH/export.sh
cd examples/int32_publisher
# Set target board [esp32|esp32s2|esp32s3|esp32c3]
idf.py set-target esp32
idf.py menuconfig
# Set your micro-ROS configuration and WiFi credentials under micro-ROS Settings
idf.py build
idf.py flash
idf.py monitor

To clean and rebuild all the micro-ROS library:

idf.py clean-microros

Is possible to use a micro-ROS Agent just with this docker command:

# UDPv4 micro-ROS Agent
docker run -it --rm --net=host microros/micro-ros-agent:humble udp4 --port 8888 -v6

Build with docker container

It's possible to build this example application using preconfigured docker container. Execute this line to build an example app using docker container:

docker run -it --rm --user espidf --volume="/etc/timezone:/etc/timezone:ro" -v  $(pwd):/micro_ros_espidf_component -v  /dev:/dev --privileged --workdir /micro_ros_espidf_component microros/esp-idf-microros:latest /bin/bash  -c "cd examples/int32_publisher; idf.py menuconfig build flash monitor"

Dockerfile for this container is provided in the ./docker directory and available in dockerhub. This approach uses ESP-IDF v5.

Using serial transport

By default, micro-ROS component uses UDP transport, but is possible to enable UART transport or any other custom transport setting the colcon.meta like:

...
"rmw_microxrcedds": {
    "cmake-args": [
        ...
        "-DRMW_UXRCE_TRANSPORT=custom",
        ...
    ]
},
...

An example on how to implement this external transports is available in examples/int32_publisher_custom_transport.

Available ports are 0, 1 and 2 corresponding UART_NUM_0, UART_NUM_1 and UART_NUM_2.

Is possible to use a micro-ROS Agent just with this docker command:

# Serial micro-ROS Agent
docker run -it --rm -v /dev:/dev --privileged --net=host microros/micro-ros-agent:humble serial --dev [YOUR BOARD PORT] -v6

Purpose of the Project

This software is not ready for production use. It has neither been developed nor tested for a specific use case. However, the license conditions of the applicable Open Source licenses allow you to adapt the software to your needs. Before using it in a safety relevant setting, make sure that the software fulfills your requirements and adjust it according to any applicable safety standards, e.g., ISO 26262.

License

This repository is open-sourced under the Apache-2.0 license. See the LICENSE file for details.

For a list of other open-source components included in ROS 2 system_modes, see the file 3rd-party-licenses.txt.

Known Issues/Limitations

There are no known limitations.

More Repositories

1

micro_ros_arduino

micro-ROS library for Arduino
C
437
star
2

micro_ros_setup

Support macros for building micro-ROS-based firmware.
Shell
365
star
3

micro_ros_platformio

micro-ROS library for Platform.IO
Python
209
star
4

micro_ros_stm32cubemx_utils

A set of utilities for integrating micro-ROS in a STM32CubeMX project
C
163
star
5

micro-ROS.github.io

A platform for seamless integration of resource constrained devices in the ROS ecosystem.
SCSS
110
star
6

micro-ROS-Agent

ROS 2 package using Micro XRCE-DDS Agent.
C++
101
star
7

NuttX

Official micro-ROS RTOS
C
88
star
8

micro-ROS-demos

Sample code using rclc and rclcpp implementations.
C
84
star
9

freertos_apps

Sample applications for FreeRTOS + micro-ROS
C
81
star
10

micro_ros_zephyr_module

micro-ROS Zephyr module and sample code
C
54
star
11

docker

Docker-related material to setup, configure and develop with micro-ROS hardware.
Dockerfile
49
star
12

system_modes

System modes for ROS 2 and micro-ROS
C++
43
star
13

rmw_microxrcedds

RMW implementation using Micro XRCE-DDS middleware.
C
35
star
14

micro-ROS_moveit2_demo

Provides a demo of micro-ROS and MoveIt2 based on ST Disco L475 IOT01 board IMU sensors.
C++
22
star
15

zephyr_apps

Sample applications for Zephyr + micro-ROS
C
19
star
16

micro_ros_mbed

micro-ROS mbed sample code
Makefile
18
star
17

micro-ROS_crazyflie_demo

Provides a demo of micro-ROS based on a Crazyflie.
Python
18
star
18

micro-ROS_openmanipulator_demo

Provides a demo of micro-ROS based on ROBOTIS OpenManipulator, Olimex STM32 E407 and VL53L1X ToF sensor.
C++
14
star
19

micro-ROS_kobuki_demo

Provides a demo of micro-ROS based on a Kobuki and an Olimex STM32-E407 board.
Python
14
star
20

rmw_embeddedrtps

RMW implementation for EmbeddedRTPS middleware
C++
13
star
21

micro-ROS_sensors_demo

Provides a demo of micro-ROS based on ST Disco L475 IOT01 board.
Shell
12
star
22

micro_ros_nuttx_app

An standalone micro-ROS app for Nuttx
Makefile
11
star
23

nuttx_apps

C
10
star
24

micro_ros_azure_rtos_app

micro-ROS app for Azure RTOS
C
8
star
25

micro_ros_utilities

General utilities for easing the usage of micro-ROS on different platforms
C
8
star
26

micro_ros_diagnostics

Diagnostics framework for micro-ROS
C
8
star
27

micro-ROS-bridge_RPI

Shell
7
star
28

micro_ros_rtthread_component

Python
7
star
29

micro_ros_msgs

Collection of ROS 2 message definitions used throughout the implementation of micro-ROS, both in the agent and client endpoints.
CMake
6
star
30

micro_ros_renesas2estudio_component

A set of utilities for integrating micro-ROS in a Renesas e2 studio project
C
6
star
31

micro-ROS_warehouse_demo

Python
5
star
32

rosidl_typesupport_microxrcedds

Type support for Micro XRCE-DDS
EmberScript
4
star
33

micro_ros_renesas_testbench

micro-ROS hardware in the loop testing
C
4
star
34

micro_ros_tivac_launchpad_app

micro-ROS app for TI Tiva C Series TM4C123GXL LaunchPad
C
4
star
35

micro_ros_vitis_component

Shell
4
star
36

micro_ros_renesas_demos

Demo code for Renesas e2 studio
C
4
star
37

benchmarking

A sets a tools and framework to develop embedded system benchmarks
C
4
star
38

benchmarking_shadow-builder

Repositiory containing the shadow-builder benchmarking tool
C++
3
star
39

executor_testbench

Executor modul for rcl with customizable scheduling semantics
C
2
star
40

raspbian_apps

C
2
star
41

micro-ROS_thumper_demo

A 6 wheel mobile robot contraller over 6LoWPAN and micro-ROS
Shell
2
star
42

micro-ROS-rtt

Micro-ROS Round-Trip Tests
C++
1
star
43

benchmarking-results

Benchmarking results
HTML
1
star
44

micro-ROS_demobox_demo

The demo box is a portable suitcase demonstration, showing advantage of using micro-ROS over ROS2 by showing power measurement and bootup time.
Shell
1
star
45

.github

micro-ROS GitHub Organization-wide files
1
star