Jlink ColdFire MCF52259 programming error

  • Jlink ColdFire MCF52259 programming error

    I have a device with MCF52259 microcontroller. I get a block verification error when trying to program Coldfire MCF52259 with Jlink CF. And the device is not working as expected (it hangs at startup) after programming. The block verification error occurs only in address 0x00013000.

    If I trick the Jlink by telling that target device is MCF52256 and using the same binary file, no errors occur and device works as expected.

    After programming I have read CPU flash memory using Jlink and checked that block starting from address 0x00013000 is different than in my binary file. And again if I have used MCF52256 target during programming, the block from 0x00013000 is correct.

    Here is the Jlink script log which I am using...
    ----
    Script file read successfully.
    Processing script file...

    Connecting to J-Link via USB (Port: 0)
    DLL version V4.00c, compiled Dec 19 2008 19:57:22
    Firmware: J-Link CF V1 compiled Sep 06 2007 09:32:25
    Hardware: V1.00
    S/N : xxxxxxx50
    OEM : IAR
    VTarget = 3.300V
    Speed: 30 kHz

    Info: Coldfire V2 Rev.0, ISA_A+, DEBUG_B+, Engines: EMAC,DIV
    Speed: 1000 kHz

    PC = 0000190C, SR = 2708 (SVC mode, I-State, IMask=7)
    D0 = CF206489, D1 = 10B01080, D2 = 0000ACC2, D3 = 0000ACC3
    D4 = 000ACE01, D5 = 000ACE23, D6 = FFFF0000, D7 = 00000000
    A0 = 20000000, A1 = 0000ACC2, A2 = 5AA5A55A, A3 = 5AA5A55A
    A4 = FFFFFFEC, A5 = 20000004, A6 = FFFFFFFF, A7 = 1F701EA0
    USP = 1F701EA0, SSP = 1F701EA0, VBR = 000001DC

    MACSR = 00000000, MASK = FFFF0000
    ACC0 = 0000ACC0, ACC1 = 0000ACC1, ACCext01 = 000ACE01
    ACC2 = 0000ACC2, ACC3 = 0000ACC3, ACCext23 = 000ACE23

    Loading binary file... [CPU.bin]
    Writing bin data into target memory @ 0x00000000.

    Info: Coldfire V2 Rev.0, ISA_A+, DEBUG_B+, Engines: EMAC,DIV

    ****** Error: Programming failed @ address 0x00013000 (block verification error)

    Info: Coldfire V2 Rev.0, ISA_A+, DEBUG_B+, Engines: EMAC,DIV
    Script processing completed.
    ----

    What could be a problem?