Skip to content

MultiTech mDot: use mbed tools to merge bootloader and application. #12918

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

Closed
wants to merge 3 commits into from

Conversation

theckmts
Copy link
Contributor

@theckmts theckmts commented May 4, 2020

Summary of changes

Removes MTS_MDOT_F411RE bootloader from tools/bootloaders and modifies the MTS_MDOT_F411RE definition in targets/targets.json so a bootloader can be specified in mbed_app.json and merged with an application using mbed cli tools.

This change is needed so the mDot bootloader can be maintained independently of mbed-os and allow users to choose their own bootloader.

Impact of changes

Existing projects targeting MTS_MDOT_F411RE that want to continue using the MTS bootloader will need to be modified to include it in their configuration settings.

Migration actions required

Documentation

None


Pull request type

[X] Patch update (Bug fix / Target update / Docs update / Test update / Refactor)
[] Feature update (New feature / Functionality change / New API)
[] Major update (Breaking change E.g. Return code change / API behaviour change)

Test results

[] No Tests required for this change (E.g docs only update)
[] Covered by existing mbed-os tests (Greentea or Unittest)
[X] Tests / results supplied as part of this PR

Tested compiling with GCC_ARM, ARMC6, and IAR compilers using mbed cli tools.

For each compiler, verified bootloader is merged with application, application runs as expected, and bootloader version is correct.

GCC_ARM compiler output

Building project blinky (MTS_MDOT_F411RE, GCC_ARM)
Scan: blinky
Scan: mts-mbed-os
Using ROM regions bootloader, application in this build.
  Region bootloader: size 0x10000, offset 0x8000000
  Region application: size 0x70000, offset 0x8010000

..

Link: blinky
Elf2Bin: blinky
Merging Regions
  Filling region bootloader with C:\Users\theck\Documents\mbed\blinky\bootloader/mdot-bootloader_v0.1.6-11-gd087115.bin
  Filling region application with .\BUILD\MTS_MDOT_F411RE\GCC_ARM\blinky_application.bin
Space used after regions merged: 0x1cbb0
Merging Regions
  Filling region application with .\BUILD\MTS_MDOT_F411RE\GCC_ARM\blinky_application.bin
Space used after regions merged: 0xcbb0

ARMC6 compiler output

Building project blinky (MTS_MDOT_F411RE, ARMC6)
Scan: blinky
Scan: mts-mbed-os
Using ROM regions bootloader, application in this build.
  Region bootloader: size 0x10000, offset 0x8000000
  Region application: size 0x70000, offset 0x8010000

..

Elf2Bin: blinky
Merging Regions
  Filling region bootloader with C:\Users\theck\Documents\mbed\blinky\bootloader/mdot-bootloader_v0.1.6-11-gd087115.bin
  Filling region application with .\BUILD\MTS_MDOT_F411RE\ARMC6\blinky_application.bin
Space used after regions merged: 0x186e4
Merging Regions
  Filling region application with .\BUILD\MTS_MDOT_F411RE\ARMC6\blinky_application.bin
Space used after regions merged: 0x86e4

IAR compiler output

Building project blinky (MTS_MDOT_F411RE, IAR)
Scan: blinky
Scan: mts-mbed-os
Using ROM regions bootloader, application in this build.
  Region bootloader: size 0x10000, offset 0x8000000
  Region application: size 0x70000, offset 0x8010000

...

Link: blinky
Elf2Bin: blinky
Merging Regions
  Filling region bootloader with C:\Users\theck\Documents\mbed\blinky\bootloader/mdot-bootloader_v0.1.6-11-gd087115.bin
  Filling region application with .\BUILD\MTS_MDOT_F411RE\IAR\blinky_application.bin
Space used after regions merged: 0x1895c
Merging Regions
  Filling region application with .\BUILD\MTS_MDOT_F411RE\IAR\blinky_application.bin
Space used after regions merged: 0x895c

Reviewers


@ciarmcom ciarmcom requested a review from a team May 4, 2020 21:00
@ciarmcom
Copy link
Member

ciarmcom commented May 4, 2020

@theckmts, thank you for your changes.
@ARMmbed/mbed-os-maintainers please review.

@0xc0170
Copy link
Contributor

0xc0170 commented May 5, 2020

@theckmts this targets 5.15 due to master cleanup (target present only on 5.15) ?

@theckmts
Copy link
Contributor Author

theckmts commented May 6, 2020

@0xc0170 The intention is to get this change into a release of 5.15. Changes to our library for MDot/XDot require changing the bootloader and we'd prefer to target 5.15 for now and update our library to target mbed-os 6 later.

If I set this to PR to target the wrong branch, please let me know what I should have done. Thanks.

@0xc0170
Copy link
Contributor

0xc0170 commented May 7, 2020

Understood, thanks ! I'll mark it as 5.15.4

@0xc0170 0xc0170 requested a review from andypowers May 7, 2020 13:39
Copy link
Contributor

@0xc0170 0xc0170 left a comment

Choose a reason for hiding this comment

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

Changes look fine to me. I'll need to although now find out what it means this tools update to the next release

@mergify mergify bot added needs: CI and removed needs: review labels May 7, 2020
@0xc0170
Copy link
Contributor

0xc0170 commented May 8, 2020

CI started

@mbed-ci
Copy link

mbed-ci commented May 8, 2020

Test run: SUCCESS

Summary: 11 of 11 test jobs passed
Build number : 1
Build artifacts

@0xc0170
Copy link
Contributor

0xc0170 commented May 11, 2020

Looking at the scope for this, this is not a bugfix that could go into 5.15 branch.

cc @maclobdell lets discuss this one

@theckmts
Copy link
Contributor Author

We're currently working on integrating with mbed-os-6.0.0-beta-1 which already has the changes needed for our next release. I'll close this PR once we're confident with the integration. These changes will no longer be needed if mbed-os-6 works for us.

@maclobdell
Copy link
Contributor

@theckmts - after you have tested it with master (aka Mbed 6) can you make a PR to the master branch?

@theckmts
Copy link
Contributor Author

theckmts commented Jun 2, 2020

Changes for mbed-os 6 were merge in 12765.

We've moved to using mbed-os 6 so this PR is no longer needed and can be closed.

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.

5 participants