Metadata-Version: 2.4
Name: opensvf
Version: 1.4.0
Summary: Open-source spacecraft software validation facility  -  SIL campaigns, physics-in-the-loop, HTML reports
License: Apache-2.0
Project-URL: Homepage, https://github.com/lipofefeyt/opensvf
Project-URL: Documentation, https://opensvf.readthedocs.io
Project-URL: Repository, https://github.com/lipofefeyt/opensvf
Requires-Python: >=3.10
Description-Content-Type: text/markdown
License-File: LICENSE
License-File: NOTICE
Requires-Dist: fmpy>=0.3.20
Requires-Dist: requests>=2.31
Requires-Dist: pythonfmu>=0.6
Requires-Dist: cyclonedds>=0.11
Requires-Dist: pyyaml>=6.0
Requires-Dist: pytest-timeout>=2.3
Requires-Dist: jinja2>=3.1
Provides-Extra: orbital
Requires-Dist: sgp4>=2.21; extra == "orbital"
Provides-Extra: uart
Requires-Dist: pyserial>=3.5; extra == "uart"
Provides-Extra: dev
Requires-Dist: pytest>=7.4; extra == "dev"
Requires-Dist: pytest-xdist; extra == "dev"
Requires-Dist: mypy>=1.8; extra == "dev"
Requires-Dist: types-PyYAML>=6.0; extra == "dev"
Requires-Dist: pyserial>=3.5; extra == "dev"
Dynamic: license-file

# OpenSVF

**Open-source spacecraft Software Validation Facility**

OpenSVF validates spacecraft flight software before hardware integration.
It runs the flight software binary in closed loop with equipment models, an
orbit and 6-DOF dynamics, sends it telecommands and decodes its telemetry.
Test procedures are written in Python; a campaign turns them into an HTML
report with a requirement traceability matrix. YAMCS can be attached as the
ground station.

**Documentation: [opensvf.readthedocs.io](https://opensvf.readthedocs.io/)**.
The flight software it is tested with, openobsw, is documented at
[openobsw.readthedocs.io](https://openobsw.readthedocs.io/).

```text
 Flight software binary (openobsw, or yours)
        |  wire protocol: stdin/stdout, or TCP to Renode
 OpenSVF (Python)
   OBC models         stub, pipe, socket
   Equipment models   AOCS sensors and actuators, EPS, thermal, TT&C
   Dynamics           opensvf-kde 6-DOF FMU, SGP4 orbit, B-field
   Bus adapters       MIL-STD-1553B, SpaceWire, CAN 2.0B
   PUS TM/TC stack    ECSS-E-ST-70-41C
   Campaign runner    procedure -> verdict -> HTML report
        |  PUS TM/TC (optional)
 YAMCS 5.12.6
```

## Compatibility

| Package | Version | Notes |
|---|---|---|
| opensvf | v1.4.0 | Python 3.10+, CI on 3.12 |
| openobsw | v0.20 (pinned in `.openobsw-version`) | C11, wire protocol v4 |
| opensvf-kde | v0.1.0+ (SGP4 + RK4 build, Aug 2026) | C++ / Eigen3 |
| YAMCS | 5.12.6 | Java 21+ |

The [compatibility](https://opensvf.readthedocs.io/en/latest/compatibility/)
page has the history; `checkcons` keeps this table, that page and the pin in
step.

## Quick start

The reference mission, MySat-1, runs without a flight software binary:

```bash
git clone https://github.com/lipofefeyt/opensvf
cd opensvf
pip install .
svf campaign mission_mysat1/campaigns/quickstart_campaign.yaml --report
```

Four procedures PASS and the report (`results/quickstart_campaign_report.html`)
lists the four requirements the campaign declares but does not cover; the
[quickstart](https://opensvf.readthedocs.io/en/latest/quickstart-mysat1/)
explains both. `pip install opensvf` installs the library and the `svf`
command without the mission files.

To run your own flight software, see
[Integrate your flight software](https://opensvf.readthedocs.io/en/latest/integrate-obsw/).

## Where to read next

| Page | For |
|---|---|
| [Architecture](https://opensvf.readthedocs.io/en/latest/architecture/) | The components, the closed loop, entry points, checks |
| [OBC modes](https://opensvf.readthedocs.io/en/latest/obc-modes/) | Stub, pipe and socket, and what a PASS shows in each |
| [Interfaces (ICD)](https://opensvf.readthedocs.io/en/latest/icd/) | Wire protocol, FMI, YAMCS and SRDB interfaces |
| [Validation](https://opensvf.readthedocs.io/en/latest/validation/) | Test levels, traceability, campaigns |
| [Known limits](https://opensvf.readthedocs.io/en/latest/known-limits/) | What this version does not do |
| [Releases](https://opensvf.readthedocs.io/en/latest/releases/) | Release notes, changelog, data pack PDFs |

## Development

```bash
pip install -e ".[dev,orbital]"
source scripts/activate.sh        # dev aliases (regen-xtce, yamcs-start, ...)

checkosvf && testosvf && checkcov && checkcons    # before every pull request
bash scripts/build_obsw_sim.sh && pytest tests/system   # L3 against the pinned openobsw
python tools/gen_docs.py && mkdocs build --strict        # the site (pip install -r docs/requirements.txt)
```

[CONTRIBUTING.md](CONTRIBUTING.md) has the rules. The dev container
(`.devcontainer/`) mounts `openobsw` and `opensvf-kde` as sibling
workspaces under `/workspace/`.

## Related projects

| Project | What it is |
|---|---|
| [openobsw](https://github.com/lipofefeyt/openobsw) | C11 flight software: PUS stack, b-dot, ADCS PD, FDIR ([targets](https://openobsw.readthedocs.io/en/latest/targets/)) |
| [opensvf-kde](https://github.com/lipofefeyt/opensvf-kde) | C++ 6-DOF kinematics and dynamics engine (FMI 2.0 FMU) |

## Roadmap

### Done

| Milestone | Scope |
|---|---|
| M1-M18 | Core platform, FMI, DDS sync, PUS stack, equipment models |
| M19-M22 | Spacecraft YAML DSL, procedure API, HTML reporting, OBSW integration guide |
| M23 | Temporal assertions + equipment fault engine |
| M24-M25 | ZynqMP SIL (aarch64 QEMU + Renode socket); YAMCS TM/TC pipeline and XTCE MDB |
| M26 | EPS/AOCS/thermal native models + test pyramid restructure |
| M27-M28 | Dual-OBC topology; UART wire protocol transport |
| M29-M31 | OBT-format init file; CAN 2.0B + SpaceWire RMAP; fidelity levels + calibration curves |
| M32-M36 | `svf validate`, SRDB namespace lint, fidelity coverage, EquipmentTickError, INCONCLUSIVE verdict |
| M37-M40 | PUS S9, S11, S12, S19 |
| M41-M42 | Shared-memory sync for RT HIL; orbital environment (SGP4, eclipse, solar) |
| M43-M45 | FreeRTOS HIL support, validation and integration campaigns |
| M46-M47 | F3 sensor fidelity (Allan variance, I-V); S20 tunable AOCS gains + FDIR thresholds |
| M48-M49 | YAMCS end-to-end B-dot demo; closed-loop detumbling convergence |
| M50 | SMP-aligned model interface (ISmpModel, SmpEquipmentMixin, catalogue + checksmp) |
| M51-M52 | PUS S15 + S23; PUS S6 + S8, wire-compatible with openobsw |
| M63 | SMP lifecycle aligned with ECSS-E-ST-40-07C; SMP claims corrected |
| v1.2 | Aligned with openobsw v0.18; L3 in CI against a pinned release |
| M76-M77 | `svf console`; OBSW communication health in every campaign result |
| v1.3 | Recovery evidence with openobsw v0.19/v0.20 |
| M78 (v1.4) | Documentation site: versioned Read the Docs site with openobsw v0.20, generated reference pages, cross-repo sync checks, known limits, data pack PDFs in CI |

### Planned

Grouped into release trains. M53-M62 come from a 2026-07 gap analysis
against a real ESA EUCLID CDMU/AOCS/HGACL SVF validation campaign (see
`REQUIREMENTS.md` SVF-DEV-188 to 201). Dates assume one part-time
maintainer.

| Release | Theme | Milestones |
|---|---|---|
| v1.5 (Q2 2027) | Second reference mission | M65 QUBIK (LSF PocketQube) feasibility spike; M66 QUBIK mission pack; M67 SatNOGS telemetry replay + model-vs-flight report; M56 post-hoc analysis tools; M72 SimLogger structured logging; M69 published Docker image |
| v1.6 (Q3 2027) | Operations preparation | M70 SCOS-2000 MIB import/export (revives SVF-DEV-098); M64 PLUTO (ECSS-E-ST-70-32C) procedure subset; M58 live YAMCS dashboards; M71 pre-built YAMCS display pages; M53 PUS S2 + S14 |
| v1.7 (Q4 2027) | Verification depth | M57 FDIR supervisor; M73 FaultPlan fault scheduler; M74 FDIR validation campaign; M55 soak + worst-case harness; M54 bus utilisation + WCET; M61 wire protocol fault injection; M62 DiscreteLine hard-line model |
| v2.0 (2028) | Interoperability | M68 real SMP runtime bridge; M75 FMU export of SimulationMaster; M60 orbital environment into opensvf-kde; M59 multi-spacecraft |

The [changelog](CHANGELOG.md) lists what each release changed.

## License

Apache 2.0
