Bump abstract-bits to support signed integers - #58
Open
puddly wants to merge 3 commits into
Open
Conversation
puddly
marked this pull request as ready for review
August 20, 2026 19:54
There was a problem hiding this comment.
Pull request overview
Updates the workspace to a newer abstract-bits revision that supports signed integer fields, allowing the Zigbee/protocol wire types to use i8 directly and removing local serialization workarounds.
Changes:
- Switch
abstract-bitsdependency to a pinned git revision and update lockfiles accordingly. - Replace several “two’s complement in
u8” fields with reali8fields in protocol payloads and remove the corresponding casts in bridge/server/NCP code. - Remove the custom
RenamedU24workaround and useu24directly for Zigbee beacontx_offset.
Reviewed changes
Copilot reviewed 11 out of 13 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| crates/ziggurat-zigbee/src/beacon.rs | Drops the RenamedU24 workaround and uses u24 directly in the beacon payload (and test). |
| crates/ziggurat-zigbee/Cargo.toml | Points abstract-bits at the new pinned git revision. |
| crates/ziggurat-server/src/main.rs | Removes as u8 casts and sends i8 RSSI values directly in events. |
| crates/ziggurat-protocol/src/wire.rs | Changes wire payload fields from u8 to i8 for signed values (RSSI/priority/tx_power). |
| crates/ziggurat-protocol/src/bridge.rs | Removes now-unnecessary casts when mapping between wire payloads and driver/stack types. |
| crates/ziggurat-protocol/Cargo.toml | Points abstract-bits at the new pinned git revision. |
| crates/ziggurat-ncp-api/src/protocol.rs | Removes as u8 casts and forwards i8 RSSI values directly in events. |
| crates/ziggurat-ncp-api/Cargo.toml | Points abstract-bits at the new pinned git revision. |
| crates/ziggurat-ncp-api/Cargo.lock | Lockfile updates due to the new abstract-bits revision and its proc-macro dependency changes. |
| crates/ziggurat-ieee-802154/Cargo.toml | Points abstract-bits at the new pinned git revision. |
| crates/ziggurat-driver/src/zigbee_stack/mac.rs | Updates beacon construction to use u24 directly for tx_offset. |
| crates/ziggurat-driver/Cargo.toml | Points abstract-bits at the new pinned git revision. |
| Cargo.lock | Workspace lockfile updates due to the new abstract-bits revision and its proc-macro dependency changes. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Comment on lines
12
to
16
| # Types only (ZigbeeNotification, NetworkConfig, ZigbeeStack, …); the runtime seam is | ||
| # left to whichever workspace consumes this crate (tokio on the host, embassy on the MCU). | ||
| ziggurat-driver = { path = "../ziggurat-driver", default-features = false } | ||
| abstract-bits = { git = "https://github.com/yara-blue/abstract-bits.git", version = "0.2.0" } | ||
| abstract-bits = { git = "https://github.com/puddly/abstract-bits.git", rev = "1f67dd91dce8a4c3b2c760ac317780856c1d6805", version = "0.2.0" } | ||
| arbitrary-int = "2.1.1" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Implemented in yara-blue/abstract-bits#10, which adds support for signed integers and lets us remove a few hacks.