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

Major rework on BlockStorage #1214

Merged
merged 1 commit into from
Feb 19, 2019

Conversation

josesimoes
Copy link
Member

Description

  • Remove platform implementations of BlockStorage functions.
  • Add configuration file for BlockStorage per target.
  • Now each target is completly independent to add any number of BlockStorage devices.
  • Add calls to BlockStorageList Initialize() and InitializeDevices()
    in ESP32 nanoHAL_Initialize.
  • Add new BlockRegionAttribute attribute.
  • Add new Attributes field to BLOCKREGIONINFO struct.
  • Add new function to flash driver declaration GetMemoryMappedAddress.
  • Remove unused code and vars that were supporting BlockStorage as a linked list.
  • BlockStorage list is now a plain simple array.
  • Remove unused StorageUsage enum.
  • Add support for memory mapped block storage.
    -Remove nfweak attribute from most functions in BlockStorage API.
  • Rework several functions in BlockStorage API.
  • Rework ESP32 flash driver to leverage on new memory mapped stuff.
  • Code clean up on ESP32 app_main.
  • Rework code on debugger and startup to follow the new API.
  • Move asserts declaration from old HAL to HALv2.
  • Code tidy up at several places to follow project guidelines.
  • Update WIN32 nanoCLR as required.

Motivation and Context

  • Normalize BlockStorage implementation among platforms and targets.
  • Allow targets to have independent block storage implementations.
  • Add official support for memory mapped storage platforms (like ESP32).
  • Make way for using BlockStorage with other media (SPI flashes, SD Cards, etc).
  • Resolves Simplify BlockStorage Home#114.

How Has This Been Tested?

  • Querying device capabilities on STM32 and ESP32 targets.
  • Deploy, run and erase blinky test app.

Screenshots

Types of changes

  • Improvement (non-breaking change that improves a feature, code or algorithm)
  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have read the CONTRIBUTING document.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

Signed-off-by: José Simões [email protected]

@josesimoes josesimoes added Type: enhancement Series: STM32xx Everything related specifically with STM32 targets Series: ESP32 Everything related specifically with ESP32 series targets Platform: Virtual Device & WIN32 Everything related specifically with WIN32 and .NET tool builds Area: Common libs Everything related with common libraries Breaking-change labels Feb 19, 2019
@nfbot
Copy link
Member

nfbot commented Feb 19, 2019

Hi @josesimoes,

I'm nanoFramework bot.
Thank you for your contribution!

A human will be reviewing it shortly. 😉

@josesimoes josesimoes force-pushed the rework-blockstorage branch 10 times, most recently from de290f0 to 179ca93 Compare February 19, 2019 12:17
- Remove platform implementations of BlockStorage functions.
- Add configuration file for BlockStorage per target.
- Now each target is completly independent to add any number of BlockStorage devices.
- Add calls to BlockStorageList Initialize() and InitializeDevices()
 in ESP32 nanoHAL_Initialize.
- Add new BlockRegionAttribute attribute.
- Add new  Attributes field to BLOCKREGIONINFO struct.
- Add new function to flash driver declaration GetMemoryMappedAddress.
- Remove unused code and vars that were supporting BlockStorage as a linked list.
- BlockStorage list is now a plain simple array.
- Remove unused StorageUsage enum.
- Add support for memory mapped block storage.
-Remove nfweak attribute from most functions in BlockStorage API.
- Rework several functions in BlockStorage API.
- Rework ESP32 flash driver to leverage on new memory mapped stuff.
- Code clean up on ESP32 app_main.
- Rework code on debugger and startup to follow the new API.
- Move asserts declaration from old HAL to HALv2.
- Code tidy up at several places to follow project guidelines.
- Update WIN32 nanoCLR as required.

Signed-off-by: José Simões <[email protected]>
@josesimoes josesimoes merged commit dfd3186 into nanoframework:develop Feb 19, 2019
@josesimoes josesimoes deleted the rework-blockstorage branch February 19, 2019 12:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area: Common libs Everything related with common libraries Breaking-change Platform: Virtual Device & WIN32 Everything related specifically with WIN32 and .NET tool builds Series: ESP32 Everything related specifically with ESP32 series targets Series: STM32xx Everything related specifically with STM32 targets Type: enhancement
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Simplify BlockStorage
2 participants