Krolyxon
Commit dd7c4d8

Branches

Refs →

budctldd7c4d8

budctl set dual on|off (W5d)

This adds dual connection (switch 11), the last of the T310's
switches, to the writable list. It is read back at once.

Verified on the owner's T310 (W5d, 2026-10-27): on and off were acked,
the immediate read-back showed the change, and the laptop's link
stayed up. Only one host was connected during the test.

No new dependencies.
Author
krolyxon
Date
2026-10-27 17:32 +0530
Parent
52014a4
Commit
dd7c4d84f0e79d70f649e9ca7b96f334752b0599

+7 −6

3 files changed

  1. M crates/budctl-cli/src/main.rs +1 −1
  2. M crates/budctl-core/src/devices/realme_t310/mod.rs +3 −4
  3. M docs/protocol/realme_t310.md +3 −1
M crates/budctl-cli/src/main.rs View
@@ -48,7 +48,7 @@ enum Command {
4848 },
4949 /// Select an EQ preset (pure-raw, deep-bass, pure-vocals, pure-bass), then read it back.
5050 Eq { preset: String },
51− /// Turn an on/off setting on or off, then read it back. Switches: game, bass-boost, spatial (3D sound), wind.
51+ /// Turn an on/off setting on or off, then read it back. Switches: game, bass-boost, spatial (3D sound), wind, dual.
5252 Set {
5353 /// The switch's name, as `status --json` lists it.
5454 switch: String,
M crates/budctl-core/src/devices/realme_t310/mod.rs View
@@ -43,11 +43,12 @@ const READ_BACK_PAUSE: Duration = Duration::from_millis(300);
4343
4444 /// The switches budctl may write, each added after the previous one passed its hardware
4545 /// checkpoint (CLAUDE.md rule 4). Spec: realme_t310.md#switch-write
46−const WRITABLE_SWITCHES: [(&str, ReadBack); 4] = [
46+const WRITABLE_SWITCHES: [(&str, ReadBack); 5] = [
4747 ("game", GAME_READ_BACK),
4848 ("bass-boost", READ_BACK),
4949 ("spatial", READ_BACK),
5050 ("wind", READ_BACK),
51+ ("dual", READ_BACK),
5152 ];
5253
5354 fn on_off(on: bool) -> &'static str {
@@ -673,14 +674,12 @@ mod tests {
673674 }
674675
675676 #[test]
676− fn switches_not_yet_verified_are_never_written() {
677+ fn unknown_switches_are_never_written() {
677678 // Nothing is sent after the handshake, so the subscribe ack is left out.
678679 let mut steps = handshake();
679680 steps.pop();
680681 let script = Script::new(steps);
681682 let mut session = open(&script).unwrap();
682− // Dual connection is the last switch (W5d).
683− assert!(matches!(session.set_switch("dual", false), Err(Error::Unsupported(_))));
684683 assert!(matches!(session.set_switch("turbo", true), Err(Error::Unsupported(_))));
685684 script.assert_done();
686685 }
M docs/protocol/realme_t310.md View
@@ -361,7 +361,7 @@ Evidence: *vendor*
361361 <a id="writes"></a>
362362 ## 10. Writes
363363
364−**One at a time.** budctl adds a write only after the previous one passes its hardware checkpoint (see the [roadmap](#roadmap)). Sent so far: [§10.1](#anc-write) off/transparency/on (W1, verified *ours-2026-10-27*), the light/medium/deep levels (W2, verified *ours-2026-10-27*), and [§10.2](#switch-write) game mode (W3, verified *ours-2026-10-27*), and [§10.3](#eq-write) the built-in EQ presets (W4, verified *ours-2026-10-27*), the bass-boost switch `1D` (W5a, verified *ours-2026-10-27*), 3D sound `1B` (W5b, verified *ours-2026-10-27*), and wind-noise reduction `1A` (W5c, verified *ours-2026-10-27*). budctl reads it back at once, because the spec gives it no special timing. The others are not sent yet.
364+**One at a time.** budctl adds a write only after the previous one passes its hardware checkpoint (see the [roadmap](#roadmap)). Sent so far: [§10.1](#anc-write) off/transparency/on (W1, verified *ours-2026-10-27*), the light/medium/deep levels (W2, verified *ours-2026-10-27*), and [§10.2](#switch-write) game mode (W3, verified *ours-2026-10-27*), and [§10.3](#eq-write) the built-in EQ presets (W4, verified *ours-2026-10-27*), the bass-boost switch `1D` (W5a, verified *ours-2026-10-27*), 3D sound `1B` (W5b, verified *ours-2026-10-27*), wind-noise reduction `1A` (W5c, verified *ours-2026-10-27*), and dual connection `11` (W5d, verified *ours-2026-10-27*). budctl reads it back at once, because the spec gives it no special timing. The others are not sent yet.
365365
366366 **General rule**:
367367 - A write reply is `0x84xx <status …>`, and `00` means accepted.
@@ -391,6 +391,7 @@ Evidence: *vendor*
391391 - **Bass boost on the owner's T310** (*ours-2026-10-27*, W5a): `0x0403 1D 01` and `1D 00` were acked with `00` within 30 ms. The immediate read-back already showed the new value, and no push came. With the EQ on pure-bass, the owner heard no clear difference.
392392 - **3D sound on the owner's T310** (*ours-2026-10-27*, W5b): `0x0403 1B 01` and `1B 00` were acked with `00` within 30 ms. The immediate read-back showed the new value. The owner heard a difference but could not name it.
393393 - **Wind-noise reduction on the owner's T310** (*ours-2026-10-27*, W5c): `0x0403 1A 00` and `1A 01` were acked with `00` within 35 ms. The immediate read-back showed the new value. It is not audible in music.
394+- **Dual connection on the owner's T310** (*ours-2026-10-27*, W5d): `0x0403 11 01` and `11 00` were acked with `00` within 50 ms. The immediate read-back showed the new value. The laptop's link stayed up both ways. Only one host was connected (the phone's Bluetooth was off), so turning it off with two hosts connected is still untested.
394395 - **Game mode on the owner's T310** (*ours-2026-10-27*, W3): `0x0403 06 01` and `06 00` were acked with `00` within 13 ms. The read 1 s later already showed the new value. No push came, and the buds played no prompt.
395396 - **Dual connection.** Other clients also send `0x0413` afterwards. The T310's bitmap lacks it, so budctl sends only `0x0403 11`. Turning dual connection off may drop the link to one host, so it is tested last.
396397
@@ -515,6 +516,7 @@ Ask for an Android HCI snoop of realme Link before W11, and for any write that d
515516
516517 | Date | Checkpoint | Result | Notes |
517518 |---|---|---|---|
519+| 2026-10-27 | W5d `set dual on`, `off` | pass | Acked, the immediate read-back showed the change, and the laptop stayed connected. Only one host was connected. See [§10.2](#switch-write) |
518520 | 2026-10-27 | W5c `set wind off`, `on` | pass (protocol) | Acked, and the immediate read-back showed the change. Not audible in music. See [§10.2](#switch-write) |
519521 | 2026-10-27 | W5b `set spatial on`, `off` | pass | Acked, the immediate read-back showed the change, and the owner heard a difference. See [§10.2](#switch-write) |
520522 | 2026-10-27 | W5a `set bass-boost on`, `off` | pass (protocol) | Acked, and the immediate read-back showed the change. The owner heard no clear difference with EQ pure-bass. See [§10.2](#switch-write) |