How To Sucessfully Program a Custom made Kinetis Microcontroller Board.

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

How To Sucessfully Program a Custom made Kinetis Microcontroller Board.

How To Sucessfully Program a Custom made Kinetis Microcontroller Board.

Kinetis Programming using PE multilink


  1. Connect All the VDD to +3.3V and all VSS to GND.
  2. Connect 10K pullup resistor to RESET_b pin of the controller.
  3. If the controller have the option of JTAG/SWD/EZport make sure to connect 10K pullup resistor to NMI_b or EZP_CS_b pin. NMI_b pins selects the interrupt to highest priority so the controller won't enter into programming mode and EZP_CS_b pin is used for selecting Ezport programming method.  
  4. At factory reset condition, all the controller is in the continuous watchdog enabled mode and constantly resetting and the voltage level on the reset pin will be approx 1.64V after adding the pullup resistor as mentioned in point 2.
  5. Do not add any filter capacitor on the reset pin while programming the controller for the first time. As it will not let the logic level go low while programming. Which is essential.
  6. On probing the reset pin to the oscilloscope the following will be the pattern

    pastedImage_10.png

  7. Before programming we need to mass erase the controller otherwise it will be in continuous reset mode. And to do that we need to configure SWD/JTAG mode. The following configurations for K20P48 LQFP in SWD mode.

  8. For mass erase following steps we need to follow.

    Search for thunderbolt icon in code warrior ie flash programmer and click on the drop-down menu on the icon.

  9. Mass_erase.png 
  10. Edit_connection.png 
  11. Click on edit then  
  12. Multilink_options.png  
  13. After configuring the above settings then click on the erase whole device option shown on step 9.
  14. If the microcontroller have JTAG/SWD and EZPORT then connect the microcontroller to JTAG port using PORT B of multilink with 20 pin headder. Try avoiding jumpers instead connect the 20 pin cable provided with PE multilink programmer. As all GND pins need to be connected on board's GND.  
  15. If the problem still persist then refer to this link Freescale community programmer
Comments

After using Kinetis products extensively over the past year I've come to the conclusion that SWD is unreliable on these parts (especially the k60's)  and should never be used in a production environment... Use either JTAG or EZPORT/SPI and save yourself a world of headache

Hi,

I am migrating my program from a FRDMKL26Z to a custom board using KL26Z128 48 QFN; I am trying to program it using the PE Multilink and SWD connections. I observe all the above levels and notice reset pin as above and ensure the NMI pin is pulled up as well. Unfortunately, i am unable to mass erase or program the target with the error as unable to connect to the PE device. Any suggestions? I was able to program the freedom board using SWD and Port G on the PE Multilink, any chance I'd be able to program it from Port B?

No ratings
Version history
Last update:
‎01-31-2014 09:24 PM
Updated by: