See Standalone for detailed documentation.

License#

Copyright 2018 Silicon Laboratories Inc. www.silabs.com

The licensor of this software is Silicon Laboratories Inc. Your use of this software is governed by the terms of Silicon Labs Master Software License Agreement (MSLA) available at www.silabs.com/about-us/legal/master-software-license-agreement. This software is distributed to you in Source Code format and is governed by the sections of the MSLA applicable to Source Code.

/***************************************************************************/
#ifndef __STANDALONE_BOOTLOADER_H__
#define __STANDALONE_BOOTLOADER_H__


void bootloaderMenu(void);


BL_Status receiveImage(uint8_t commState);

bool checkDebugMenuOption(uint8_t ch);

BL_Status initOtaState(void);

BL_Status checkOtaStart(void);

BL_Status receiveOtaImage(void);

bool paIsPresent(void);

bool halCheckIntegrity(void);

#endif //__STANDALONE_BOOTLOADER_H__

Required Custom Functions#

void

This function must be implemented, providing a bootloader menu.

Available Bootloader Library Functions#

Functions implemented by the bootloader library that may be used by custom functions.

receiveImage(uint8_t commState)

Puts the bootloader into a mode where it will receive an image. commState indicates whether the image is received via serial (COMM_SERIAL) or over the air (COMM_RADIO)

bool

A hook to the bootloader library for it to check for extra menu options. Only used for ember internal debug builds, not normally needed.

Initialize OTA Bootloader state.

Check to see if the bootloader has detected an OTA upload start.

Puts the bootloader into a mode where it will receive an image over the air. The function checkOtaStart() should have been called first and it should have returned with a status of BL_SUCCESS before calling this function.

bool

Uses the information in the PHY_CONFIG token to determine if a power amplifier is present in the node design.

bool

Validate application integrity by running AES-MMO hash and comparing to AAT.

Required Custom Functions Documentation#

bootloaderMenu#

void bootloaderMenu (void )

This function must be implemented, providing a bootloader menu.

Parameters
N/A

Definition at line 35 of file /Users/vihuszar/Git/EmbeddedSoftware/super/platform/base/hal/micro/cortexm3/common/standalone-bootloader.h

Available Bootloader Library Functions Documentation#

receiveImage#

BL_Status receiveImage (uint8_t commState)

Puts the bootloader into a mode where it will receive an image. commState indicates whether the image is received via serial (COMM_SERIAL) or over the air (COMM_RADIO)

Parameters
N/AcommState

Definition at line 51 of file /Users/vihuszar/Git/EmbeddedSoftware/super/platform/base/hal/micro/cortexm3/common/standalone-bootloader.h

checkDebugMenuOption#

bool checkDebugMenuOption (uint8_t ch)

A hook to the bootloader library for it to check for extra menu options. Only used for ember internal debug builds, not normally needed.

Parameters
N/Ach

Returns

  • true if the option was handled, false if not.


Definition at line 58 of file /Users/vihuszar/Git/EmbeddedSoftware/super/platform/base/hal/micro/cortexm3/common/standalone-bootloader.h

initOtaState#

BL_Status initOtaState (void )

Initialize OTA Bootloader state.

Parameters
N/A

Note

  • OTA support hooks are subject to change!

Returns


Definition at line 65 of file /Users/vihuszar/Git/EmbeddedSoftware/super/platform/base/hal/micro/cortexm3/common/standalone-bootloader.h

checkOtaStart#

BL_Status checkOtaStart (void )

Check to see if the bootloader has detected an OTA upload start.

Parameters
N/A

Note

  • OTA support hooks are subject to change!

Returns


Definition at line 72 of file /Users/vihuszar/Git/EmbeddedSoftware/super/platform/base/hal/micro/cortexm3/common/standalone-bootloader.h

receiveOtaImage#

BL_Status receiveOtaImage (void )

Puts the bootloader into a mode where it will receive an image over the air. The function checkOtaStart() should have been called first and it should have returned with a status of BL_SUCCESS before calling this function.

Parameters
N/A

Note

  • OTA support hooks are subject to change!

Returns


Definition at line 82 of file /Users/vihuszar/Git/EmbeddedSoftware/super/platform/base/hal/micro/cortexm3/common/standalone-bootloader.h

paIsPresent#

bool paIsPresent (void )

Uses the information in the PHY_CONFIG token to determine if a power amplifier is present in the node design.

Parameters
N/A

Note

  • This function must not be called before emBootloaderRadioBoot().

Returns

  • true if a power amplifier is present, false otherwise.


Definition at line 91 of file /Users/vihuszar/Git/EmbeddedSoftware/super/platform/base/hal/micro/cortexm3/common/standalone-bootloader.h

halCheckIntegrity#

bool halCheckIntegrity (void )

Validate application integrity by running AES-MMO hash and comparing to AAT.

Parameters
N/A

Returns

  • false if fails integrity check, true if pass


Definition at line 98 of file /Users/vihuszar/Git/EmbeddedSoftware/super/platform/base/hal/micro/cortexm3/common/standalone-bootloader.h