Difference between revisions of "Infineon XMC1000"
(→Boot Mode Index (BMI)) |
|||
Line 3: | Line 3: | ||
This article describes device specifics of the Infineon XMC1000 microcontroller. |
This article describes device specifics of the Infineon XMC1000 microcontroller. |
||
== Boot Mode Index (BMI) == |
== Boot Mode Index (BMI) == |
||
− | The XMC1000 family supports different boot modes. The actual boot mode is configured in the Boot Mode Index (BMI) which is a 2 byte value stored in the flash and holding information about the boot mode (start-up mode) and the debug configuration of the device. |
+ | The XMC1000 family supports different boot modes. The actual boot mode is configured in the Boot Mode Index (BMI) which is a 2 byte value stored in the flash and holding information about the boot mode (start-up mode) and the debug configuration of the device. Depending on the configured boot mode, different debug pins are used for the debug communication. |
+ | === Problem === |
||
+ | The XMC1000 series devices are shipped with boot mode ''ASC Bootstrap Loader mode'' (ASC_BSL). Unfortunately, the debug interface of the device is disabled in this mode. So when using J-Link or Flasher, the boot mode needs to be changed prior a target connection can be established. |
||
+ | === Solution === |
||
+ | By default, the J-Link performs the switching sequence to ''SWD0'' (P0.14 & P015 used for SWD) if the BMI of the device is ASC_BSL. If a BMI other than SWD0 is required, the default behavior can be simply overwritten using a J-Link Script File. Please find below script files for the other boot modes: |
||
+ | *ASC_BSL to SWD1: [[:File:Infineon_XMC1000_PCode_SWD1.pex]] |
||
− | So what the J-Link software basically does as part of the XMC1000 connect sequence is to check if the device is in ASCL_BSL mode and if so, performs the switching sequence to ''SWD0'' (P0.14 & P0.15 used for SWD) as this configuration is used by 90% of our customers. However, some customers may want to use a different BMI mode (BMI mode != SWD0) like for example SWD1, SPD0 or SPD1. For those customers, a special connect sequence is required which switches the BMI mode to the desired one instead of SWD0. In this case, please get in contact with SEGGER directly (e.g. via E-Mail / forum). |
||
+ | *ASC_BSL to SPD0: [[:File:Infineon_XMC1000_PCode_SDP0.pex]] |
||
+ | *ASC_BSL to SPD1: [[:File:Infineon_XMC1000_PCode_SDP1.pex]] |
||
+ | |||
+ | Please note that the J-Link Script Files are pre-compiled (*.pex) thus they neither contain plaintext nor can be modified. If you feel that you need a modified version of the script file, please get in contact with SEGGER directly (e.g. via E-Mail / forum). For further information how to use the J-Link Script File in your environment please refer to https://wiki.segger.com/Using_J-Link_Script_Files |
||
+ | |||
+ | === NOTE === |
||
+ | #The required switching sequence needs to be performed over a half-duplex UART communication on the TMS/SWDIO pin (Pin7) thus this pin needs to be connected to be able to change the BMI |
||
+ | #The bootstrap loader of the XMC1000 becomes confused if invalid / incorrect data have been sampled. To prevent unexpected behavior, we recommend to perform a power-on-reset of the target before establishing a connection using J-Link |
||
+ | |||
+ | |||
+ | |||
+ | === Overview BMI Modes === |
||
+ | The table below represents the available boot mode index (BMI) configurations |
||
− | The table below represents the available boot mode configurations. |
||
{| class="wikitable" |
{| class="wikitable" |
||
|+Boot Mode overview |
|+Boot Mode overview |
Revision as of 12:26, 20 February 2018
This article describes device specifics of the Infineon XMC1000 microcontroller.
Boot Mode Index (BMI)
The XMC1000 family supports different boot modes. The actual boot mode is configured in the Boot Mode Index (BMI) which is a 2 byte value stored in the flash and holding information about the boot mode (start-up mode) and the debug configuration of the device. Depending on the configured boot mode, different debug pins are used for the debug communication.
Problem
The XMC1000 series devices are shipped with boot mode ASC Bootstrap Loader mode (ASC_BSL). Unfortunately, the debug interface of the device is disabled in this mode. So when using J-Link or Flasher, the boot mode needs to be changed prior a target connection can be established.
Solution
By default, the J-Link performs the switching sequence to SWD0 (P0.14 & P015 used for SWD) if the BMI of the device is ASC_BSL. If a BMI other than SWD0 is required, the default behavior can be simply overwritten using a J-Link Script File. Please find below script files for the other boot modes:
- ASC_BSL to SWD1: File:Infineon_XMC1000_PCode_SWD1.pex
- ASC_BSL to SPD0: File:Infineon_XMC1000_PCode_SDP0.pex
- ASC_BSL to SPD1: File:Infineon_XMC1000_PCode_SDP1.pex
Please note that the J-Link Script Files are pre-compiled (*.pex) thus they neither contain plaintext nor can be modified. If you feel that you need a modified version of the script file, please get in contact with SEGGER directly (e.g. via E-Mail / forum). For further information how to use the J-Link Script File in your environment please refer to https://wiki.segger.com/Using_J-Link_Script_Files
NOTE
- The required switching sequence needs to be performed over a half-duplex UART communication on the TMS/SWDIO pin (Pin7) thus this pin needs to be connected to be able to change the BMI
- The bootstrap loader of the XMC1000 becomes confused if invalid / incorrect data have been sampled. To prevent unexpected behavior, we recommend to perform a power-on-reset of the target before establishing a connection using J-Link
Overview BMI Modes
The table below represents the available boot mode index (BMI) configurations
BMI | Description |
---|---|
ASC Bootstrap Load Mode (ASC_BSL) | Factory default half-duplex UART |
User Mode (Productive) | |
User Mode (Debug) SWD0 | P0.14 & P0.15 used for SWD |
User Mode (Debug) SWD1 | P1.3 & P1.2 used for SWD |
User Mode (Debug) SPD0 | P0.14 used for SPD |
User Mode (Debug) SPD1 | P1.3 used for SPD |
User Mode (HAR) SWD0 | P0.14 & P0.15 used for SWD |
User Mode (HAR) SWD1 | P1.3 & P1.2 used for SWD |
User Mode (HAR) SPD0 | P0.14 used for SPD |
User Mode (HAR) SPD1 | P1.3 used for SPD |
For further information regarding the BMI, please refer to the technical reference manual of the Infineon XMC1000 series.