Skip to content
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

openthread_border_router: Firmware updates for third party Silabs dongles #3628

Merged
merged 7 commits into from
Jun 21, 2024

Conversation

darkxst
Copy link
Contributor

@darkxst darkxst commented Jun 6, 2024

Provide support for auto firmware updates on some popular third party dongles. Using firmware builds from: https://github.com/darkxst/silabs-firmware-builder

OTBR supports a wide range of firmware versions, thus any update of OTBR itself is unlikely to require new firmware builds. So these third-party firmware should never block a new OTBR release.

NB: SLZB-07 support requires the device has the cp2102 eeprom flashed with manufacturer strings, only newer stock has this from the factory. However SMLIGHT will be releasing a tool for user to update eeprom content on older devices.

Summary by CodeRabbit

  • New Features

    • Added support for auto firmware updates for Sonoff ZBDongle-E.
    • Added support for auto firmware updates for SMLIGHT SLZB-07.
    • Introduced network socket support using socat in version 2.6.0.
  • Updates

    • Updated the SiLabs flasher to version 0.0.20.

Copy link
Contributor

coderabbitai bot commented Jun 6, 2024

Walkthrough

Walkthrough

The recent updates to openthread_border_router encompass enhanced functionality with the addition of auto firmware update support for Sonoff ZBDongle-E and SMLIGHT SLZB-07. The SiLabs flasher version is also updated to 0.0.20. Moreover, the network socket support using socat introduced in version 2.6.0 is highlighted.

Changes

File Path Change Summary
openthread_border_router/CHANGELOG.md Added support for auto firmware updates for Sonoff ZBDongle-E, SMLIGHT SLZB-07, and updated the SiLabs flasher version.
openthread_border_router/build.yaml Updated UNIVERSAL_SILABS_FLASHER version from 0.0.18 to 0.0.20.
openthread_border_router/config.yaml Updated version from 2.6.0 to 2.7.0.
openthread_border_router/rootfs/.../universal-silabs-flasher-up Added new firmware flashing options and GPIO reset flags for specific devices.

Sequence Diagram(s)

sequenceDiagram
    participant User
    participant BorderRouter
    participant FirmwareRepo
    participant USBDevice

    User->>+BorderRouter: Initializes firmware update
    BorderRouter->>+FirmwareRepo: Fetch firmware for device
    FirmwareRepo-->>-BorderRouter: Firmware package
    BorderRouter->>+USBDevice: Check device type
    USBDevice-->>-BorderRouter: Device type (e.g., Sonoff ZBDongle-E)
    BorderRouter->>+USBDevice: Send firmware update commands
    USBDevice-->>-BorderRouter: Firmware updated response
    BorderRouter-->>-User: Update completed
Loading

Recent review details

Configuration used: CodeRabbit UI
Review profile: ASSERTIVE

Commits

Files that changed from the base of the PR and between c900989 and 6d4312a.

Files selected for processing (1)
  • openthread_border_router/CHANGELOG.md (1 hunks)
Additional context used
Path-based instructions (1)
openthread_border_router/CHANGELOG.md (4)

Pattern */**(html|markdown|md): - For instructional content in documentation, use a direct and authoritative tone. Avoid expressions of politeness such as 'may' or 'please', and ensure the goal of the instruction is fronted.

  • Apply the Microsoft Style Guide to ensure documentation maintains clarity and conciseness.
  • In step-by-step instructions, front the location phrase in the instructional sentence.
  • In step-by-step instructions, front the 'goal' in the instructional sentence.
  • In step-by-step instructions, if in doubt what to front, front the 'goal' before the location phrase in the instructional sentence.
  • do not hyphenate terms like 'top-right' or 'bottom-left' with 'corner'

Pattern */**(html|markdown|md): - Use bold to mark UI strings.

  • If "" are used to mark UI strings, replace them by bold.

