fix(#1132): keep the rotation SET gate as it was, pin the reconnect reset

Applies the Gemini review: the rotation gate change was outside this issue's scope, so rotation SET stays on supportsIndicators. Adds a test that a new radio's device-info drops the previous radio's advert tags.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
pull/1133/head
diffwireauto 3 weeks ago
parent 7f6df7be81
commit 024072f733

@ -1938,7 +1938,7 @@ class MeshCoreConnector extends ChangeNotifier {
'rotation SET',
DeviceUiSurface.rotation,
buildRotationSetFrame(degrees),
advertised: supportsDisplayRotation,
advertised: supportsIndicators,
);
}

@ -284,6 +284,20 @@ void main() {
expect(connector.supportsLedControl, isTrue);
});
test('the next radio does not inherit the previous radio\'s tags', () {
// Radio A: tags say LED only, bit clear.
connectWith(caps2: 0x01, tags: [offbandInfoTagLedControl]);
expect(connector.supportsDisplayControl, isFalse);
// Radio B predates the advert and sets the bit. Its device-info drops
// A's advert, so the bit answers both.
connector.handleFrameForTest(deviceInfo());
connector.handleFrameForTest(Uint8List.fromList(advertUnsupported()));
expect(connector.supportsDisplayControl, isTrue);
expect(connector.supportsLedControl, isTrue);
});
test('support is never probed: no display or LED GET is sent', () {
connectWith(
caps2: offbandCap2Indicators,

Loading…
Cancel
Save

Powered by TurnKey Linux.