Files
alro65 deb04c9315 sprint-0: fundaciones VMS-Sailor
Sprint 0 completo del producto VMS-Sailor (Vessel Management System
integrado para buques 30-40m). Brief de referencia en
VMS_Sailor_v2_Parte_*.md (intacto).

Core (vmssailor.core, 95.17% coverage, 99 tests verde):
- ShipCoord: sistema naval x_pp/y_cl/z_bl frozen
- Vessel, Deck, Bulkhead
- Equipment, EquipmentModel, Sensor, EquipmentSpec
- Tag, AlarmConfig, TagBinding, Scaling
- CardInstance, Bus, Topology con validacion 21 puntos I/O AR-NMEA-IO-v1.0
- Alarm, PermissiveRule, Condition
- Project agregado raiz con validacion cross-entity
- Persistencia portable .vmsproj (SQLite) con roundtrip verificable

Biblioteca curada seed (vmssailor.library):
- systems_catalog.json completo (catalogo maestro Parte 1 sec 7)
- 2 vessels: Sunseeker 76, Ferretti 850
- 2 motores: MTU 12V 2000 M96, Volvo D13-900
- 1 genset: Northern Lights M65C13
- yacht_motor_planeo.yaml (reglas heuristicas)
- TODO marcado data_source=seed_estimate - requiere validacion datasheets

Tools:
- vms-validate-library: CLI valida biblioteca completa
- vms-generate-test-project: CLI demo + verificacion roundtrip persistencia

Design System + 8 mockups HTML estaticos:
- docs/design_system.md (paleta Deep Ocean, gradientes, typography, motion)
- docs/brand/ (logo + variantes SVG)
- docs/mockups/splash, studio_main, runtime_overview,
  runtime_mimic_fuel (P&ID animado), runtime_alarms, runtime_trim (panel
  estrella con horizonte artificial), mobile_overview, mobile_trim
- docs/mockups/index.html (galeria)

Firmware (Sprint 12+ implementacion):
- firmware/ar_nmea_io_v1/src/config/pinout.h con macros GPIO

Decisiones autonomas documentadas en docs/decisions_sprint0.md.

Stack: Python 3.11 + uv + Pydantic v2 + SQLite stdlib + hatchling +
pytest 9 + ruff + mypy. Sin PySide6, FastAPI, Flutter ni firmware
funcional (entran en sprints siguientes).

Criterio de aceptacion Sprint 0: cumplido.
- uv sync: OK
- pytest: 99/99 verde
- cov vmssailor.core: 95.17% (objetivo >=80%)
- ruff: clean
- vms-validate-library: OK
- vms-generate-test-project: INTEGRIDAD OK

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-17 07:26:06 -04:00

85 lines
5.3 KiB
Markdown
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# VMS-Sailor — Arquitectura (vista general)
> One-pager con links a las partes del brief. Para detalles ir a los
> documentos originales (`VMS_Sailor_v2_Parte_*.md`).
## Producto vertical completo
```
┌──────────────────────────┐
│ VMS-Sailor Studio │
│ (PC de Álvaro) │
│ │
│ · Biblioteca curada IP │
│ · Wizard 8 pasos │
│ · Editor mímicos/tags │
│ · Compilador .vmspack │
└─────────────┬────────────┘
│ .vmspack firmado
│ .vmsdelta firmado
┌─────────────────────────────────────────────────────────────┐
│ PC INDUSTRIAL DEL BUQUE │
│ │
│ ┌──────────────────────┐ ┌──────────────────────┐ │
│ │ Runtime servidor │ WS │ Runtime cliente │ │
│ │ · servicio Windows │ ◄────► │ desktop (PySide6) │ │
│ │ · drivers Modbus │ REST │ puente + máquinas │ │
│ │ · drivers NMEA 2000 │ └──────────────────────┘ │
│ │ · alarm engine │ │
│ │ · permissive engine │ ┌──────────────────────┐ │
│ │ · authority manager │ ◄────► │ VMS-Sailor Mobile │ │
│ │ · stability monitor │ WSS │ Flutter (WiFi local)│ │
│ │ · historian DuckDB │ └──────────────────────┘ │
│ └──────────┬───────────┘ │
└──────────────┼──────────────────────────────────────────────┘
│ Modbus RTU + NMEA 2000
┌──────────────┴──────────────────────────────────────────────┐
│ AR-NMEA-IO-v1.0 (×N tarjetas distribuidas) │
│ ESP32 + 10 DO + 5 DI + 1 RPM + 4 AI │
│ · plug-and-produce (config descargada del VMS) │
│ · OTA seguro firmado │
│ · alarmas y permissives locales críticos │
└──────────────┬──────────────────────────────────────────────┘
│ I/O físico
┌──────────┐ ┌──────────┐ ┌──────────┐
│ Motores │ │ Genset │ │ Tanques, │
│ MTU/Volvo│ │ │ │ bombas...│
└──────────┘ └──────────┘ └──────────┘
```
## Productos relacionados
- **AR-ECDIS** (producto separado, no se desarrolla aquí). Publica al
backbone NMEA 2000 los PGNs de navegación y actitud que VMS-Sailor
consume: 127250 Heading, 127251 ROT, 127257 Attitude, 129025/129029
Position, 129026 COG/SOG, 128259 Speed Water.
## Componentes por sprint
| Sprint | Foco | Componente |
|---|---|---|
| 0 | Fundaciones | core + persistencia + biblioteca seed + design system |
| 1-3 | Studio | wizard + editores + biblioteca completa |
| 4-5 | Runtime servidor | drivers + tag store + historian + alarm engine |
| 6 | Runtime cliente | desktop completo |
| 7 | Empaquetado | compilador + MSI + activación HWID |
| 8 | Seguridad operativa | permissives + authority + stability monitor |
| 9-10 | Capas + telemetría | layer config engine + VPN + audit |
| 11 | Mobile | Flutter completo |
| 12-15 | Firmware | Modbus + NMEA 2000 + OTA + hardening |
| 16+ | Refinamiento | logbook regulatorio, integraciones Seakeeper, etc. |
## Reglas de oro (recordatorio)
Ver `VMS_Sailor_v2_Parte_06_Sprints_y_reglas.md` sección 5. Las críticas:
1. Tests obligatorios en `core` y `runtime/server`
2. Sin red de salida en Runtime (salvo activación + VPN admin)
3. Auditoría siempre activa
4. Coordenadas navales `ShipCoord(x_pp, y_cl, z_bl)` siempre
5. Unidades SI internas siempre
6. Idioma español por defecto
7. Runtime inmutable para el cliente (solo deltas firmados)