20 Commits

Author SHA1 Message Date
Patrick Schurig
5bb6da0e9f [3b-iv] ETM_ARBITRATOR actif — iso-fonctionnalité prouvée (simulation + tests charging, diff décisions zéro écart)
- energyplugin/energyplugin.pri : décommente DEFINES += ETM_ARBITRATOR (flip actif)
- energyplugin/etm/energyarbitrator.cpp : ajoute qCDebug "Updating smart charging" en tête
  de update() — comparabilité des logs avec l'amont garantie
- AGENTS.md : 3b →  FAITE, chiffres de preuve, prochaine action 3c

Preuve iso-fonctionnalité :
- Simulation : 226 lignes décisions (Theoretically/Surplus/Current load) — diff = 0
- Tests charging : 57 lignes décisions — diff = 0 ; 46/46 PASS ref ET ETM
- [Arbitre] présents avec raisons françaises (idle, surplus PV, aWATTar, deadline)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-08 11:29:34 +02:00
Patrick Schurig
d8ebd65eba [upstream-fix] maxChargingCurrent uint→double + INCLUDEPATH energyplugin.pri + flip ETM vers pri
- tests/mocks/plugins/energymocks/integrationpluginenergymocks.json : maxChargingCurrent
  "type": "uint" → "type": "double" sur les 3 Thing classes (charger, chargerPhaseSwitching,
  simpleCharger) — nymea 1.15 a changé le type de l'interface evcharger.
- energyplugin/energyplugin.pri : INCLUDEPATH += $$PWD — rend energyplugin/ accessible
  aux consommateurs du .pri (simulation, tests) qui compilent les sources ETM.
- energyplugin/energyplugin.pro : le toggle ETM_ARBITRATOR déplacé dans energyplugin.pri
  (unique point de contrôle propagé à plugin ET simulation).
- tests/auto/simulation/experience/energyexperienceenergymock.cpp : même flip que
  energypluginnymea.cpp — instancie EnergyArbitrator si ETM_ARBITRATOR est défini.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-08 10:39:31 +02:00
Patrick Schurig
c3fedfe36b [3b] décision B + modèle sécurité (AGENTS + SAFETY.md) + Doxygen proxy/inactif
- AGENTS.md : nouvelle entrée "3b révisé — délégation EV à l'amont" (beta hybride
  assumée, ETM réel en 3c, transplantation EV en 3g) ; modèle sécurité L0-L4
  avec double déclenchement verifyOverloadProtection documenté (signal ligne 127 +
  appel cyclique ligne 313 SCM.cpp).
- docs/SAFETY.md : document normatif 5 couches + signalisation locale optionnelle ;
  Variante B confirmée pour le repli L2 (EV au minimum + notification nymea +
  risque 1,4 kW accepté) ; table défaillances/couches corrigée (L1 ne couvre pas
  compteur hors ligne).
- energyarbitrator.cpp update() : commentaire explicitant la correspondance exacte
  avec l'ordre SCM (1-4 parent, ETM entre 4 et 7, planSpot+planSurplus via getPlan).
