Skip to content

feat(rynk): dongle groundwork — protocol and config - #1027

Open
HaoboGu wants to merge 4 commits into
mainfrom
feat/dongle-groundwork
Open

feat(rynk): dongle groundwork — protocol and config#1027
HaoboGu wants to merge 4 commits into
mainfrom
feat/dongle-groundwork

Conversation

@HaoboGu

@HaoboGu HaoboGu commented Aug 4, 2026

Copy link
Copy Markdown
Collaborator

Protocol vocabulary and config plumbing for the upcoming 2.4 GHz dongle. Definitions only — no behavior: the keyboard side and the dongle firmware land in follow-ups.

  • Protocol (rmk-types): the 0x09xx dongle command range (info, slot table, slot selection, forget), the DongleSlotsChange topic, DongleInfo / DongleSlot / DongleSlots payloads, the NoTarget error, the dongle_ctrl GATT UUID and its DONGLE_CTRL_OPEN_PAIRING_WINDOW opcode, and decode_header — a non-destructive COBS header peek so a dongle can route a frame without re-encoding it. Wire snapshots updated.
  • New dongle cargo feature (rmk-types, implied by host): gates the dongle-only rows. Without it a keyboard's TopicEvent doesn't grow to DongleSlots size, and GetDongleSlots' response stays out of the payload-budget assert that sets the minimum legal rynk_buffer_size.
  • Config (rmk-config): dongle_slots_num / dongle_links_num / dongle_pairing_window_secs, validated against the new protocol_limits::MAX_DONGLE_SLOTS ceiling and emitted as build constants. DONGLE_SLOTS_NUM follows the established per-build split — the ceiling on host builds for wire compatibility, the configured value on firmware, with a generated ceiling assert.
  • Advertising constants (rmk-types/src/ble.rs): RMK_ADV_COMPANY_ID and DONGLE_SEEKING_ADV_KIND live together, ungated, so the split peripheral and the dongle share one manufacturer-data namespace; rmk/src/split/ble/peripheral.rs now uses the const instead of a bare 0xe118.
  • CI: a --features dongle row for rmk-types — the only configuration where the new gate reaches the firmware-side payload-budget assert.

Stack — depends on #1026; #1028 builds on this branch. The keyboard side (dongle bond slot, dongle key, seeking advertising, dongle_ctrl characteristic) moved out to a follow-up branch so this PR is groundwork only.

@HaoboGu
HaoboGu force-pushed the feat/dongle-groundwork branch from 1600417 to f7da592 Compare August 4, 2026 11:04
@github-actions

github-actions Bot commented Aug 4, 2026

Copy link
Copy Markdown

Size Report

Example main PR Diff .text .data .bss
use_config/nrf52832_ble 397.6 KiB 397.6 KiB +0.00% ⬇️ -4 0 0
use_config/nrf52840_ble 439.6 KiB 439.6 KiB +0.00% 0 0 0
use_config/nrf52840_ble_split (central) 500.8 KiB 500.8 KiB +0.00% 0 0 0
use_config/nrf52840_ble_split (peripheral) 318.8 KiB 318.8 KiB +0.00% 0 0 0
use_config/pi_pico_w_ble 672.7 KiB 672.7 KiB +0.00% 0 0 0
use_config/rp2040 146.3 KiB 146.3 KiB +0.00% 0 0 0
use_config/rp2040_split (central) 159.9 KiB 159.9 KiB +0.00% ⬆️ +4 0 0
use_config/rp2040_split (peripheral) 27.9 KiB 27.9 KiB +0.00% 0 0 0
use_config/stm32f1 62.6 KiB 62.6 KiB +0.00% ⬆️ +4 0 0
use_config/stm32h7 100.4 KiB 100.4 KiB +0.00% ⬆️ +4 0 0
use_rust/nrf52832_ble 385.2 KiB 385.2 KiB +0.00% ⬇️ -4 0 0
use_rust/nrf52840_ble 435.2 KiB 435.2 KiB +0.00% ⬇️ -4 0 0
use_rust/nrf52840_ble_split (central) 504.3 KiB 504.3 KiB +0.00% 0 0 0
use_rust/nrf52840_ble_split (peripheral) 316.4 KiB 316.4 KiB +0.00% ⬇️ -4 0 0
use_rust/pi_pico_w_ble 672.1 KiB 672.1 KiB +0.00% ⬇️ -4 0 0
use_rust/rp2040 145.6 KiB 145.6 KiB +0.00% 0 0 0
use_rust/rp2040_split (central) 158.4 KiB 158.4 KiB +0.00% ⬆️ +4 0 0
use_rust/rp2040_split (peripheral) 28.2 KiB 28.2 KiB +0.00% 0 0 0
use_rust/stm32f1 61.9 KiB 61.9 KiB +0.00% 0 0 0
use_rust/stm32h7 119.7 KiB 119.7 KiB +0.00% 0 0 0
use_config/nrf52832_ble — 397.6 KiB → 397.6 KiB (+0.00% ⬇️)

cargo size (PR):

   text	   data	    bss	    dec	    hex	filename
 364868	   8620	  33624	 407112	  63648	rmk-nrf52832

cargo size (main):

   text	   data	    bss	    dec	    hex	filename
 364872	   8620	  33624	 407116	  6364c	rmk-nrf52832

Bloaty diff (PR vs main):

    FILE SIZE        VM SIZE    
 --------------  -------------- 
  +0.0%     +13  [ = ]       0    .debug_str
  +0.0%      +7  [ = ]       0    .strtab
  +9.8%      +6  [ = ]       0    [Unmapped]
  -0.0%      -4  -0.0%      -4    .text
  -0.0%     -10  [ = ]       0    .debug_loc
  -0.0%    -216  [ = ]       0    .debug_info
  -0.1%    -240  [ = ]       0    .debug_line
  -0.0%    -444  -0.0%      -4    TOTAL
use_config/nrf52840_ble — 439.6 KiB → 439.6 KiB (+0.00%)

cargo size (PR):

   text	   data	    bss	    dec	    hex	filename
 397900	   8628	  43664	 450192	  6de90	rmk-nrf52840

cargo size (main):

   text	   data	    bss	    dec	    hex	filename
 397900	   8628	  43664	 450192	  6de90	rmk-nrf52840

Bloaty diff (PR vs main):

    FILE SIZE        VM SIZE    
 --------------  -------------- 
  +0.0%     +13  [ = ]       0    .debug_str
  +0.0%      +7  [ = ]       0    .strtab
  -0.0%    -216  [ = ]       0    .debug_info
  -0.1%    -240  [ = ]       0    .debug_line
  -0.0%    -436  [ = ]       0    TOTAL
use_config/nrf52840_ble_split (central) — 500.8 KiB → 500.8 KiB (+0.00%)

cargo size (PR):

   text	   data	    bss	    dec	    hex	filename
 455256	   8684	  48856	 512796	  7d31c	central

cargo size (main):

   text	   data	    bss	    dec	    hex	filename
 455256	   8684	  48856	 512796	  7d31c	central

Bloaty diff (PR vs main):

    FILE SIZE        VM SIZE    
 --------------  -------------- 
  +0.0%     +11  [ = ]       0    .debug_str
  +0.0%      +9  [ = ]       0    .strtab
  -0.0%      -2  [ = ]       0    .debug_loc
  -8.5%      -4  [ = ]       0    [Unmapped]
  -0.0%    -216  [ = ]       0    .debug_info
  -0.1%    -234  [ = ]       0    .debug_line
  -0.0%    -436  [ = ]       0    TOTAL
use_config/nrf52840_ble_split (peripheral) — 318.8 KiB → 318.8 KiB (+0.00%)

cargo size (PR):

   text	   data	    bss	    dec	    hex	filename
 292804	   8500	  25184	 326488	  4fb58	peripheral

cargo size (main):

   text	   data	    bss	    dec	    hex	filename
 292804	   8500	  25184	 326488	  4fb58	peripheral

Bloaty diff (PR vs main):

    FILE SIZE        VM SIZE    
 --------------  -------------- 
  +0.0%     +19  [ = ]       0    .strtab
  -0.0%      -2  [ = ]       0    .debug_loc
  -0.0%     -95  [ = ]       0    .debug_line
  -0.0%    -124  [ = ]       0    .debug_str
  -0.0%    -234  [ = ]       0    .debug_info
  -0.0%    -436  [ = ]       0    TOTAL
use_config/pi_pico_w_ble — 672.7 KiB → 672.7 KiB (+0.00%)

cargo size (PR):

   text	   data	    bss	    dec	    hex	filename
 635100	      0	  53704	 688804	  a82a4	rmk-pi-pico-w

cargo size (main):

   text	   data	    bss	    dec	    hex	filename
 635100	      0	  53704	 688804	  a82a4	rmk-pi-pico-w

Bloaty diff (PR vs main):

    FILE SIZE        VM SIZE    
 --------------  -------------- 
  +0.0%    +222  [ = ]       0    .debug_info
  +0.0%     +23  [ = ]       0    .debug_line
  +3.9%      +2  [ = ]       0    [Unmapped]
  +0.0%      +1  [ = ]       0    .strtab
  -0.0%     -10  [ = ]       0    .debug_loc
  -0.0%     -14  [ = ]       0    .debug_str
  +0.0%    +224  [ = ]       0    TOTAL
use_config/rp2040 — 146.3 KiB → 146.3 KiB (+0.00%)

cargo size (PR):

   text	   data	    bss	    dec	    hex	filename
 135880	      0	  13908	 149788	  2491c	rmk-rp2040

cargo size (main):

   text	   data	    bss	    dec	    hex	filename
 135880	      0	  13908	 149788	  2491c	rmk-rp2040

Bloaty diff (PR vs main):

    FILE SIZE        VM SIZE    
 --------------  -------------- 
  +0.0%    +826  [ = ]       0    .debug_str
  +0.1%     +70  [ = ]       0    .strtab
  +0.0%      +2  [ = ]       0    .debug_loc
  -0.0%      -9  [ = ]       0    .debug_info
  -0.0%     -13  [ = ]       0    .debug_line
  +0.0%    +876  [ = ]       0    TOTAL
use_config/rp2040_split (central) — 159.9 KiB → 159.9 KiB (+0.00% ⬆️)

cargo size (PR):

   text	   data	    bss	    dec	    hex	filename
 148908	      0	  14860	 163768	  27fb8	central

cargo size (main):

   text	   data	    bss	    dec	    hex	filename
 148904	      0	  14860	 163764	  27fb4	central

Bloaty diff (PR vs main):

    FILE SIZE        VM SIZE    
 --------------  -------------- 
  +0.0%      +4  +0.0%      +4    .text
  -9.8%      -4  [ = ]       0    [Unmapped]
  -0.0%      -6  [ = ]       0    .strtab
  -0.0%     -25  [ = ]       0    .debug_info
  -0.1%    -101  [ = ]       0    .debug_line
  -0.0%    -140  [ = ]       0    .debug_str
  -0.0%    -272  +0.0%      +4    TOTAL
use_config/rp2040_split (peripheral) — 27.9 KiB → 27.9 KiB (+0.00%)

cargo size (PR):

   text	   data	    bss	    dec	    hex	filename
  25696	     60	   2804	  28560	   6f90	peripheral

cargo size (main):

   text	   data	    bss	    dec	    hex	filename
  25696	     60	   2804	  28560	   6f90	peripheral

Bloaty diff (PR vs main):

    FILE SIZE        VM SIZE    
 --------------  -------------- 
  +0.0%      +4  [ = ]       0    .debug_line
  +3.9%      +2  [ = ]       0    [Unmapped]
  +0.0%      +1  [ = ]       0    .debug_str
  +0.0%      +1  [ = ]       0    .strtab
  +0.0%      +8  [ = ]       0    TOTAL
use_config/stm32f1 — 62.6 KiB → 62.6 KiB (+0.00% ⬆️)

cargo size (PR):

   text	   data	    bss	    dec	    hex	filename
  57748	     28	   6336	  64112	   fa70	rmk-stm32f1

cargo size (main):

   text	   data	    bss	    dec	    hex	filename
  57744	     28	   6336	  64108	   fa6c	rmk-stm32f1

Bloaty diff (PR vs main):

    FILE SIZE        VM SIZE    
 --------------  -------------- 
  +0.1%    +964  [ = ]       0    .debug_str
  +0.2%    +100  [ = ]       0    .strtab
  +0.0%      +4  +0.0%      +4    .text
  -2.9%      -2  [ = ]       0    [Unmapped]
  -0.0%      -6  [ = ]       0    .debug_line
  +0.1% +1.04Ki  +0.0%      +4    TOTAL
use_config/stm32h7 — 100.4 KiB → 100.4 KiB (+0.00% ⬆️)

cargo size (PR):

   text	   data	    bss	    dec	    hex	filename
  94440	    264	   8128	 102832	  191b0	rmk-stm32h7

cargo size (main):

   text	   data	    bss	    dec	    hex	filename
  94436	    264	   8128	 102828	  191ac	rmk-stm32h7

Bloaty diff (PR vs main):

    FILE SIZE        VM SIZE    
 --------------  -------------- 
  +0.2%    +266  [ = ]       0    .debug_line
  +0.0%     +37  [ = ]       0    .debug_str
  +0.0%     +36  [ = ]       0    .debug_info
   +55%     +22  [ = ]       0    [Unmapped]
  +0.0%      +4  +0.0%      +4    .text
  -0.0%      -9  [ = ]       0    .strtab
  +0.0%    +356  +0.0%      +4    TOTAL
use_rust/nrf52832_ble — 385.2 KiB → 385.2 KiB (+0.00% ⬇️)

cargo size (PR):

   text	   data	    bss	    dec	    hex	filename
 352228	   8620	  33560	 394408	  604a8	rmk-nrf52832

cargo size (main):

   text	   data	    bss	    dec	    hex	filename
 352232	   8620	  33560	 394412	  604ac	rmk-nrf52832

Bloaty diff (PR vs main):

    FILE SIZE        VM SIZE    
 --------------  -------------- 
  +9.7%      +6  [ = ]       0    [Unmapped]
  +0.0%      +1  [ = ]       0    .debug_str
  +0.0%      +1  [ = ]       0    .strtab
  -0.0%      -4  -0.0%      -4    .text
  +0.0%      +4  -0.0%      -4    TOTAL
use_rust/nrf52840_ble — 435.2 KiB → 435.2 KiB (+0.00% ⬇️)

cargo size (PR):

   text	   data	    bss	    dec	    hex	filename
 396136	   8628	  40904	 445668	  6cce4	rmk-nrf52840

cargo size (main):

   text	   data	    bss	    dec	    hex	filename
 396140	   8628	  40904	 445672	  6cce8	rmk-nrf52840

Bloaty diff (PR vs main):

    FILE SIZE        VM SIZE    
 --------------  -------------- 
  +0.0%    +140  [ = ]       0    .debug_line
  +0.0%    +111  [ = ]       0    .debug_str
  +0.0%     +48  [ = ]       0    .debug_info
  +0.0%     +34  [ = ]       0    .strtab
  +0.0%     +10  [ = ]       0    .debug_loc
   +10%      +5  [ = ]       0    [Unmapped]
  -0.0%      -4  -0.0%      -4    .text
  +0.0%    +344  -0.0%      -4    TOTAL
use_rust/nrf52840_ble_split (central) — 504.3 KiB → 504.3 KiB (+0.00%)

cargo size (PR):

   text	   data	    bss	    dec	    hex	filename
 456876	   8684	  50824	 516384	  7e120	central

cargo size (main):

   text	   data	    bss	    dec	    hex	filename
 456876	   8684	  50824	 516384	  7e120	central

Bloaty diff (PR vs main):

    FILE SIZE        VM SIZE    
 --------------  -------------- 
  +0.0%      +6  [ = ]       0    .strtab
  +5.6%      +3  [ = ]       0    [Unmapped]
  -0.0%      -1  [ = ]       0    .debug_str
  +0.0%      +8  [ = ]       0    TOTAL
use_rust/nrf52840_ble_split (peripheral) — 316.4 KiB → 316.4 KiB (+0.00% ⬇️)

cargo size (PR):

   text	   data	    bss	    dec	    hex	filename
 290540	   8500	  24952	 323992	  4f198	peripheral

cargo size (main):

   text	   data	    bss	    dec	    hex	filename
 290544	   8500	  24952	 323996	  4f19c	peripheral

Bloaty diff (PR vs main):

    FILE SIZE        VM SIZE    
 --------------  -------------- 
  +0.0%    +232  [ = ]       0    .debug_info
  +0.0%    +154  [ = ]       0    .debug_str
  +0.0%    +100  [ = ]       0    .debug_line
  +0.0%     +11  [ = ]       0    .strtab
  +6.5%      +3  [ = ]       0    [Unmapped]
  -0.0%      -4  -0.0%      -4    .text
  +0.0%    +496  -0.0%      -4    TOTAL
use_rust/pi_pico_w_ble — 672.1 KiB → 672.1 KiB (+0.00% ⬇️)

cargo size (PR):

   text	   data	    bss	    dec	    hex	filename
 634840	      0	  53384	 688224	  a8060	rmk-pi-pico-w

cargo size (main):

   text	   data	    bss	    dec	    hex	filename
 634844	      0	  53384	 688228	  a8064	rmk-pi-pico-w

Bloaty diff (PR vs main):

    FILE SIZE        VM SIZE    
 --------------  -------------- 
   +12%      +6  [ = ]       0    [Unmapped]
  +0.0%      +4  [ = ]       0    .strtab
  +0.0%      +1  [ = ]       0    .debug_str
  -0.0%      -1  [ = ]       0    .debug_line
  -0.0%      -4  -0.0%      -4    .text
  -0.0%     -10  [ = ]       0    .debug_loc
  -0.0%      -4  -0.0%      -4    TOTAL
use_rust/rp2040 — 145.6 KiB → 145.6 KiB (+0.00%)

cargo size (PR):

   text	   data	    bss	    dec	    hex	filename
 135312	      0	  13748	 149060	  24644	rmk-rp2040

cargo size (main):

   text	   data	    bss	    dec	    hex	filename
 135312	      0	  13748	 149060	  24644	rmk-rp2040

Bloaty diff (PR vs main):

    FILE SIZE        VM SIZE    
 --------------  -------------- 
  +0.0%    +102  [ = ]       0    .debug_str
  +0.0%     +80  [ = ]       0    .debug_line
  +0.0%     +37  [ = ]       0    .debug_info
  +0.0%      +5  [ = ]       0    .strtab
  +0.0%    +224  [ = ]       0    TOTAL
use_rust/rp2040_split (central) — 158.4 KiB → 158.4 KiB (+0.00% ⬆️)

cargo size (PR):

   text	   data	    bss	    dec	    hex	filename
 147612	      0	  14604	 162216	  279a8	central

cargo size (main):

   text	   data	    bss	    dec	    hex	filename
 147608	      0	  14604	 162212	  279a4	central

Bloaty diff (PR vs main):

    FILE SIZE        VM SIZE    
 --------------  -------------- 
  +0.0%     +10  [ = ]       0    .debug_loc
  +0.0%      +4  +0.0%      +4    .text
  +5.7%      +3  [ = ]       0    [Unmapped]
  -0.0%      -6  [ = ]       0    .strtab
  -0.0%     -25  [ = ]       0    .debug_info
  -0.1%    -102  [ = ]       0    .debug_line
  -0.0%    -140  [ = ]       0    .debug_str
  -0.0%    -256  +0.0%      +4    TOTAL
use_rust/rp2040_split (peripheral) — 28.2 KiB → 28.2 KiB (+0.00%)

cargo size (PR):

   text	   data	    bss	    dec	    hex	filename
  25796	     60	   3068	  28924	   70fc	peripheral

cargo size (main):

   text	   data	    bss	    dec	    hex	filename
  25796	     60	   3068	  28924	   70fc	peripheral

Bloaty diff (PR vs main):

    FILE SIZE        VM SIZE    
 --------------  -------------- 
  +0.0%      +4  [ = ]       0    .debug_line
  +4.2%      +2  [ = ]       0    [Unmapped]
  +0.0%      +1  [ = ]       0    .debug_str
  +0.0%      +1  [ = ]       0    .strtab
  +0.0%      +8  [ = ]       0    TOTAL
use_rust/stm32f1 — 61.9 KiB → 61.9 KiB (+0.00%)

cargo size (PR):

   text	   data	    bss	    dec	    hex	filename
  57080	     28	   6272	  63380	   f794	rmk-stm32f1

cargo size (main):

   text	   data	    bss	    dec	    hex	filename
  57080	     28	   6272	  63380	   f794	rmk-stm32f1

Bloaty diff (PR vs main):

    FILE SIZE        VM SIZE    
 --------------  -------------- 
  +1.7%      +1  [ = ]       0    [Unmapped]
  -0.0%      -1  [ = ]       0    .debug_str
  [ = ]       0  [ = ]       0    TOTAL
use_rust/stm32h7 — 119.7 KiB → 119.7 KiB (+0.00%)

cargo size (PR):

   text	   data	    bss	    dec	    hex	filename
 108184	    320	  14028	 122532	  1dea4	rmk-stm32h7

cargo size (main):

   text	   data	    bss	    dec	    hex	filename
 108184	    320	  14028	 122532	  1dea4	rmk-stm32h7

Bloaty diff (PR vs main):

    FILE SIZE        VM SIZE    
 --------------  -------------- 
  +0.0%      +9  [ = ]       0    .strtab
  -5.0%      -3  [ = ]       0    [Unmapped]
  -0.0%     -37  [ = ]       0    .debug_str
  -0.0%     -46  [ = ]       0    .debug_info
  -0.2%    -283  [ = ]       0    .debug_line
  -0.0%    -360  [ = ]       0    TOTAL

@HaoboGu
HaoboGu force-pushed the feat/dongle-groundwork branch from f7da592 to 889ca1f Compare August 4, 2026 12:19
@HaoboGu
HaoboGu force-pushed the feat/dongle-groundwork branch 2 times, most recently from bbc1835 to 7b9a7c1 Compare August 4, 2026 12:50
@HaoboGu
HaoboGu force-pushed the feat/dongle-groundwork branch 7 times, most recently from 5ce4363 to cf69a80 Compare August 5, 2026 07:32
@HaoboGu
HaoboGu force-pushed the feat/dongle-groundwork branch 5 times, most recently from 3b2a186 to 433afcc Compare August 5, 2026 11:18
@HaoboGu
HaoboGu force-pushed the feat/dongle-groundwork branch from 433afcc to e1c480f Compare August 5, 2026 11:27
@HaoboGu
HaoboGu force-pushed the feat/dongle-groundwork branch from e1c480f to f508a76 Compare August 5, 2026 12:31
@HaoboGu
HaoboGu force-pushed the feat/dongle-groundwork branch 3 times, most recently from 410eae2 to 81a733f Compare August 5, 2026 16:10
@HaoboGu
HaoboGu force-pushed the feat/dongle-groundwork branch from 81a733f to cc4db26 Compare August 5, 2026 16:14
@HaoboGu
HaoboGu force-pushed the feat/dongle-groundwork branch from cc4db26 to aa47698 Compare August 5, 2026 16:20
@HaoboGu
HaoboGu force-pushed the feat/dongle-groundwork branch from aa47698 to 4dfe73a Compare August 5, 2026 16:26
Base automatically changed from refactor/ble-stack-ownership to main August 5, 2026 16:54
@HaoboGu
HaoboGu force-pushed the feat/dongle-groundwork branch 2 times, most recently from b67d3f6 to 2db1001 Compare August 5, 2026 17:48
@HaoboGu
HaoboGu force-pushed the feat/dongle-groundwork branch from 2db1001 to 97c3891 Compare August 6, 2026 10:15
@HaoboGu HaoboGu changed the title feat(rynk): dongle groundwork — protocol, config, and the keyboard side feat(rynk): dongle groundwork — protocol and config Aug 6, 2026
HaoboGu added 3 commits August 7, 2026 00:26
- `DongleSlot` keeps only what survives the keyboard being off — slot,
  connected, name. Battery came from the dongle's BAS client, which has no
  charge state to report; the host reads the keyboard's own richer
  `BatteryStatus` through the pass-through instead.
- Wire types size by the protocol ceiling (`MAX_DONGLE_SLOTS`), which is a
  decoder's bound; `DONGLE_SLOTS_NUM` is the dongle's own table length and is
  now emitted only under the `dongle` feature, along with its ceiling assert.
- `wire_frames.snap` gains every feature-gated row instead of dropping it:
  the test is gated on `host`, the feature superset, so the file is generated
  once and complete rather than identical-because-truncated across sets.
- The dongle's `led_indicator` subscriber count is derived from
  `dongle_links_num` (one per link task) instead of a hardcoded 2 that a
  raised link count would silently outgrow.
- Compatibility section states the `RynkError` append rule and that 0.x is
  pre-release; `GetDongleInfo`'s note trimmed to what the row doesn't say.
… table

- `GetDongleInfo` is gone. The probe was never the payload — it's the routing
  rule: a keyboard rejects the whole `0x09xx` segment as `UnknownCmd`, so
  `GetDongleSlots` identifies a dongle *and* returns what the host actually
  needs, in one round trip. Its `slots_num`/`links_num` had no host consumer
  (pairing is keyboard-triggered, a full table evicts by LRU), and its
  `version` had nothing to compare against, since `GetVersion` is forwarded
  and answers for the keyboard. `0x09xx` renumbers to close the gap; 0.x is
  pre-release.
- `DongleSlots.slots` is now dense — `Vec<Option<DongleSlot>>` whose index is
  the slot number, so `DongleSlot.slot` goes away and empty slots become
  representable. A host can then warn before a full table silently evicts the
  least-recently-seen keyboard on the next pairing.
- The connect handshake joins `GetDongleSlots` with the version and capability
  requests, so the same round trip identifies the peer. This is load-bearing:
  a dongle whose target is off answers its own segment while the forwarded
  pair fails with `NoTarget`, which today aborts `connect` before the host can
  probe at all.
- `Client` holds a `Peer` (keyboard / dongle with target / dongle without)
  instead of a bare `DeviceCapabilities`; keyboard endpoints fail locally with
  `NoDongleTarget` when there is no target to forward to.
The dongle stopped issuing Rynk requests, so a slot name now comes from the
GAP device name. The size alias still holds: a keyboard publishes one string
as both that and DeviceInfo::product_name.
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