OCPP EV Charger Entegrasyonu
Zeus 2.0, OCPP 1.6J (production) ve OCPP 2.0.1 (yakında) charge point'leri için tam Central System (CSMS) görevi görür. İlk doğrulanmış charger: Beny BCP-AT2N-P (22 kW AC, Type-2 tethered, RFID, Wi-Fi/Ethernet/4G).
Mimari Bileşenler
+--------------------+ WSS / TLS +-----------------+
| OCPP Charger(s) | -----------------------> | nginx :443 |
| (Beny BCP-AT2N-P) | wss://host/ocpp/1.6/ | (TLS terminator)|
+--------------------+ {cpid} +--------+--------+
|
ws (Upgrade)
v
+----------------------------------------------------------------------+
| FastAPI Backend |
| |
| +-------------------+ +--------------------+ +-------------+ |
| | WS Server |--->| python-ocpp |--->| Service | |
| | /ocpp/1.6/{cpid} | | ZeusChargePoint16 | | Layer | |
| +---------+---------+ +---------+----------+ +------+------+ |
| | | | |
| v v v |
| +-------------------+ +--------------------+ +-------------+ |
| | Redis | | Command Dispatcher | | REST API | |
| | (registry + | | (multi-worker | | /api/ocpp/* | |
| | rate-limit + | | pub/sub) | | (22 endpoint)| |
| | idempotency) | +--------------------+ +------+------+ |
| +-------------------+ | |
| v |
| +-------------------+ +--------------------+ +-------------+ |
| | Celery Beat | | WS Event Broker |--->| Frontend | |
| | (4 task) | | /ws/telemetry | | (Next.js) | |
| +-------------------+ +--------------------+ +-------------+ |
| | |
| v |
| +-------------------------------+ |
| | PostgreSQL + TimescaleDB | |
| | (8 tablo, ocpp_meter_samples | |
| | hypertable) | |
| +-------------------------------+ |
+----------------------------------------------------------------------+
Faz Roadmap'i
| Faz | Durum | İçerik | PR |
|---|---|---|---|
| 1+2 | Tamamlandı | DB şema + WS server + protokol çekirdeği | #264 |
| 3 | Tamamlandı | REST API + business logic + provisioning | #265 |
| 4 | Tamamlandı | Real-time events + Celery jobs | #266 |
| 5 | Tamamlandı | Frontend MVP | #267 |
| 6 | Tamamlandı | Session geçmişi + raporlar + SLD + SmartCharging editor | #270 |
| 7 | Production-ready (canary onayı bekliyor) | Nginx + Docker Compose + observability + security audit + release gate | #272, #273 |
Hızlı Başlangıç
- Saha kurulum (teknisyen / üretici): Saha Entegrasyon Kılavuzu
- API kullanımı (backend / integrator): Faz 3 — REST API Design Contract
- Real-time (frontend / observability): Faz 4 — Events & Jobs
- Frontend MVP (UI / ürün): Faz 5 — Frontend MVP
- Advanced features (sessions/reports/SLD/SmartCharging): Faz 6 — Advanced Features
- Production deployment (nginx/observability/release gate): Faz 7 — Production Deployment
- Sürüm geçmişi: Changelog
Desteklenen Protokol Versiyonları
| Versiyon | Durum |
|---|---|
| OCPP 1.6J | Production — Faz 2 itibarıyla tam destek |
| OCPP 2.0.1 | Yakında — endpoint stub mevcut, handshake 1011 ile kapatılır |
Desteklenen Feature Profile'lar (OCPP 1.6J)
- Core — BootNotification, Heartbeat, StatusNotification, Authorize, StartTransaction, StopTransaction, MeterValues, DataTransfer
- FirmwareManagement — UpdateFirmware, FirmwareStatusNotification, GetDiagnostics, DiagnosticsStatusNotification
- LocalAuthList — GetLocalListVersion, SendLocalList
- Reservation — ReserveNow, CancelReservation
- SmartCharging — SetChargingProfile, ClearChargingProfile, GetCompositeSchedule
Multi-Tenant İzolasyon
OCPP entegrasyonu Zeus 2.0 multi-tenant kuralına (CLAUDE.md §4) tam uyumludur:
- Her charger
tenant_idile ilişkilendirilir. - REST endpoint'lerinde
current_user.tenant_idfilter zorunlu. - WS event broadcast'i tenant scope'unda yapılır.
- Cross-tenant probe enumeration'a karşı 404 (403 değil) döner.