Similar commit to this one:
6e56e6269f
When .text + .data oveflow available flash, the linker may not show an
error. This change makes sure .data is included in the size calculation.
This frees 128 bytes of .bss RAM on the nRF51, at the cost of possibly
more expensive GC cycles. Leave it as-is on the nRF52 as that chip has a
lot more RAM.
This is also done in the micro:bit:
a7544718a7/inc/microbit/mpconfigport.h (L6)
* ports/nrf/boards: Adding linker script for nrf52832 using BLE stack s132 v.5.0.0.
* ports/nrf/drivers/bluetooth: Updating makefile to add BLE_API_VERSION=4 if s132 v5.0.0 is used.
* ports/nrf/drivers/bluetooth: Updating BLE stack download script to also download S132 v5.0.0.
* ports/nrf/drivers/bluetooth: Updating ble_drv.c to handle BLE_API_VERSION=4 (s132 v5.0.0).
* ports/nrf/boards: Updating linker script for nrf52832 with s132 v.5.0.0 bluetooth stack.
* ports/nrf/drivers/bluetooth: Removing commented out code in ble_drv.c
* ports/nrf/drivers/bluetooth: Updating define of GATT_MTU_SIZE_DEFAULT for SD132v5 to be defined using the new name defined in the SD headers in a more generic way.
* ports/nrf/drivers/bluetooth: Cleaning up use of BLE_API_VERSION in the ble_drv.c. Also considering s140v6 API, so not all has been changed to >= if API version 3 and 4 in combo is used. New s140v6 will differ on these, and add a new API not compatible with the API for 3 and 4.
- Rename microbit_module_init to board_module_init0 which is the generic
board module init function.
- Add low priority callback registration of display tick handler in the
module init function.
- Rename init function to ticker_init0.
- Implement ticker_register_low_pri_callback (recycle of unused
set_low_priority_callback function which was unimplemented).
- Add support for registering 2 low pri callbacks. For now, one intended
for microbit display, and one for modmusic.
* ports/nrf: Add micro:bit filesystem.
This filesystem has been copied from BBC micro:bit sources [1] and
modified to work with the nRF5x port.
[1]: https://github.com/bbcmicrobit/micropython/blob/master/source/microbit/filesystem.c
* ports/nrf/modules/uos: Make listdir() and ilistdir() consistent.
This removes the optional direcotry paramter from ilistdir(). This is
not consistent with VFS, but makes more sense when using only the
microbit filesystem.
Saves about 100 bytes.
* ports/nrf/modules/uos: Add code size comment.
* Remove FLASH_ISR and merge .isr_vector into FLASH_TEXT. This saves
some code space, especially on nRF52 devices.
* Reserve space for nonvolatile storage of data. This is the place for
a filesystem (to be added).
The patch enables the possibility to disable or initialize the repl
info from outside of the module. Can also be used to initialize the
repl_display_debugging_info in pyexec.c if not startup file is clearing
.bss segment.