Bootloader Host Error: “The Flash Row is not Valid for the Selected Array” - KBA221445

Version 15

    Version: *A


    Translation - Japanese: ブートローダーホスト エラー:“The Flash Row is not Valid for the Selected Array” について- KBA221445- Community Translated (JA)



    How to resolve "The flash row is not valid for the selected array" error in the Bootloader Host for PSoC® 3, PSoC 4, or PSoC 5LP bootloader designs?



    This error appears when the Bootloader Host application attempts to bootload the bootloader area of flash or portion of memory that is Write-protected. Unless specified, a bootloadable application starts at the next empty flash row to the dependent bootloader application. If there is a conflict between the pre-programmed bootloader regarding the bootloader flash area or flash row protection settings, bootloading will not be allowed.

    For example, consider a product on field with a bootloader programmed (say, Bootloader A). Assume you are updating the build with the latest version of PSoC Creator Components. Let us call the updated bootloader as Bootloader B. Now, if a new bootloadable is built with the .hex and .elf dependency to Bootloader B, you may face the invalid flash row error while bootloading the new application on the field. This may be because of these reasons:

    1. Bootlader B may consume less flash rows, but the preprogrammed Bootloader A occupies more flash rows. So, the new .cyacd file is attempting to bootload the pre-programmed bootloader rows, which is not allowed.
    2. More rows of Booloader A may have been “Write Protected” compared to the actual number of rows used by Booltoader B. In that case, the new .cyacd file is attempting to bootload protected rows.

    Note that any functional modifications in Bootloader B (compared to A) will not be reflected in the actual application even if Bootloader B is set as a dependency. This is because Booltoader B is not reprogrammed to the device.

    Figure 1: PSoC Creator Projects and Flash Memory Usage

    To address this issue, you can manually place the bootloadable application to any flash row above the bootloader image and below the metadata area of flash as shown in Figure 1. This approach can be used to avoid flash consumption discrepancies between an older/newer revision of dependency files and in the presence of flash row protection settings. The steps are as follows:


    1. In the Bootloadable configuration settings (Configure dialog), enable the Manual application image placement option. Unless enabled, the Placement address option will be grayed out. Refer Figure 2.
    2. Specify the address in the Placement address field such that the address is above the bootloader image on the device and below the metadata area. To determine the placement address, add product of flash row number and the flash row size, with the flash base address. Ensure to align the placement address to the flash row size. See the Flash and EEPROM chapter of the System Reference Guide for details about flash memory organization.


    Figure 2: Manual Application Placement Option in Bootloadable Configuration


    Bootloader and Bootloadable

    AN73854 - PSoC® 3, PSoC 4, and PSoC 5LP Introduction to Bootloaders

    PSoC® 3, PSoC 4, and PSoC 5LP Flash Memory Organization and Array ID Parameter - KBA84740