TARS robot control library with daemon, dashboard, and SDK
Project description
TARS
โ ๏ธ Note to Visitors
This repository is a personal fork for experimenting with a new distributed architecture. If you're looking for the main TARS-AI project, please visit:
๐ https://github.com/TARS-AI-Community/TARS-AI
This fork splits TARS into a dual-machine setup:
- Host Computer (macOS/Windows/Linux): Handles all AI processing (STT, TTS, LLM, Vision)
- Raspberry Pi 5: Handles all hardware I/O (servos, camera, audio)
Architecture Overview
New Architecture: RPi is self-contained and runs a WebRTC server + gRPC server. The host computer connects to it as a client.
RPi 5 (tars) - Standalone Robot Host Computer (tars-conversation-app) - AI Brain
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ WEBRTC + gRPC SERVERS โ โ WEBRTC CLIENT + AI โ
โ โ โ โ
โ tars_daemon.py โ โ tars_bot.py โ
โ โ โ โ
โ On boot: โ โ Connects to RPi: โ
โ - Starts WebRTC server โ WebRTC โ - aiortc client โ
โ - Starts gRPC server โโโโโโโโโโค - POST /api/offer โ
โ - POST /api/offer endpoint โ P2P โ โ
โ โ โ Audio Pipeline: โ
โ Audio Routing: โ โ โโโโโโโโโโโโโโโโโโโโโโโ โ
โ - Mic โ WebRTC track โโโโโโโโโผโโโโโโโโโผโบโ VAD โ STT โ LLM โ โ
โ - WebRTC track โ Speaker โโโโโผโโโโโโโโโผโโค โ TTS โ Audio Out โ โ
โ โ โ โโโโโโโโโโโโโโโโโโโโโโโ โ
โ DataChannel State Sync: โ โ โ
โ - Receives eye states โ โ Services: โ
โ - Sends battery status โ โ - Deepgram STT โ
โ โ โ - GPT LLM + Tools โ
โ gRPC API (port 50051): โ โ - ElevenLabs TTS โ
โ - Move(movement, speed) โโโโโโโโโโค - Vision (tool calls) โ
โ - CaptureCamera(w, h, q) โ gRPC โ โ
โ - SetEmotion(emotion) โ โ Tools call RPi via gRPC โ
โ - SetEyeState(state) โ โ โ
โ - GetStatus() โ โ โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ
โ I2C + USB + CSI
โผ
โโโโโโโโโโโโโโโโโโโโ
โ Hardware โ
โ - Servos โ
โ - USB Soundcard โ
โ - Pi Camera โ
โ - Display โ
โ - Battery โ
โโโโโโโโโโโโโโโโโโโโ
Key Principle: The robot is self-contained. It boots up and waits for an AI brain to connect, not the other way around.
๐ฆ Installation
SDK Only (App Development)
For controlling TARS from your computer (Mac/Windows/Linux):
pip install tars-robot
This installs only the lightweight SDK (~3 dependencies) needed to connect to the robot via gRPC.
Full Daemon (Raspberry Pi)
For running the robot daemon on the Pi:
pip install tars-robot[daemon]
This installs all dependencies including FastAPI, pygame, Adafruit libraries, etc.
๐ Full Installation Guide - Detailed instructions, usage examples, and troubleshooting
What This Repo Contains
- gRPC-based control system for Raspberry Pi 5 (low-latency hardware control)
- WebRTC server for bidirectional audio streaming
- 19 pre-programmed movements for servo control
- Camera capture via gRPC (Pi Camera or USB webcam)
- Real-time state synchronization via WebRTC DataChannel
Quick Start
Web Dashboard
First Boot WiFi Setup:
On first boot, TARS starts a WiFi hotspot:
SSID: TARS-Setup
Password: tars1234
Setup URL: http://10.42.0.1:8080/setup
After WiFi is configured, access the dashboard at:
# Local network (home WiFi)
http://tars.local:8080
# Tailscale (dorm/corporate networks)
http://100.x.x.x:8080
๐ WiFi Setup Guide - Complete WiFi configuration instructions
Dashboard Features:
- Monitor robot status (battery, CPU, network)
- Control movements via joystick
- Install and manage apps from the App Store
- Configure WiFi and system settings
Tabs:
- Status: System metrics, battery, connections
- Control: Movement controls with joystick interface
- Apps: Official and community apps marketplace
- Settings: WiFi management, enterprise WiFi support, updates
Command Line
Start the RPi daemon (waits for AI brain to connect):
# Start WebRTC + gRPC servers (default)
python tars_daemon.py
# Or using start script
./start.sh
# WebRTC only (no gRPC)
python tars_daemon.py --no-grpc
# Specify custom gRPC port
python tars_daemon.py --grpc-port 50052
The RPi will:
- Start the WebRTC server on port 8001
- Start the gRPC server on port 50051 (default)
- Start the web dashboard on port 8080
- Wait for the host computer to connect via POST /api/offer
- Once connected, audio flows bidirectionally and gRPC handles hardware control
Documentation
User Guides:
- DAEMON.md - Getting started with unified daemon
- DASHBOARD.md - Web dashboard guide
- WIFI_SETUP.md - WiFi configuration and troubleshooting
API Reference:
- MOVEMENTS.md - Servo control and movement API
- HARDWARE_IO.md - Camera and audio API
Architecture & Design:
- ARCHITECTURE.md - System architecture
๐ค Contributing
- Join the community on Discord:
๐ https://discord.gg/AmE2Gv9EUt
๐ License
This project is licensed under Creative Commons Attribution-NonCommercial 4.0 International (CC-BY-NC 4.0).
You may:
- Build and modify your own TARS robot
- Share improvements and derivatives
- Use the project for personal, educational, and research purposes
You may not use this project for commercial purposes without explicit permission from the authors. Commercial use includes, but is not limited to:
- Selling 3D printed parts, kits, or complete robots
- Selling or distributing STL / CAD files for money
- Offering paid assembly, customization, or installation services
- Monetized YouTube, Social Media, Patreon, or subscription content that distributes project files or derivatives
- Using this project in paid products, commercial research, or corporate projects
- Integrating this project into commercial software or hardware products
- Selling derivatives or modified versions of the hardware or software
If you are unsure whether your use case is commercial, assume it is and request permission from the authors.
See the LICENSE file for details.
๐งพ Attribution
Please follow the attribution guidelines when sharing or publishing derivative work:
๐ ATTRIBUTION.md
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file tars_robot-0.4.2.tar.gz.
File metadata
- Download URL: tars_robot-0.4.2.tar.gz
- Upload date:
- Size: 27.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
83de17574048e6f64d569a13f896a3d3a8f51505f8f70ab4afec8d65ab588414
|
|
| MD5 |
0a2add8ed23f92fa23bdeec73395b47d
|
|
| BLAKE2b-256 |
d573b5dfd4cd5b131c401ea30f566e8ab464f80b5539e8eb391a679956b93d39
|
File details
Details for the file tars_robot-0.4.2-py3-none-any.whl.
File metadata
- Download URL: tars_robot-0.4.2-py3-none-any.whl
- Upload date:
- Size: 23.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f1cc6748f8fa7511c72b7d0d2f6511fee918290768099cde2edfb765f8d0a01f
|
|
| MD5 |
e3c6c20ce458b096c80db39543dae2d7
|
|
| BLAKE2b-256 |
8db6485982e1c59d18361fe2d50234fc26f5ec366c3b7170aebe2d345a2a2af2
|