Skip to content

Separate WiFi update planning from WiFi flash execution #143

@tylerkron

Description

@tylerkron

Problem

UpdateWifiModuleAsync(...) currently combines two responsibilities:

  • decide whether the WiFi firmware is already current
  • execute the WiFi flashing flow

The built-in skip logic is driven implicitly by whether the passed device implements ILanChipInfoProvider.

In desktop integration, that coupling made the flow awkward:

  • desktop needed to do an explicit pre-check so it could surface clear UI/logging and add startup retries
  • but when it later called UpdateWifiModuleAsync(...), Core wanted to probe the WiFi version again because the device still implemented ILanChipInfoProvider
  • desktop had to work around that by using one device for the explicit check and a non-provider adapter for the actual flash path

Current desktop workaround

Desktop now performs the version decision itself, then intentionally routes the real flash through an adapter that does not expose ILanChipInfoProvider so Core will skip the internal duplicate probe.

That works, but it is an API-shape workaround.

Desired improvement

Core should separate WiFi update planning from WiFi update execution, or otherwise let callers opt out of the internal version probe when they have already made the decision.

Possible approaches:

  • expose a separate CheckWifiFirmwareStatusAsync(...)
  • add an UpdateWifiModuleAsync(..., skipVersionCheck: true) option
  • model the plan/decision and execution as distinct public operations

Acceptance criteria

  • callers can perform a single explicit version decision and then execute WiFi flashing without triggering a second hidden probe
  • Core remains the source of truth for version comparison logic
  • the API is clearer about whether it is making a decision, executing a flash, or both

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions