Skip to content

Specific notes for Nordic Semiconductors chips

nRF5 SDK

MiraOS is built with nRF5 SDK v15.2

SoftDevice

MiraOS is available in variants with and without SoftDevice. The version used is 6.1.1

The variants with SoftDevice handle the start of SoftDevice, as well as all radio events. BLE events are provided by a MiraOS API, see concurrent Bluetooth.

Access other events through the Nordic Semiconductor's SDK, see nrf_sdh_soc.h file.

Example

    #include "nrf_sdh_soc.h"

    static void evt_receiver(uint32_t evt_id, void *p_context)
    {
        // Handle events here
    }

    NRF_SDH_SOC_OBSERVER(m_sd_evt_receiver, 0, evt_receiver, &ctx);

Used ABI

MiraOS 2.4.0 and later uses the ARM EABI ABI, earlier versions used the VFP ABI. The FPU is also turned off by default to save power.

To use hardware floating point, use the -mfloat-abi=softfp flag to gcc and turn on the FPU during startup:

    SCB->CPACR |= (3UL << 20) | (3UL << 22);

Please read ARM's documentation about the CPACR register.