I'm having this an issue programming an MK10DX256VLK7. I've had
no such problems with the MK10DN512ZVLK10. The log is attached.
Any ideas what I should be looking at?

Thanks,
- Alex

 -------------------------- output -------------------------- 
$ openocd -f interface/busblaster.cfg -f program.cfg 
Open On-Chip Debugger 0.6.0-dev-00575-g9f55daa (2013-02-27-17:50)
Licensed under GNU GPL v2
For bug reports, read
        http://openocd.sourceforge.net/doc/doxygen/bugs.html
Info : only one transport option; autoselect 'jtag'
3000 kHz
trst_and_srst separate srst_gates_jtag trst_push_pull srst_open_drain
Info : add flash_bank kinetis k10.pflash
Info : max TCK change to: 30000 kHz
Info : clock speed 3000 kHz
Info : JTAG tap: k10.cpu tap/device found: 0x4ba00477 (mfg: 0x23b, part: 
0xba00, ver: 0x4)
Polling target failed, GDB will be halted. Polling again in 100ms
Info : JTAG tap: k10.cpu tap/device found: 0x4ba00477 (mfg: 0x23b, part: 
0xba00, ver: 0x4)
Info : k10.cpu: hardware has 6 breakpoints, 4 watchpoints
---Device detected, Trying reset.
Info : JTAG tap: k10.cpu tap/device found: 0x4ba00477 (mfg: 0x23b, part: 
0xba00, ver: 0x4)
target state: halted
target halted due to debug-request, current mode: Thread 
xPSR: 0x01000000 pc: 0xfffffffe msp: 0xfffffffc
Polling succeeded again
---Device reset. Attempting to erase.
Info : Probing flash info for bank 0
Warn : flash configuration field erased, please reset the device
erased sectors 0 through 127 on flash bank 0 in 1.537945s
---Erase succeeded. Attempting to program.
Error: ftfx command failed FSTAT: A0 W0: 0B000000 W1: 01000000 W2: 00000000
Error: error writing to flash at address 0x00000000 at offset 0x00000000
---Programming failed.
shutdown command invoked
 -------------------------- program.cfg -------------------------- 
adapter_khz 3000

set CHIPNAME k10

source [find target/k40.cfg]

reset_config trst_and_srst

#
# Bank definition for the 'program flash' (instructions and/or data)
#
flash bank $_CHIPNAME.pflash kinetis 0x00000000 0x80000 0 4 $_TARGETNAME

jtag arp_init-reset

set FIRMFILE beta512.elf

if { [catch {init}] } {
    echo "---Device not detected."
} else {
    echo "---Device detected, Trying reset."
    if {[catch {reset halt}]} {
        echo "---Device not responding."
    } else {
        echo "---Device reset. Attempting to erase."

        if {[catch {flash erase_sector 0 0 127 } ] || 1 } {
            echo "---Erase succeeded. Attempting to program."
            if {[catch {flash write_image $FIRMFILE } ] } {
                echo "---Programming failed."
            } else {
                echo "---Done programming, Verifying."
                if {[catch { verify_image $FIRMFILE } ] } {
                    echo "---Verify failed. Reject."
                } else {
                    echo "---Verify succeeded. Done!"
                }
            }
        } else {
            echo "---Erase failed."
        }
    }
}
shutdown
 -------------------------- git info -------------------------- 
$ git merge-base HEAD origin/master
064475459bf869d5c722851fdfd22719ec0a3adc

$ git log 064475459bf869d5c722851fdfd22719ec0a3adc..HEAD
Author: Andreas Fritiofson <[email protected]>
Date:   Thu Jul 19 00:02:46 2012 +0200

    kinetis: bugfix in kinetis_write() fallback path
    
    Offset calculation into buffer was wrong and code would read outside buffer
    if count was not a multiple of four.
    
    Change-Id: Ied625b10221423d5a5f25d27ce1edd8c2c3eca8a

Author: Christopher Kilgour <[email protected]>
Date:   Sat Jul 7 16:47:06 2012 -0700

    kinetis: ensure flash writes are not truncated
    
    The number if longwords or "sections" (Freescale term) written for a Kinetis
    flash write (4, 8, or 16 bytes depending on the part density/granularity) 
are
    now rounded up to ensure there are no truncations when the desired write is
    not a multiple of the minimum write size.
    
    Change-Id: I8db40a8769d8ac5393a46cbf4e5ff0df82faf916

Author: Spencer Oliver <[email protected]>
Date:   Fri Aug 10 16:17:24 2012 +0100

    flash: fix FC_FLEX_RAM class code path
    
    If the flash class was defined as FC_FLEX_RAM then this would always drop
    through to the default handler.
    
    This bug was found by clang, so untested.
    
    Change-Id: I2d9fe6415dd216728a145519400f7b9ef1bd3c3a

Author: Christopher Kilgour <[email protected]>
Date:   Wed May 23 11:05:28 2012 -0700

    kinetis: update support for all program flash granularities
    
    Updates the Kinetis NOR flash support to handle all known block and sector
    sizes.  Previously only 2kiB sectors were hard-coded, now all four known
    combinations non-volatile sector sizes are supported.
    
    The premise of separating Kinetis Program Flash (PFLASH) from FlexNVM is
    also introduced.  This means each "block" of flash (in Freescale terms) is
    treated as a bank in OpenOCD.  Correspondingly, the existing board
    configuration for the TWR-K60M512 eval system is updated to recognize two
    banks instead of one.
    
    A board config for the TWR-K60F120M is also added.
    
    Bank and sector erase and programming has been checked with both of the
    mentioned eval boards.
    
    Change-Id: Iae2d10ebf8f548d0a3698df5430bbbe1ccadc58a

 -------------------------- end -------------------------- 


------------------------------------------------------------------------------
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://p.sf.net/sfu/appdyn_d2d_feb
_______________________________________________
OpenOCD-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openocd-devel

Reply via email to