You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@mynewt.apache.org by Vipul Rahane <vi...@runtime.io> on 2016/11/21 20:23:00 UTC

Changes to newtmgr fragmentation code (Backwards compatibility breaking changes)

Hello,

I wanted to do a change to the newtmgr library in mynewt. 

Current functionality: 

Firmware: We have a flag named NMGR_F_CBOR_RSP_COMPLETE. When the protocol fragments the response, it sets this flag on the last fragment. Each fragment has a 8 byte newtmgr header which is not currently used for any specific purpose in subsequent fragments other than the first fragment.
Each fragments header contains the length of the fragment.

Newtmgr Tool: Caters to firmware functionality.

Proposed changes: 

Firmware: Only the first fragment would have a newtmgr header with the length of the entire response. The subsequent fragments would not contain the header. NMGR_F_CBOR_RSP_COMPLETE will get removed with the above changes. This would mean that reliability would get handled by the transport as opposed to the application layer protocol. Bluetooth being a reliable protocol, fragmentation works fine.

Newtmgr Tool: Make changes to it to cater to the firmware functionality.

The changes would be released in 1.0.0.beta2.

Any comments or suggestions are welcome.

Regards,
Vipul Rahane