fix(easee_cloud): resume a phase flip only after a valid stop poll - #159
Draft
erikarenhill wants to merge 3 commits into
Draft
erikarenhill wants to merge 3 commits into
erikarenhill wants to merge 3 commits into
Conversation
Easee applies a new phaseMode only when the session restarts. The driver paused, wrote phaseMode and resumed inside one ev_set_current, about 0.3 s apart. The cloud queues commands, so the resume reached the charger before the contactor opened and the session kept its phase count. On an Easee Home with a Tesla, phaseMode=3 was written mid-session and the car drew 15 A on one phase for hours until the owner paused and resumed in the Easee app. Hold the auto-resume for 15 s after a flip pause. The host's following ev_set_current ticks resume once the delay has passed. An explicit ev_pause or ev_resume clears the delay. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01766Rey7C5yDqY8qnnc92SA Signed-off-by: Erik <758402+erikarenhill@users.noreply.github.com> Signed-off-by: Fredrik Ahlgren <fredrik@sourceful-labs.com>
resume_charging in the same command continues the session, so a 1Φ→3Φ flip never latches. Wait for a poll that shows charging has stopped instead of a fixed 15 s delay. Co-authored-by: Fredrik Ahlgren <fredrik@sourceful-labs.com> Signed-off-by: Fredrik Ahlgren <fredrik@sourceful-labs.com>
Signed-off-by: Fredrik Ahlgren <fredrik@sourceful-labs.com>
frahlg
force-pushed
the
fix/easee-phase-flip-resume-delay
branch
from
October 4, 2026 16:30
7628352 to
9d67fab
Compare
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
Easee applies a new
phaseModeonly when a session restarts. Since the 2026-05-30 fix, the driver handles a mid-session 1Φ↔3Φ flip with pause → writephaseMode→ resume, all inside oneev_set_current. On real hardware the resume arrived about 340 ms after the pause:The cloud queues commands, so the resume reached the charger before the contactor opened. The session went on at the old phase count. Core then offered about 15–16 A per phase on 3Φ, but the car drew a flat ~3.55 kW (15 A on one phase) for about 3.5 hours. Pausing and resuming manually in the Easee app moved it to 3Φ immediately, at about 9–11 kW.
A flip made while the car was idle worked the same morning, because the next session started on the new phase count.
Change
ev_set_currentoffer then resumes charging.ev_start,ev_pauseorev_resumeclears the wait after the command succeeds.easee_cloudfrom 1.3.6 to 1.3.7 and refresh the manifest hash and catalog.Tests
make test-driver ID=easee_cloud: 39 passed, 15 skipped on the Cursor head.make check: 4810 passed, 923 skipped on9d67fab, rebased onto currentmainafter the other driver PRs merged.Hardware
easee_cloud1.3.1, whosedriver_commandis identical to 1.3.6.🤖 Generated with Claude Code
https://claude.ai/code/session_01766Rey7C5yDqY8qnnc92SA