Skip to main content
raccoon-cli

raccoon-cli

The dev toolchain for RaccoonOS — scaffold, configure, sync, and run Botball robots.

License: GPL v3 Python Build & Release Latest Release PyPI

📖 Full documentation at raccoon-docs.pages.dev


raccoon is the command-line companion to raccoon-lib. It handles everything outside the robot code itself: generating hardware boilerplate from a YAML config, syncing files to the Pi, and running your missions remotely.


Installation

pip install raccoon-cli

How it works

raccoon uses a client-server architecture. Your laptop runs the CLI; the Pi runs a small FastAPI daemon (raccoon-server) that receives commands, manages execution, and streams logs back.

Pi setup (one time)

# On the Pi -- install raccoon-server as a systemd service
sudo raccoon-server install

After that, the server starts automatically on boot and raccoon connect can reach it.


Commands

Missions

Projects are git repos created with the setup script of raccoon-template (see Getting Started); run raccoon from inside the project.

Command Description
raccoon mission create <[Mxxx]name>... Add one or more missions; the number is optional (auto: M010, M020, ... M990), e.g. Drive M500Wave (M000/M999 are reserved)
raccoon mission list List the project's missions
raccoon mission rename <name|Mxxx> <new-name> Rename a mission (file, class and references; the M-number is kept)
raccoon mission remove <name|Mxxx>... [--keep-file] Remove one or more missions
raccoon mission reorder [order...] Reorder missions (interactive without arguments) and renumber them

Hardware & code generation

Command Description
raccoon codegen Regenerate src/hardware/defs.py and src/hardware/robot.py from config
raccoon calibrate ticks Measure encoder ticks per revolution
raccoon calibrate autotune Run motor autotune
raccoon calibrate servos Interactively calibrate servo offsets
raccoon calibrate step-response Record a motor step response
raccoon validate Check config, files and imports for consistency
raccoon migrate Apply numbered project migrations

Remote development

Command Description
raccoon connect <address> Connect to a Pi server
raccoon disconnect Disconnect from the current Pi
raccoon status Show connection status
raccoon sync Sync changed files to the Pi (uses content hashing)
raccoon sync --force Re-upload all files
raccoon run Regenerate code, sync, and run on the Pi
raccoon upload Full preflight, then push to the robot and confirm it starts
raccoon shell Open an SSH session on the connected Pi
raccoon doctor Health check of tools, connection and versions

Debugging

Command Description
raccoon logs show / tail / download / clear Read, follow, download or clear the robot's logs (raccoon logs sources lists them)
raccoon checkpoint list / show List saved checkpoints or show one
raccoon checkpoint restore <id> Restore project to a checkpoint
raccoon checkpoint delete / clean Delete one checkpoint or clean up old ones

Tooling

Command Description
raccoon update Update raccoon-cli to the latest version
raccoon web Launch the web IDE

Project structure

A new project contains:

MyRobot/
├── raccoon.project.yml    # Hardware config -- motors, sensors, drivetrain, connection
├── src/
│   ├── main.py
│   ├── hardware/
│   │   ├── defs.py        # Generated -- do not edit by hand
│   │   └── robot.py       # Generated -- do not edit by hand
│   ├── missions/
│   │   ├── setup_mission.py
│   │   └── shutdown_mission.py
│   └── steps/
└── .raccoonignore         # match patterns excluded from sync

defs.py and robot.py are regenerated by raccoon codegen (and automatically on every raccoon run). Edit raccoon.project.yml to change the hardware config - never edit the generated files directly.


Configuration

A project uses a split config layout. The root file just glues things together:

raccoon.project.yml

name: MyRobot
uuid: <auto-generated>

robot:       !include 'config/robot.yml'
missions:    !include 'config/missions.yml'
definitions: !include 'config/hardware.yml'
connection:  !include 'config/connection.yml'

config/hardware.yml -- sensors, motors, servos

button:
  type: DigitalSensor
  port: 10
imu:
  type: IMU
front_left_ir_sensor:
  type: IRSensor
  port: 1
front_right_ir_sensor:
  type: IRSensor
  port: 2

_motors: !include-merge 'motors.yml'
_servos: !include-merge 'servos.yml'

config/motors.yml

left_motor:
  type: Motor
  port: 0
  inverted: false
  calibration:
    ticks_to_rad: 0.00002   # set by raccoon calibrate
    vel_lpf_alpha: 1.0
    # Optional: omit pid to use STM32 firmware defaults
    # pid: {kp: 1.22, ki: 0.045, kd: 0.0}
right_motor:
  type: Motor
  port: 1
  inverted: true
  calibration:
    ticks_to_rad: 0.00002
    vel_lpf_alpha: 1.0

config/connection.yml

pi_address: 192.168.4.1
pi_port: 8421
pi_user: pi
auto_connect: true

~/.raccoon/config.yml (global)

known_pis:
  - hostname: raccoon-pi
    address: 192.168.4.1
default_pi_user: pi

Contributing

See CONTRIBUTING.md for how to get started contributing

License

Copyright (C) 2026 Tobias Madlberger
Licensed under the GNU General Public License v3.0 -- see COPYING for details.

Metadata

Release files for raccoon-cli 187

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distribution (wheel)

Table of built distributions (wheels) for raccoon-cli 187
File Interpreter ABI Platform Actions
raccoon_cli-187-py3-none-any.whl Python 3 none any Details for raccoon_cli-187-py3-none-any.whl

Release files / raccoon_cli-187-py3-none-any.whl

Download URL raccoon_cli-187-py3-none-any.whl
Size 2.0 MB
Tags Python 3
SHA-256 checksum
How to use checksums
f3af0af720681f399384968c2ecfa03b66dc0dd7ad5ea1b8b19784dd3cc05f2c
BLAKE2b-256 checksum
How to use checksums
356ed4064bd96948acf4ca39d205f48d9b89e97a0e296262738dbfbc70baf576
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 21, 2026.

Transparency log

Security for raccoon-cli 187

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

1 file in this release has been uploaded with provenance metadata.

Attestation for raccoon_cli-187-py3-none-any.whl

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 21, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

187 This release

1 release file Full provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page