open-fpv-sim
The Python client of Open FPV Sim, an open-source FPV drone simulator that runs real Betaflight (SITL) against physics, electrical, sensor, radio and video models.
pip install open-fpv-sim[log,rerun]
The package is the client (import ofs). It drives an ofs-sim server, which you build from the repository
(cargo build -p ofs-sim) and point at with OFS_SIM_BIN; flying real Betaflight also needs the SITL build
described in the repository's docs/dev-setup.md. Build the server from the tag that matches this package version
(git checkout v<version>, the version pip show open-fpv-sim prints): a client and a server of different releases
speak different protocols and are refused at the handshake.
import ofs
sim = ofs.launch(headless=True)
sim.load("quads/opendrone-5f-freestyle.toml", world="flat", seed=42, mode="lockstep")
sim.inject(ofs.faults.MotorFailure(motor=2, at=3.0))
sim.play_inputs("flips.csv")
sim.run(seconds=10)
df = sim.log.to_dataframe(["imu.gyro_frd_radps", "motor.*.omega_radps", "battery.voltage_v"])
If a session fails (a Betaflight crash, a non-finite value), the server writes a repro bundle, and the sim_error
event names it. ofs.repro.find_bundles(sim.logs_dir) lists the bundles and ofs.repro.replay_bundle(path) runs one
again and says whether the failure came back (docs/repro-bundle.md in the repository).
A world with [[gates]] has a race: sim.get_world().gates lists them, sim.run(...).race is the lap clock
(present, running, next_gate, laps, current_lap_s, last_lap_s, best_lap_s) and the gate_passed and
lap_completed events carry the splits and lap times (docs/race-timing.md in the repository).
To fly a path from a script without Betaflight, load with open_loop_fc=True, stabilize=True: a minimal angle-mode
stabilizer (a test stand-in, not Betaflight) so the sticks set the lean and the turn rate. python/examples/circuit.py
flies a lap through four gates this way, and on Betaflight SITL too (docs/scripted-flight.md in the repository).
Extras: log reads the session recordings (mcap, pandas; Parquet export also needs pyarrow), rerun adds the
live view (ofs.rerun.view(sim)).
Metadata
Release files for open-fpv-sim 0.2.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| open_fpv_sim-0.2.0.tar.gz | 60.9 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| open_fpv_sim-0.2.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 97.7 kB
Release files / open_fpv_sim-0.2.0.tar.gz
| Download URL | open_fpv_sim-0.2.0.tar.gz |
|---|---|
| Size | 60.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
35996668ca892baf76144e1e9f8fbeef418b026069b06630290b82ab9ce174b5
|
|
BLAKE2b-256 checksum How to use checksums |
a01d89eb058b420608c57c8c8d178581b1c02b0d823204dbdaee00513045a7d6
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
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 Oct 17, 2026.
Transparency logRelease files / open_fpv_sim-0.2.0-py3-none-any.whl
| Download URL | open_fpv_sim-0.2.0-py3-none-any.whl |
|---|---|
| Size | 36.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
6d21796e3fd1c2b0913cf5c245758e290a4c1fe4cead36fe4ce8571f5e8798e4
|
|
BLAKE2b-256 checksum How to use checksums |
a91af3b6b975769eb3024a133ee9c67c93ed0641c2f8408de3b958c200d4f196
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
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 Oct 17, 2026.
Transparency log