AnsweredAssumed Answered

Trouble with AN2295 bootloader on Kinetis K20

Question asked by Rick Ball on Jul 5, 2013
Latest reply on Sep 30, 2015 by Harsh Patel

I'm trying to use the 'Developer's Serial Bootloader' (Version 12, dated 9/2012) with a Kinetis MK20DX128VLH5 MCU on a custom board.

 

I've managed to get it to communicate over the serial port, but it reports some warnings with the ID/protocol, and then fails to program the flash.

 

The application it's trying to flash has been modified as suggested in the AppNote, by moving the flash base from 0 to 0x1000 (first protection block past the bootloader).

 

Here are the messages (with problems highlighted):

 

------------------------------------------------------------------------------

hc08sprg - Developer's HC/S08/CFV1/V2/Kinetis Serial Bootloader

$Version: 10.0.12.0$

------------------------------------------------------------------------------

FC protocol versions supported:

        0x01 (HC08)

        0x03 (large HC08)

        0x02 (S08)

        0x06 (long S08)

        0x0A (large S08)

        0x04 (ColdFire)

        0x08 (Kinetis)

------------------------------------------------------------------------------

 

Parsed S-record lines: 702  Bytes total: 53024

Source address range: 0x1000-0xDF2F

 

Waiting for HC(S)08/ColdFire/Kinetis reset ACK (timeout: 8s)...received 0xfc (good).

WARNING! The protocol version [0x08] (Kinetis) does not match the one associated

with the device with following SDID [0x015].

Protocol version for given SDID should be [0x02] (S08).

Continuing with reported protocol version anyway.

Something is screwed up, please report!

Bootloader protocol version: 0x08 (Kinetis, read command supported,

Protocol secured: CRC-CCITT)

Bootloader version string: K20

System device ID: 0x015 [MC9S08RA16] rev. 1

Kinetis Package: 64-pin .

Number of memory blocks: 1

Memory block #1: 0x00001000-0x0000FFFF

Erase block size: 2048 bytes

Write block size: 128 bytes

Original vector table: 0x00000000-0x000003FF

New vector table: 0x00001000-0x000013FF

The S19 image also contains redirected vectors. The automatic redirection is skipped now.

Are you sure to program part? [y/N]: y

Memory is erased.

Memory programming block 0: W 0x00001000 0%

Can't program block 0 at address 0x00001000

Program memory failed.

 

Has the bootloader been tested with this K20 part? I checked the datasheet, and it looks like 0x0015 is the correct ID for the part, but maybe it also applies to the older MC9S08RA16 device?


Any suggestions for how to find/fix the problem?


Thanks,


Rick Ball

Outcomes