mbed-os-6.0.0-alpha1
Pre-releaseWe are pleased to announce the Mbed OS 6.0.0-alpha-1 release is now available.
Summary
This is our first engineering preview of Mbed OS 6.0 focusing on general cleanup and bug fixes. It contains everything that we worked on since December and was deemed ready to merge to master. Please note that this release intentionally breaks compatibility with Mbed OS 5 series. To find out more details please have a look at sections below.
Migration Guide
This section lists specific changes which are part of this release and may need special attention.
Cellular: Move string_to_pdp_type method to CellularContext
Summary of changes
string_to_pdp_type
is only used in CellularContext
classes and by having the conversion method in CellularContext it can be used also to check the non-standard Non-IP PDP type string.
Impact of changes
Migration actions required
Classes derived from CellularContext must implement new function:
virtual const char *get_nonip_context_type_str() = 0;
This API has already been implemented in AT_CellularContext though, so current code does not change.
Blockdevice config changes to make it possible to run littlefs filesystem tests
Summary of changes
Moves BlockDevice configurations used by SystemStorage as BlockDevice defaults. This makes it possible to use the defaults to execute littlefs filesystem tests.
Adds SPIF/QSPIF/SPIFReduced- and SDBlockDevice specific app configs for making it possible to run the forementioned tests.
Impact of changes
none
Migration actions required
Thread: remove constructors deprecated in 5.1
Summary of changes
Remove the immediate-start constructors deprecated in Mbed OS 5.1.
Impact of changes
Code using the old constructors will no longer compile
Migration actions required
Code using immediate-start Thread
constructors must be changed to use the Thread::start
method.
Remove unsupported folder
Summary of changes
Mbed OS was carrying the unsupported
directory for a long time. The main reason was
to enable users to benefit from some form of USB stack. Now when there
is a proper implementation of USB stack in Mbed I think it's time for
unsupported to go. If any other functionality present in this
directory will be needed it'll need to be introduced in Mbed OS
properly.
Impact of changes
As the name suggest 'unsupported' directory was unsupported, but it was there that means our community was free to use any of the functionality present. So in theory it is breaking change, even if the code was never properly supported.
Migration actions required
Removed functionality was never supported and its use was not recommended. If you used USB device mode, please port your code to use the supported version from drivers directory. If you need any other features please consider contributing it properly to Mbed.
Cellular: Refactor cellular variable visibilities
Summary of changes
Cellular: Refactor cellular variable visibilities
- Earlier some variables were public even though used only internally
- Also refactored variables to the end of class definitions
- Removed duplicate _property_array from CellularDevice
- Changed _impl methods as protected
Impact of changes
This can potentially be a breaking change but at least currently none of the existing mbed-os cellular targets required any changes.
Migration actions required
If customer wants to use some cellular variable marked as private, they need to inform @ARMmbed/mbed-os-wan and we can review the case.
ATHandler refactoring
Summary of changes
As ATHandler is part of Cellular's public API it is now moved to /API folder
Also some functions and variables are refactored to be private/protected where applicable
Also virtual cmd_start() (and destructor) method(s) devirtualised because not needed.
Unittests updated to reflect changes
Impact of changes
As ATHandler is part of Cellular's public API it is now moved to /API folder
Also some functions and variables are refactored to be private/protected where applicable
Also virtual cmd_start() (and destructor) method(s) devirtualised because not needed.
Migration actions required
Visibility of some methods have been changed in ATHandler and should not cause any issues if those were not used (as they shouldn't have been).
Also if include path has been used correctly for ATHandler.h there are no cahnges needed
ONME-4433 SocketAddress::operator== should also check port
Summary of changes
Currently SocketAddress::operator== does not check port number. Adding this check can be considered as a breaking change. Now SocketAddress::operator== checks port also. All greentests and unitests was checked and fixed.
Impact of changes
N/A
Migration actions required
N/A
Expose target_offset and header_offset parameters in targets.json
Summary of changes
The app_offset and header_offset parameters have always been a part of the target configuration parameters. However, they were intercepted by the tools and never exposed to the application. The new FOTA (update client next generation) functionality requires these parameters in the code as well now. So this PR adds them to targets.json file. The only result of this PR is the addition of these two macros into the code.
Note that the tools already expose the macros APPLICATION_ADDR and HEADER_ADDR having the same values. However, these macros are only available when the application is built with the bootloader. If it isn't, these macros aren't available, hence this PR.
This change is required for new fota client.
Impact of changes
None
Migration actions required
None
Enabling small C library option and deprecating uARM toolchain
Summary of changes
- In Mbed-OS 2-region memory model, ARM Std and Microlib scatter files are common
more info on https://github.com/ARMmbed/mbed-os/blob/master/docs/design-documents/platform/memory-model/ram_memory_model.md,
so replaced ARM Std scatter file 1-region memory model with Microlib scatter file 2 region memory model. - Moved the "__aeabi_assert" function from Microlib boot code file to mbed_retarget file so that it can be available for both RTOS Microlib and bare metal to resolve the undefined symbol linker issue.
- Copied ARM Microlib boot code into ARM std boot code and guarded with __MICROLIB. This is required in order to build a RTOS application with Microlib.
- Added a new target config "supported_c_libs" in targets.json and build tools to check if the selected "default_lib" is supported for the selected toolchain. If not the build tool will raise an exception.
- Added the new test suite for testing the build tool changes for default_lib and supported_c_libs.
- PR changes tested with blinky and blinky bare metal examples and greentea bare metal tests run locally.
Impact of changes
With these changes, uARM toolchain is being deprecated.
Migration actions required
As uARM toolchain is deprecated, the user has to redefine a supported_c_libs configuration with "small" for arm toolchain on the target in targets.json to enable Microlib support like
"supported_c_libs": {
"arm": ["std", "small"],
"gcc_arm": ["std", "small"],
"iar": ["std"]
}
and change the scatter file to the 2-region memory model see more info.
Instead of -t uARM, use default_lib with "small" in mbed_app.json configuration for ARMC6 toolchain.
cmsis: remove arm math
Summary of changes
Not needed file, should be part of DSP. The functionality is part of the library provided
by CMSIS.
I would like to test this, for all devices. This header file should be removed in 6.0.0 as we do not provide DSP library. Thus I set this as Major update.
Fixes #12054
Impact of changes
Applications should use CMSIS DSP package. As the order of includes is not defined in our tools, this might cause an error - hard to tell which cmsis math header was actually included. The removed math header we used in this code base was much older version.
Migration actions required
Use CMSIS DSP release (not part of Mbed OS at the moment) - the header file cmsis math is included there.
SharedPtr: add nullptr constructor
Summary of changes
For consistency with std::shared_ptr
, and mbed::Callback
, and as a
potential optimisation aid, give SharedPtr
a distinct constructor for
nullptr
.
Impact of changes
- Optimise clearing by adding
nullptr
overload.
Migration actions required
- The added
nullptr
overload meansSharedPtr(NULL)
orSharedPtr(0)
will no longer work; users must useSharedPtr(nullptr)
orSharedPtr()
.
Add MBED_FALLTHROUGH attribute
Summary of changes
C++17 standardised [[fallthrough]]
for switch
statements to suppress compiler warnings. Provide access to it, or compiler-specific alternatives.
Impact of changes
MBED_FALLTHROUGH
attribute added to mbed_toolchain.h
- a portable equivalent for C++17's [[fallthrough]]
.
Migration actions required
None
NVStore: already deprecated implementation removed
Summary of changes
NVStore: already deprecated implementation removal
Impact of changes
People are adviced to use KVStore
Migration actions required
No migration path available.
Remove deprecated FunctionPointer class
Summary of changes
- Deprecated class
FunctionPointer
has been removed.
Impact of changes
- Any code using
FunctionPointer
will no longer compile.
Migration actions required
- Any remaining
FunctionPointer
users should switch toCallback
.
CellularBase/AT_CellularBase removal
Summary of changes
Removed CellularBase and AT_CellularBase from cellular stack and updated both code and unittests accordingly. Cellular drivers in Mbed OS have been updated.
APN lookup and SMS features are now disabled by default
Impact of changes
Earlier cellular device properties were handled in AT_CellularBase class and after this change they are handled now correctly in AT_CellularDevice class. The properties are always modem specific and must be therefore handled in AT_CellularDevice class which is common for all contexts using it.
CellularBase has been completely removed so those using must now switch to use CellularInterface instead.
Disabling SMS will save ~4,5kB and APN lookup about ~2kB
Migration actions required
Cellular modem drivers must be updated (done for targets in Mbed OS) by removing references to CellularBase.
CellularBase must be changed to CellularInterface if still in use. (was already typedef'ed so no other changes needed)
If SMS or APN lookup are needed by application, those needs to be enabled in mbed_app.json
(cellular.use-apn-lookup: true or cellular.use-sms: true)
Small fixes for SecureStore
Summary of changes
- SecureStore: Deinitialize also member TDBStorages on deinit()
- SecureStore: Validate internal RBP data first
- SecureStore: Don't use flags of corrupted data. Allow removing.
- SecureStore: Validate internal header size before using its values.
Impact of changes
N/A
Migration actions required
N/A
TDBStore refactoring
Summary of changes
TDBStore
does not anymore require Flash based block device.
Impact of changes
N/A
Migration actions required
N/A
Storage related test improvements and small fixes
Summary of changes
SlicingBlockDevice
does not anymore accept both parameters as zero, or size as zero. SlicingBlockDevice(block, 0,0)
used to create a block device that took up the whole block device. There is no sense on doing so, and if used like this, it has most probably been a programming error. Therefore the constructor now does MBED_ASSERT()
if both parameters, start
and stop
point to same value. Effectively this prevents creating a slice that has size of zero, or take the full block device.
Impact of changes
You cannot anymore create a SlicingBlockDevice that has size of zero, or take the full size of underlying block device.
Migration actions required
No migration required for code that uses SlicingBlockDevice as it is intended.
UnbufferedSerial: Introduce the class to replace RawSerial
Summary of changes
Add the UnbufferedSerial class to provide unbuffered I/O access.
It is intended to be used instead of RawSerial. See documentration section for more details.
Impact of changes
Migration actions required
MbedCRC and CRC HAL revisions (6.0 redo)
Summary of changes
The MbedCRC
class has been improved and optimised.
Impact of changes
There is now a global JSON configuration drivers.crc-table-size
controlling table usage, and individual uses can be size-optimised via template parameters. However some changes are backwards-incompatible:
Migration actions required
- The special-case handling of
POLY_32BIT_REV_ANSI
has been removed - the same result can be obtained viaPOLY_32BIT_ANSI
. - CRCs smaller than 8 bits now return results in the standard position at the bottom of the register - previously they were shifted with random bits at the bottom.
- The previous precomputed table for
POLY_16BIT_IBM
had errors - this has been corrected, but CRC results will be different from the previous software calculation (but will match any hardware calculation)
minimal-printf: Enable using a target configuration parameter
Summary of changes
Add ability to enable Minimal printf using configuration parammeter.
A new configuration parameter target.printf_lib
has been added to enable it.
Impact of changes
Convenient and familiar way to configure Mbed OS.
Migration actions required
N/A
Remove deprecated Callback methods
Summary of changes
Deprecated methods in Callback
removed.
Impact of changes
Some code that was generating deprecation warnings will no longer compile at all.
Migration actions required
- Replace construction using
Callback(arg, func)
with the reversedCallback(func, arg)
- Replace use of
attach
with simple assignment, such ascallback = func;
orcallback = { func, arg };
Add Getaddrinfo interface for multiple DNS adresses
Summary of changes
Impact of changes
Migration actions required
Known Issues
There are no new known issues with this release.
Contents
Ports for Upcoming Targets
Fixes and Changes
12256
Update psa binaries for 6.0.0-alpha1
12238
Minimal-printf: Fix wrapping of printf functions for the ARM compiler
12236
Fix baremetal build failures
12218
tests tickers: adapt ticker_interrupt_test() test case for high frequency tickers
12217
Nuvoton: Add DEVICE_USBDEVICE detection in usbd implementation
12216
Fix dl_channel tests
12215
Cellular: Implementation of virtual get_ip_address funtion in ublox-api
12214
Cellular: Move string_to_pdp_type method to CellularContext
12202
Increase MSI clock frequency when exiting deep sleep
12200
Minor fixes for peripheral pins on Dragonfly Nano
12196
LWIP: don't pbuf_free(NULL) on socket close
12195
Corrected PPP debug trace flagging
12194
Nanostack Socket event handler fix
12193
Cellular: Move cellular event queue thread ownership to CellularDevice
12189
Removed hardcoded CY8CPROTO_062_4343W bt baudrate limit.
12188
Greentea test :Added the print in the exception handler
12186
STM serial init: Set pin function only if pin is defined (not NC)
12185
BLE: fix pointer not set to null on delete
12182
Update watchdog tests to run with bare metal profile
12181
Add DTLS in Connectivity's design document
12179
TESTS: Update testing of examples in mbed-os
12178
Fixes for LPC55S69_NS TLS tests
12176
Nuvoton: Support usbd
12175
Minimal-printf: Fix documentation as floating point is disabled by default
12173
Change size embedded in the temp_ram_page_data
12170
Nuvoton: Support dynamic heap configuration on IAR
12169
syntax error corrections - rm unnecessary semicolons
12167
Update Cypress Targets and Assets
12164
Pr dev/remove hardcoded timeout in cypress bt code
12162
CMSIS-pack update for STM32WB-family
12155
LPC11U24: Fix baremetal build and runtime error
12151
NRF5x: Fix baremetal linker error
12144
NRF52840: Use 2 region memory model for the ARM toolchain
12143
Blockdevice config changes to make it possible to run littlefs filesystem tests
12141
Thread: remove constructors deprecated in 5.1
12138
TESTS-MBED_HAL-COMMON_TICKERS no more executed
12133
Cellular: Suppress long AT traces
12132
LWIP: Remove unused MBOX configs
12131
Cellular: Fix Gemalto/Cinterion driver
12128
Remove unsupported folder
12123
Cellular: Refactor cellular variable visibilities
12122
ATHandler refactoring
12121
Serial: Deprecate the class and promote UnbufferedSerial instead
12120
ONME-4433 SocketAddress::operator== should also check port
12118
Fixed Serial ambiguity for enable_input and enable_output
12114
Cellular: Fix to not use all zero address for DNS
12113
Fix for issue #12104 (STM32 can_init_freq() ignores frequency)
12111
Microlib: Disable feof function usage in general filesystem test
12110
Moved CP Max recv len into mbed_lib.json
12109
Replace RawSerial as it has been deprecated
12108
Wi-sun network event handler update
12101
Bare metal: Retrieve error context after crash
12099
Implemented recommended fix from https://github.com/STMicroelectronic
12098
Wrong order of code fixed
12097
cypress target: fix iar warnings
12095
Update MXRT1050 to SDK 6.0
12092
Refactored away onboard_modem_api because it is not needed at all
12089
Update offloaded TLSSocket to TLSSocket design
12088
Cellular: Fix AT command for COPS manual network selection
12086
TARGET_STM: fix flash api 64bit address alignment on L4 and WB
12085
PSA setup template changes.
12083
Cellular: Add check for network congestion in BC95 driver
12081
Expose target_offset and header_offset parameters in targets.json
12080
Unittest cleanup made
12079
Coverity fixes
12078
Cellular: Add PPP/IP config flags in CellularInterface.json
12073
Unittests: fix for PRs 12051 and 11996
12071
Minimal Console: Use static pin map
12069
STM32: astyle update
12068
Enabling small C library option and deprecating uARM toolchain
12067
STM32 GPIO IRQ : add a critical section in gpio_irq_init
12065
Non-IP socket implementation for NIDD over CP
12064
Valgrind support added for unittests
12063
Move get_ip_address_if() to NetworkStack and include it in multihoming test
12061
NANO130: Support dynamic heap configuration on IAR
12057
NUC472/M487: Limit EMAC receive frame length as 1518
12055
cmsis: remove arm math
12052
fpga tests: clear uart fix
12051
Unittest configuration mechanism improved
12050
Fix TDBStore sizes for SecureStore tests
12048
SharedPtr: add nullptr constructor
12045
Netsocket test adjusted to Wisun
12044
increamed qspi size for cypress integration fs tests
12043
Modify itm_api.c for EFM32 targets
12041
Add QSPI and relevant test support for target EP_AGORA
12038
Cypress: Remove qspi_frequency() call.
12037
SharedPtr: add move operations
12034
SysTimer: Suppress implicit virtual warning
12032
Add MBED_FALLTHROUGH attribute
12029
STM32F0: create STM32F091xC target
12027
Modify nsapi_dns tests to be module tests
12026
Update HAL file to Toshiba's TMPM4G9
12025
Platform: Delete an unused astyle output file
12024
ONME-4366 - Fix UBLOX_EVK_ODIN_W2 fails in emac tests due to heap mem
12020
Fix issues in setting radio access technology
12019
Cypress: rework lptimer hal
12018
STM32_EMAC cleanup
12017
NVStore: already deprecated implementation removed
12013
Add UDP ECHOTEST with connect/send/recv calls
12012
USB device HID test: remove duplicated define
12011
STMOD_CELLULAR: improve debug print
12008
Cellular: Fix ATHandler string handling
11997
Remove deprecated FunctionPointer class
11996
CellularBase/AT_CellularBase removal
11995
MCU_NRF52840 target configuration fixes
11988
Small fixes for SecureStore
11987
TDBStore refactoring
11986
Storage related test improvements and small fixes
11980
DISCO_L4R9I: update clock configuration for all clock sources
11976
LWIP system mailbox overflow fix
11975
PPPinterface: remove faulty address getter check for invalid pointer
11962
Bug in mbed_alloc_wrappers.cpp
11961
UnbufferedSerial: Introduce the class to replace RawSerial
11957
MbedCRC and CRC HAL revisions (6.0 redo)
11952
Fix for Dragonfly nano and registration for LTE-M plans
11927
Speed up unittests by not limitting Make to spawn more processes
11920
Simplify pull request template headers and instructions
11897
MbedCRC: improve init value handling and tests
11891
minimal-printf: Enable using a target configuration parameter
11880
Remove deprecated Callback methods
11878
Improve API documentation and test coverage
11866
Update pycryptodome version
11817
ESP8266 "busy s..." fix (ONME-4352)
11653
Add Getaddrinfo interface for multiple DNS adresses
11594
M2351: Pre-build secure image/lib to favor pelion application
10959
M2351: Support TFM level 1
Using this release
You can fetch this release from the mbed-os GitHub repository, using the tag "mbed-os-6.0.0-alpha-1".
If you need any help with this release please visit our support page, which provides reference links and details of our support channels.