Repository navigation
Update device capabilities and versions for FiRa 2.0 - #154
Conversation
There was a problem hiding this comment.
Code Review
This pull request updates the UCI, MAC, and PHY versions to 2.0 and refactors how device capabilities are defined and handled. It introduces a structured Capabilities struct in src/device.rs and updates the CapTlvType enum in both Python and PDL definitions to include new capability types. Additionally, a new test is added to verify these capabilities. The code review feedback is highly constructive and should be fully addressed: it points out an incorrect capability value for ranging_time_struct (which should be 0x01 for block-based scheduling), suggests correcting an inaccurate comment regarding session_key_length, and recommends defining and using enum constants for CCC and Aliro vendor-specific capabilities instead of raw magic numbers in tests.
26a5510 to
4014abe
Compare
bf68078 to
1dd9646
Compare
Although PR #144 introduced DL-TDoA roles, ranging methods, and active-round limits on top of UCI 2.0, Pica still reported MAC and PHY version 1.3, and DEFAULT_CAPS_INFO retained untyped FiRa 1.1 byte slices. Consequently, capability tag IDs were shifted relative to FiRa 2.0, mandatory FiRa 2.0 tags were missing, and scheduling bitmasks were incorrect. Bump MAC_VERSION and PHY_VERSION to 2.0, update CapTlvType in PDL and uci.py to FiRa 2.0 tag IDs, and replace DEFAULT_CAPS_INFO with a typed Capabilities struct covering all mandatory FiRa 2.0 and optional DL-TDoA, CCC, and Aliro capabilities. Closes #146
Although PR #144 introduced DL-TDoA roles, ranging methods, and active-round limits on top of UCI 2.0, Pica still reported MAC and PHY version 1.3, and DEFAULT_CAPS_INFO retained untyped FiRa 1.1 byte slices. Consequently, capability tag IDs were shifted relative to FiRa 2.0, mandatory FiRa 2.0 tags were missing, and scheduling bitmasks were incorrect.
Bump MAC_VERSION and PHY_VERSION to 2.0, update CapTlvType in PDL and uci.py to FiRa 2.0 tag IDs, and replace DEFAULT_CAPS_INFO with a typed Capabilities struct covering all mandatory FiRa 2.0 and optional DL-TDoA, CCC, and Aliro capabilities.
Closes #146