Pattern */**(html|markdown|md): - Be brief in your replies and don't add fluff like "thank you for..." and "Please let me know if"


Pattern */**(html|markdown|md): - Use sentence-style capitalization also in headings.

LanguageTool
openthread_border_router/CHANGELOG.md

[misspelling] ~5-~5: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ....0 - Support auto firmware updates for Sonoff ZBDongle-E - Support auto firmware upda...


[misspelling] ~5-~5: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...upport auto firmware updates for Sonoff ZBDongle-E - Support auto firmware updates for SML...


[misspelling] ~6-~6: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...e-E - Support auto firmware updates for SMLIGHT SLZB-07 - Bump universal SiLabs flasher...


[misspelling] ~7-~7: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...es for SMLIGHT SLZB-07 - Bump universal SiLabs flasher to 0.0.20 ## 2.6.0 - Add supp...


[misspelling] ~11-~11: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...- Add support for network sockets using socat ## 2.5.1 - Support Home Assistant Conn...


[misspelling] ~18-~18: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...ant Connect ZBT-1. ## 2.5.0 - Bump to OTBR POSIX version 2279c02f3c (2024-02-28 22...


[misspelling] ~23-~23: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...r fix for container shutdown in case of OTBR agent failures ## 2.4.6 - Bump to OTB...


[misspelling] ~27-~27: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...TBR agent failures ## 2.4.6 - Bump to OTBR POSIX version 9bdaa91016 (2024-02-15 08...


[misspelling] ~28-~28: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...-02-15 08:50:34 -0800) - Bump universal SiLabs flasher to 0.0.18 - Fix container shutd...


[misspelling] ~29-~29: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...0.0.18 - Fix container shutdown in case OTBR agent fails to startup - Shutdown mDNS ...


[misspelling] ~30-~30: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...to startup - Shutdown mDNS daemon after OTBR agent (allows the OTBR service to pro...


[misspelling] ~30-~30: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...DNS daemon after OTBR agent (allows the OTBR service to properly sign off on the n...


[misspelling] ~37-~37: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ... when NAT64 is enabled - Bump universal SiLabs flasher to 0.0.17 - Bump to OTBR POSIX ...


[misspelling] ~38-~38: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...rsal SiLabs flasher to 0.0.17 - Bump to OTBR POSIX version 13d583e361 (2024-01-26 09...


[misspelling] ~43-~43: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...becoming unreachable when operating the OTBR with other TBRs - Bump to OTBR POSIX ve...


[misspelling] ~44-~44: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...ting the OTBR with other TBRs - Bump to OTBR POSIX version 02421b0ea6 (2024-01-19 15...


[misspelling] ~48-~48: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...-19 15:58:03 -0800) ## 2.4.3 - Enable TREL support on infrastructure link - Enable...


[misspelling] ~50-~50: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...support (disabled by default) - Bump to OTBR POSIX version 657e775cd9 (2024-01-05 17...


[misspelling] ~54-~54: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...-05 17:10:13 -0800) ## 2.4.2 - Update firmare for Home Assistant SkyConnect and Yello...


[misspelling] ~54-~54: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ....2 - Update firmare for Home Assistant SkyConnect and Yellow to the latest version buil...


[misspelling] ~56-~56: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...om Gecko SDK v4.4.0.0. - Bump universal SiLabs flasher to 0.0.16 ## 2.4.1 - Fix NAT6...


[misspelling] ~64-~64: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...NAT64 enable script ## 2.4.0 - Enable TREL - Enable NAT64 (disabled by default) - ...


[misspelling] ~66-~66: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...e NAT64 (disabled by default) - Bump to OTBR POSIX version 27ed99f375 (2023-12-13 10...


[misspelling] ~67-~67: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...-12-13 10:11:52 -0800) - Bump universal SiLabs flasher to 0.0.15 - Shutdown add-on on ...


[misspelling] ~68-~68: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ... flasher to 0.0.15 - Shutdown add-on on otbr-agent crash (use Supervisor Watchdog function...


[misspelling] ~73-~73: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...utomatic restarts) ## 2.3.2 - Bump to OTBR POSIX version 9e50efa8de (2023-08-23 21...


[misspelling] ~74-~74: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...23-08-23 21:28:30 -0700) This updates mDNSResponder to 1790.80.10 ## 2.3.1 - Update firma...


[misspelling] ~78-~78: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...onder to 1790.80.10 ## 2.3.1 - Update firmare for Home Assistant SkyConnect and Yello...


[misspelling] ~78-~78: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ....1 - Update firmare for Home Assistant SkyConnect and Yellow to the latest version buil...


[misspelling] ~83-~83: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...ecko SDK v4.3.1.0. ## 2.3.0 - Bump to OTBR POSIX version 8d12b242db (2023-07-13 20...


[misspelling] ~84-~84: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ... includes the new REST API to reset the OTBR - Bump universal SiLabs flasher to 0.0....


[misspelling] ~85-~85: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ... API to reset the OTBR - Bump universal SiLabs flasher to 0.0.13 - Use add-on hostname...


[misspelling] ~86-~86: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ....13 - Use add-on hostname to connect to OTBR REST API ## 2.2.0 - Update firmare fo...


[misspelling] ~90-~90: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...ct to OTBR REST API ## 2.2.0 - Update firmare for Home Assistant SkyConnect and Yello...


[misspelling] ~90-~90: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ....0 - Update firmare for Home Assistant SkyConnect and Yellow to the latest version buil...


[misspelling] ~99-~99: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ... deleting datasets ## 2.0.0 - Bump to OTBR POSIX version f46f68956b (2023-05-23 09...


[misspelling] ~100-~100: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...ludes the new REST API part of upstream OTBR ## 1.2.0 - Fix firmware flashing on H...


[misspelling] ~105-~105: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ... Home Assistant Yellow - Bump universal SiLabs flasher to 0.0.12 - Bump to OTBR POSIX ...


[misspelling] ~106-~106: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...rsal SiLabs flasher to 0.0.12 - Bump to OTBR POSIX version cbeaf817c5 (2023-03-29 11...


[misspelling] ~111-~111: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...cally flash firmware for Home Assistant SkyConnect and Yellow - Update serial port default...


[misspelling] ~117-~117: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...Drop armv7 support ## 1.0.0 - Bump to OTBR POSIX version d83fee189a (2023-02-28 08...


[typographical] ~120-~120: Unpaired symbol: ‘"’ seems to be missing (EN_UNPAIRED_QUOTES)
Context: ...uct name to Silicon Labs Multiprotocol" (used in OTBR mDNS/DNS-SD announcments)...


[misspelling] ~120-~120: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ... Silicon Labs Multiprotocol" (used in OTBR mDNS/DNS-SD announcments) - Set default...


[misspelling] ~120-~120: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...ultiprotocol" (used in OTBR mDNS/DNS-SD announcments) - Set default baudrate 115200 correctl...


[misspelling] ~121-~121: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...mDNS/DNS-SD announcments) - Set default baudrate 115200 correctly - Let the OTBR REST AP...


[misspelling] ~122-~122: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...ult baudrate 115200 correctly - Let the OTBR REST API listen on local interface only...


[uncategorized] ~124-~124: When ‘HTTP-compliant’ is used as a modifier, it is usually spelled with a hyphen. (SPECIFIC_HYPHEN)
Context: ...HTTP header - Fix REST API to return an HTTP compliant status line - Add OTBR discovery suppor...


[misspelling] ~125-~125: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...urn an HTTP compliant status line - Add OTBR discovery support ## 0.3.0 - Bump to ...


[misspelling] ~129-~129: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ... discovery support ## 0.3.0 - Bump to OTBR POSIX version 079bbce34a (2022-12-22 19...


[misspelling] ~132-~132: This word is normally spelled with a hyphen. (EN_COMPOUNDS_FINE_GRAINED)
Context: ...e primary interfaces are returned - Add fine grained OTBR log level control - Fix service st...


[misspelling] ~132-~132: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...erfaces are returned - Add fine grained OTBR log level control - Fix service stop (f...


[misspelling] ~137-~137: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...Pv6 forwarding explicitly (required for HAOS 9.x) - Add egress firewall rules for fo...


[misspelling] ~142-~142: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...irewall is enabled ## 0.2.5 - Bump to OTBR POSIX version 110eb2507c (2022-11-24 14...


[misspelling] ~146-~146: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...24 14:36:14 -0800) ## 0.2.4 - Bump to OTBR POSIX version 0e15296792 (2022-11-07 12...


[misspelling] ~154-~154: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ... Firewall shutdown ## 0.2.2 - Bump to OTBR POSIX version 9fea68cfbe (2022-06-03 11...


[misspelling] ~176-~176: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...hardware flow control ## 0.1.2 - Bump OTBR to ot-br-posix git f8399eb08/openthread...


[misspelling] ~176-~176: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ... flow control ## 0.1.2 - Bump OTBR to ot-br-posix git f8399eb08/openthread git 7dfde1f12 ...


[misspelling] ~176-~176: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ... Bump OTBR to ot-br-posix git f8399eb08/openthread git 7dfde1f12 ## 0.1.1 - Add baudrate...


[misspelling] ~180-~180: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...enthread git 7dfde1f12 ## 0.1.1 - Add baudrate and hardware flow control configuration...

Markdownlint
openthread_border_router/CHANGELOG.md

13-13: Expected: 1; Actual: 0; Below (MD022, blanks-around-headings)
Headings should be surrounded by blank lines


14-14: null (MD032, blanks-around-lists)
Lists should be surrounded by blank lines

Additional comments not posted (3)
openthread_border_router/CHANGELOG.md (3)

7-7: Approved: SiLabs flasher version bump

The update of the SiLabs flasher version to 0.0.20 is correctly documented. This change aligns with the PR objectives and the AI-generated summary.

Tools
LanguageTool

[misspelling] ~7-~7: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...es for SMLIGHT SLZB-07 - Bump universal SiLabs flasher to 0.0.20 ## 2.6.0 - Add supp...


5-6: Approved: Auto firmware update support

The entries for auto firmware updates for Sonoff ZBDongle-E and SMLIGHT SLZB-07 are correctly added under version 2.7.0. This update is consistent with the PR description.

Tools
LanguageTool

[misspelling] ~5-~5: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ....0 - Support auto firmware updates for Sonoff ZBDongle-E - Support auto firmware upda...


[misspelling] ~5-~5: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...upport auto firmware updates for Sonoff ZBDongle-E - Support auto firmware updates for SML...


[misspelling] ~6-~6: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...e-E - Support auto firmware updates for SMLIGHT SLZB-07 - Bump universal SiLabs flasher...


11-11: Approved: Addition of network socket support

The addition of network socket support using socat under version 2.6.0 is documented clearly. This entry enhances the changelog's detail and accuracy.

Tools
LanguageTool

[misspelling] ~11-~11: Possible spelling mistake found. (MORFOLOGIK_RULE_EN_US)
Context: ...- Add support for network sockets using socat ## 2.5.1 - Support Home Assistant Conn...


Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

Share
Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai generate interesting stats about this repository and render them as a table.
    • @coderabbitai show all the console.log statements in this repository.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (invoked as PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Additionally, you can add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.

CodeRabbit Configration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

openthread_border_router/build.yaml Show resolved Hide resolved
@agners agners changed the title Openthread auto firmware updates for third party Silabs dongles openthread_border_router: Firmware updates for third party Silabs dongles Jun 21, 2024
Copy link
Member

@agners agners left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've added the universal SiLabs flasher bump to the changelog.

Otherwise looks good! Thanks!

@agners agners merged commit f2c5704 into home-assistant:master Jun 21, 2024
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants