Freescale Semiconductor 802.15.4 manual Chapter Embedded Bootloader Public Function Description

Page 49

Chapter 7

Embedded Bootloader Public Function Description

This section describes the public functions which the 802.15.4/Zigbee application can call in the Embedded Bootloader.

7.1 802.15.4/Zigbee Application Accessible Functions

The following functions, located in the Embedded Bootloader, are made accessible for 802.15.4/Zigbee applications. For example, an 802.15.4/Zigbee application is not required to have programming routines to store NVM data in flash. A function pointer, for each function of the below listed functions, is defined in Embedded Bootloader.c:

Enable_Download_Firmware()

Hard_Reset()

NV_Flash_Setup()

Update_NV_RAM()

FL_ICG_Setup()

UART_Port_Select();

The Embedded_Bootloader.h file contains function pointer prototypes and must be included in source files calling these functions. The function pointers are setup to point to functions with the same name in the Embedded Bootloader.

extern Enable_Download_Firmware_ptr_t Enable_Download_Firmware; extern Hard_Reset_ptr_t Hard_Reset;

extern NV_Flash_Setup_ptr_t NV_Flash_Setup; extern Update_NV_RAM_ptr_t Update_NV_RAM; extern ICG_Setup_ptr_t FL_ICG_Setup;

extern UART_Port_Select_ptr_t UART_Port_Select;

7.1.1 Enable_Download_Firmware

Prototype:

bool_t Enable_Download_Firmware

(

uint8_t interface_state,

uint8_t firmware_state

)

Description:

The application must call this function to make the system ready for a new firmware download. The application must provide a way for the user to interact with the system to call this function.

Freescale Semiconductor

Embedded Bootloader Reference Manual, Rev. 0.0

7-1

Image 49
Contents 802.15.4/Zigbee Embedded Bootloader How to Reach Us USA/Europe/Locations Not Listed Contents Embedded Bootloader Programming Embedded Bootloader Public Function Description Audience Conventions References Target Chapter Embedded Bootloader DescriptionAxiom AXM-0308 Ported TargetsPotential Issues FeaturesBenefits Optional Firmware Upload Settings Upload Firmware Chapter Using the Embedded BootloaderUse Case One Use Case Two Safe Mode BootUpdating Non-volatile Memory NVM An Example of How to Change the MAC AddressUart Baud Rate System Bus FrequencyChapter Test Tool Zigbee Flash Tool Graphical User Interface GUI Version Using the Tools Menu OptionView Menu Option Using the View Menu OptionFirmware Upload Selecting the Firmware File to UploadAfter a Successful Firmware Upload Changing the NVM Data in Flash or File Using the Help MenuSystem Configuration Window Command Line Version Parameter List Command Line Version CMDFlash Erase Disabled Example Normal Use Example DefaultEmbedded Bootloader Reference Manual, Rev Programming To An Empty Erased Board Chapter Embedded Bootloader ProgrammingConnection Assistant Window Load Executable Window Status Window Upgrading The Embedded Bootloader Connection Assistant Window Programmer Expert Window S19 File Window Status Window Embedded Bootloader Reference Manual, Rev Chapter Application Integration Reference Guide Embedded Bootloader ImageProduct Deliverables Application Support FilesApplication Unreferenced SymbolsApplication Linker File Compiler DefinesApplication Support Files System Clock SetupDigiType.h 2 Gb60io.h3 Crt0.c and Crt.h NVData.c and NVData.h EmbeddedBootloader.h and EmbeddedBootloader.cISRVectors.c DummyIsr.c Chapter Port Integration Reference Guide Embedded Bootloader Build Environment1 HCS08 Compiler 2 HCS08 LinkerEmbeddedBootloaderFunctionalityLib.Lib EmbeddedBootloader.mcp2 HCS08FlashLib.Lib Source FilesCode and Data Segments Porting to a Specific TargetStandard Libraries Compiler #definesTarget.h Source FilesEmbeddedBootloaderTarget.h ResetVector.cHWInit.c HWInit.hMain.c 802.15.4/Zigbee Application Accessible Functions Chapter Embedded Bootloader Public Function DescriptionEnableDownloadFirmware Embedded Bootloader boot flag UpdateNVRAM HardResetFLICGSetup NVFlashSetupOutput None UARTPortSelectEmbedded Bootloader Reference Manual, Rev 128 Direct Port Registers Chapter Embedded Bootloader Memory Map1BFF 4BFF 4DFF 4FFF 8BFF 8DFF 8FFF Embedded Bootloader Reference Manual, Rev FFB0 Ffbf Cursive = fixed register and vectors in flash Embedded Bootloader Reference Manual, Rev Folder Structure Appendix a Release Folder and File StructureFile Structure EmbeddedBootloaderFunctionalityLib.Lib Functionality library Embedded Bootloader Reference Manual, Rev