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

[portinglayer][ota] implement ota porting layer api #135

Merged
merged 4 commits into from
Jul 5, 2023
Merged

Conversation

step0035
Copy link
Collaborator

@step0035 step0035 commented Jun 26, 2023

  • matter sdk ota code should not call lower layer api
  • implement portinglayer api for ota
  • fix issue caused by long duration of flash erase
    • might get hardfault sometimes during long flash erase
    • blocking call might cause time-sensitive events such as matter subscription to timeout
  • we fix this by storing the ota payload in a 4kb buffer (size of a sector is 4kb)
  • once this buffer is filled up, erase the sector and write to that sector
  • if ota abort (default ~10minutes timeout), a non-blocking background task will handle the flash erasure and self-delete afterwards.
  • also rename core/matter_ota.cpp to core/matter_ota_initializer.cpp to avoid duplicate

@step0035
Copy link
Collaborator Author

wait for corresponding matter sdk update to merge first

@AdamZhang0124 AdamZhang0124 merged commit 73c2dd6 into main Jul 5, 2023
@step0035 step0035 deleted the ota_porting branch July 6, 2023 02:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants