Skip to content

Ignore disabled serial backends when reporting a connection - #3717

Open
Amoulier wants to merge 1 commit into
meshcore-dev:devfrom
Amoulier:fix/disabled-serial-connection
Open

Amoulier wants to merge 1 commit into
meshcore-dev:devfrom
Amoulier:fix/disabled-serial-connection

Conversation

@Amoulier

Copy link
Copy Markdown

A registered serial backend can remain physically connected after it is logically disabled. MultiSerialInterface::isConnected() currently counts that stale connection, although its receive/write/busy paths already exclude disabled interfaces. Require an enabled backend before reporting a connection.

Regression coverage checks a disabled Bluetooth backend, another enabled transport remaining connected, re-enabling Bluetooth, and disabling/removing interfaces. Three checks fail on the unmodified dev implementation and all four pass with this change.

Validation:

  • pio test -e native --filter test_multi_serial_interface: 4/4 passed.
  • pio test -e native -e native_kiss_modem: 62/62 passed.
  • pio run -e muzi_base_uno_superIO_companion_radio_ble: passed.
  • git diff --check: passed.

The tests use a backend whose physical connection flag deliberately remains set across disable(). No protocol or interface-selection behavior changes.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant