Skip to content

sachinkum0009/edge-rtc

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

edge-rtc

This repo is for using WebRTC with ROS2

Build Status Main

Description

This project aims to integrate WebRTC capabilities into ROS2 applications, enabling real-time communication and data exchange. Specifically for video streaming and low latency application with Robotic Perception SOTA models.

Block Diagram

Block Diagram

Demo

webrtc-2025-10-17_17.56.52.mp4

Architecture

flowchart LR
  subgraph App["EdgeRTC App"]
    Main[main.py] --> Config[EdgeRTCConfig]
    Main --> Provider[ImageProvider async queue / per-topic]
    Main --> Adapter[RtcRos2Adapter rclpy thread]
    Main --> Server[RtcServer aiohttp + aiortc]
    Adapter -->|publishtopic, frame| Provider
    Server -->|HTTP /offer| PC[RTCPeerConnection]
    PC -->|addTrack ImageVideoTrack| Track[ImageVideoTrack]
    Track -->|await get_latesttopic| Provider
    Track -->|VideoFrame| PC
  end

  subgraph ROS2["ROS2"]
    Cameras[/camera topics/] -->|Image msgs| Adapter
  end

  subgraph Client["WebRTC Client / Browser"]
    Browser -->|POST /offer sdp, topic| Server
    Browser <-->|SDP answer + media| PC
  end

  Cameras --> Adapter
  Browser --> Server
Loading

Installation

virtualenv edgertc_env
source edgertc_env/bin/activate
pip install -r edge_rtc/requirements.txt

export PYTHONPATH=$PYTHONPATH:/<path_to_venv>/edgertc_env/lib/python3.*/site-packages

colcon build --symlink-install --packages-select edge_rtc
source install/setup.bash

ros2 launch edge_rtc webrtc_video_server.launch.py

ros2 launch edge_rtc webrtc_ros2_client.launch.py

References

About

This repo is for using WebRTC with ROS2

Topics

Resources

License

Stars

Watchers

Forks

Sponsor this project

  •  

Contributors

Languages