-
Notifications
You must be signed in to change notification settings - Fork 440
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remove ieee802154 from IphcRepr #1033
base: main
Are you sure you want to change the base?
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #1033 +/- ##
==========================================
- Coverage 80.88% 80.26% -0.62%
==========================================
Files 81 81
Lines 28452 28734 +282
==========================================
+ Hits 23013 23064 +51
- Misses 5439 5670 +231 ☔ View full report in Codecov by Sentry. |
Was hoping to get some feedback on the structure of things before investing time into improving coverage. |
Could you explain why is this needed to support 6lowpan over BLE? IIUC address compression works the same way in both 6lo over BLE and 6lo over ieee802.15.4. The info you use to compress/decompress is an EUI64 that can be derived from either the ieee802.15.4 link address or the BLE link address. So I think it should be possible to pass in the EUI64, and have higher layers calculate it differently depending on whether the link is ieee802.15.4 or BLE? Then the code can stay in the same place, the refactor is not needed. I'm not a 6lowpan expert though. Hopefully @thvdveld can weigh in. (The reason I'm a bit concerned with the refactor is that "look at packet fields, write Rust enum, copy it around, match it to do thing" typically increases code size vs "look at packet fields, do thing") |
Yes, this is largely the case for non-contextual compression.
Due to the things I've mentioned above, some kind of refactor will still be needed to remove ieee802.15.4 from There's more info in the linked issue. |
My question is: why can't we keep the current code structure, just replace This way |
I unfortunately don't know enough about ieee802154 to give you a good answer. @thvdveld thinks an EUI64 isn't enough for ieee802154. |
First part of #1031 .
The
IphcRepr
type was written in terms of ieee802154 addresses.I've replaced the ieee802154 address for structures that closer match the RFC and can be used on other mediums like BLE.
After this, I need to do the same for
sixlowpan/mod.rs
and move the ieee802154 bits into thewire/ieee802154.rs
file.