- rulebasedscheduler.h : Doxygen getPlan() marqué "PROXY AMONT POUR L'EV (beta)".
- evadapter.h : Doxygen applyAction() marqué "Inactif jusqu'à 3g".

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-08 07:41:12 +02:00
Patrick Schurig
7d3fc6e5ea add adresse IP dans AGENTS.md 2026-06-08 07:23:55 +02:00
Patrick Schurig
08039a3542 [wip] état session — phases 0-3b, prochaine action 3b-iv, topologie remotes 2026-06-07 23:34:18 +02:00
Patrick Schurig
5f49e4ca3c [3b-wip] EnergyArbitrator + RuleBasedScheduler + EvAdapter (dispatch amont, ETM_ARBITRATOR désactivé)
- EnergyArbitrator : public SmartChargingManager — raison documentée dans AGENTS.md §DÉCISIONS DE DESIGN
- SmartChargingManager : protected slots + virtual update() + 3 accesseurs inline [ETM]
- RuleBasedScheduler::getPlan() wraps planSurplusCharging/planSpotMarketCharging, annote chaque action d'un reason français
- EvAdapter : ILoadAdapter concret pour evcharger — applyAction() implémenté, NON appelé en 3b (dispatch via adjustEvChargers() amont, iso-fonctionnel)
- ETM_ARBITRATOR : commenté dans .pro — ne s'active qu'après preuve iso-fonctionnelle (3b-iv)
- Doxygen \brief + invariants + contrats sur toutes les classes/méthodes publiques etm/ (DoD §5)
- plan.h : timeSlots (pas slots, mot-clé Qt) ; commentaire JSON sérialisation "slots" OPTIMIZER_PROTOCOL §6
- .clangd : flags de repli Qt/nymea pour clangd via symlink ~/Schreibtisch/
- compile_commands.json gitignore (chemins absolus locaux)
- Build : 0 erreurs, 0 warnings — libnymea_energypluginnymea.so 914 KB

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-07 23:16:49 +02:00
Patrick Schurig
9017a880ac [brief] AGENTS.md = version définitive (architecture+workflow), statut phases 0-3a, décision TARGET drop-in actée 2026-06-07 22:06:50 +02:00
Patrick Schurig
4ae1939f93 [3a] structs protocole + interfaces LoadAdapter/Scheduler (zéro comportement)
LoadAction (kind+funding+§6 fields), LoadDescriptor, SurplusContext (§5),
Plan/Slot, ILoadAdapter, IScheduler — noms de champs = OPTIMIZER_PROTOCOL.md.
energyplugin.pri inclut etm/etm.pri. Build Qt6 vert, aucun fichier upstream touché.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-07 22:02:18 +02:00
Patrick Schurig
f4d5b20297 [phase1] renommage .pro + métadonnées debian ETM (fork 1.13.0+etm1, TARGET et paquets inchangés)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-07 21:39:49 +02:00
Patrick Schurig
074fa71308 [brief] AGENTS.md définitif (arbitre+LoadAdapters), CLAUDE.md pointeur, protocole versionné 2026-06-07 21:32:12 +02:00
Patrick Schurig
39f8c7ae18 docs: integrate architecture SVG into README
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-06 09:43:41 +02:00
1de49a8e63 Téléverser les fichiers vers "/"
fonctional blocs
2026-06-06 09:37:48 +02:00
Patrick Schurig
a751a4ccb6 docs: replace upstream nymea README with ETM PowerSync README
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-06 09:34:51 +02:00
Patrick Schurig
b8e882616b docs: document internal data flow and EnergyManagerConfiguration in INTERFACE.md
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-06 09:13:04 +02:00
Patrick Schurig
2931d295bc docs: add INTERFACE.md with complete NymeaEnergy JSON-RPC API
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-06 09:13:04 +02:00
74c94161cd chore: add .gitignore for build artifacts 2026-06-06 09:13:04 +02:00
7588473a60 feat: add EcoWithMinCurrent + EcoMinWithTargetTime charging modes
- charginginfo.h: 2 new ChargingMode enum values
- smartchargingmanager.h: EcoMinChargingCurrent = 6A constant
- smartchargingmanager.cpp: 5 changes
  A: fallback EcoMinWithTargetTime → EcoWithMinCurrent (not Eco)
  B: EcoWithMinCurrent ignored in spot market without target
  C: EcoMinWithTargetTime treated as EcoWithTargetTime for deadline
  D: planSurplusCharging: target time check for EcoMin modes
  E: adjustEvChargers: floor at max(6A, minValue) when no surplus/spot/time
2026-04-05 08:12:47 +02:00
d76e7e61d5 fix: detect actual EV phase instead of hardcoding phase A
- evcharger.cpp: phases() now calls meteredPhases() instead of returning PhaseNone
- smartchargingmanager: add chargerPhaseKey() with 3-level fallback
  1. meteredPhases() when charger is active
  2. effectivePhases from last known state
  3. fallback 'A' + warning (previous behavior)
- Remove 4 FIXME comments on lines 394, 477, 517
2026-04-05 07:09:38 +02:00
a679e76286 chore: add CLAUDE.md agent context 2026-04-04 17:37:01 +02:00
b343650f9b initial commit 2026-01-11 11:09:23 +01:00