This document introduces a method to use USB User Bootloader, and offers an easy way to develop the ABOV 32-bit Cortex-M0x MCUs. By reading through this document, you will learn how to operate A31G32x USB User Bootloader with examples, step by step.
2. User requirements A31G32x USB Bootloader quick guide System requirements Windows PC (7, 8, 10) USB mini-B type cable Figure 5. Window PC & Mini-B Cable ABOV website For detailed information about corresponding software and documents, you can visit our website at https://www.abovsemi.com.
A31G32x USB Bootloader quick guide 3. User Bootloader environment & concept User Bootloader environment & concept Figure 7. User Bootloader Environment and Concept ① Bootloader Project makes Boot code file in Keil environment. ② The application project has user code and boot code generated from the boot project.
Flash Memory area Division BOOT ZONE ① Boot code storage area to rewrite APPLICATION ZONE ② Re-write Impossible ③ BOOT ZONE size : 4KB APPLICATION ZONE ① User code area ② Re-write possible through Boot code Figure 8. A31G32x Flash Memory Map...
A31G32x USB Bootloader quick guide 5. USB User Bootloader protocol USB User Bootloader protocol Outgoing packet definition Inline programmers take commands from the host to upgrade, inspect, and execute the program. Instructions of inline programmers have a defined data frame format, and the code used here is as follows: Table 1.
5. USB User Bootloader protocol A31G32x USB Bootloader quick guide Host command list In-line programmers have the following instructions for handling each action. Table 3. Operation Command Packet Description Description Remark RESET 0xA5 Reset MCU ERS_SN 0xE1 Erase internal flash sector...
A31G32x USB Bootloader quick guide 5. USB User Bootloader protocol 5.3.4 PGM_DB (Program Data Block) Description: Write the value written to the data buffer block to the designated flash address. Arguments: 32-bit (4 bytes) address + 32-bit (4 bytes) size (MSB First)
A31G32x USB Bootloader quick guide 7. User Bootloader project User Bootloader project Refer to “A31G32x_USB_user_bootloader” project. This project supports example source with a PC GUI tool and the USB User Bootloader. This section describes the detailed guide of the USB User Bootloader.
③ The bootcode hex file is converted into an array and made into one C file, where the C file name is the same as the hex file name. ④ Because we include bootcode.c in Project, use the same name for convenience. Figure 12. Example of A31G32x Keil Option for Target...
SCB->VTOR = 0x00001000; //Vector Table Offset Register bootcode.c ① Include C file converted from hex file to the Project (added to example project already). ② If there is a change in the bootloader project, update it. Figure 17. Add bootcode.c in Application Project – A31G32x...
A31G32x USB Bootloader quick guide Compiler Settings ① Set Application start address in IROM1 and Bootcode area in IROM2. ② Select the Hex file creation option (For use in UART downloader). Figure 18. Example of Setting Options for Target in Application Project – A31G32x...
A31G32x USB Bootloader quick guide 7. User Bootloader project ③ Set specific Address for Bootcode (Options for File ‘Bootcode.C’). Figure 19. Example of bootcode.c File Option in Application Project – A31G32x...
8. Example of User Bootloader for USB A31G32x USB Bootloader quick guide Example of User Bootloader for USB Building and running project Running application code makes it easier to start the Shield Board. To run the application code, follow the steps below: Step 1.
Pin Headers connected to MCU C. USB, switch and jumper to check input/output, reset, and debugger pins A-Link (CMSIS-DAP/UART) board configuration A-Link for programming and debugging with ABOV 32-bit MCU(connected to USB port of Supports UART. Figure 20. Starter Kit B/D...
8. Example of User Bootloader for USB A31G32x USB Bootloader quick guide Set up the Starter Kit 8.3.1 Set jumpers to control the Starter Kit To set up the Starter Kit, follow the procedure introduced below: The Starter Kit uses USB power-①.
A31G32x USB Bootloader quick guide 8. Example of User Bootloader for USB Connect the Starter Kit to your PC 8.4.1 PC connection via USB on the Starter Kit Connect the USB 2.0 (mini-B type) cable to the Starter Kit as shown in Figure 22.
8. Example of User Bootloader for USB A31G32x USB Bootloader quick guide Compile & firmware update as User Bootloader project 8.5.1 Run the Bootloader project Before downloading the Bootloader example, Keil uVision5 for ARM must be installed on your PC.
A31G32x USB Bootloader quick guide 8. Example of User Bootloader for USB 8.5.2 Compiling the Bootloader & application project Execute “Rebuild all target files” on the created uVision5 (User Bootloader for USB Project). Select Rebuild (①) to proceed with compilation.
8. Example of User Bootloader for USB A31G32x USB Bootloader quick guide 8.5.3 Download the Bootloader If the compilation finishes without error, you can begin programming the starter kit. Check the following in case of errors in settings. Check that CMSIS-DAP Debugger (①) is selected in the Debug tab (use CMSIS-DAP for A-Link).
A31G32x USB Bootloader quick guide 8. Example of User Bootloader for USB 8.5.4 Update firmware as USB User Bootloader In this section, you can learn how to update firmware via USB. The starter kit board is comprised of a device board and the USB modules.
8. Example of User Bootloader for USB A31G32x USB Bootloader quick guide After setting the device, turn on the power. The device enters the boot mode for USB communication. See Figure 29. Run QuickWriter (PC tool) for USB. There are 3 programs for Supporting Virtual com port, HID full-speed, and HID low speed.
A31G32x USB Bootloader quick guide 8. Example of User Bootloader for USB 8.5.5 Check the updated application operation In this section, you can check the application operation (downloaded using the USB bootloader): To enter the application, PF1 pin (user define) is low level, and then reset the device.
Revision history A31G32x USB Bootloader quick guide Revision history Date Version Description 20.12.04 1.00 Document created...
Page 33
ABOV Semiconductor ("ABOV") reserves the right to make changes, corrections, enhancements, modifications, and improvements to ABOV products and/or to this document at any time without notice. ABOV does not give warranties as to the accuracy or completeness of the information included herein. Purchasers should obtain the latest relevant information of ABOV products before placing orders.