Skip to content

Separate radio TSN from ZCL/ZDO TSN - #291

Draft
puddly wants to merge 2 commits into
zigpy:devfrom
puddly:puddly/fix-tsn
Draft

puddly wants to merge 2 commits into
zigpy:devfrom
puddly:puddly/fix-tsn

Conversation

@puddly

@puddly puddly commented Nov 4, 2026 •

Copy link
Copy Markdown
Member

Fixes #290.

The Z-Stack TSN is an internal ID that's just passed by the radio library and returned by Z-Stack for status updates and responses, it has no relation to any on-air frame counters. Since the counter is only 8 bits, I've taken the aiospinel approach of having a global asyncio queue of request IDs. This guarantees no overlap, reuse, and allows requests to queue up and wait for a free TID.

@zigpy-review-bot zigpy-review-bot added the bugfix This PR fixes a bug label Nov 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bugfix This PR fixes a bug

Projects

None yet

Development

Successfully merging this pull request may close these issues.

AF.DataConfirm is matched by ZCL TSN only, so concurrent same-TSN requests to different devices get each other's delivery status

2 participants