Flash Bootloader - partially working - what am I doing wrong? (Production boards w/o OpenSDA)

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

Flash Bootloader - partially working - what am I doing wrong? (Production boards w/o OpenSDA)

Jump to solution
1,524 Views
orangeusa
Contributor III

I'm using a K64F and migrating to custom hardware. So am trying to dump OpenSDA - that's a lot of hardware and $$$ for a production unit... And holding up sending out a board until I get the bootloader happy.

I've tried "freedom_bootloader.bin" and that works fine while connected to the SDA USB port and running "KinetisUpdater.exe" to update led_demo_FRDM-K64F_a000.bin with an offset of 0x0000A000. Perfect.

....    Now - trying to dump OpenSDA and setup a bootloader for production hardware.   ....

Loaded "flashloader_loader.bin" and it creates a USB HID device that "KinetisUpdater.exe" sees, and will flash the demo_blinky. Great.

"freedom_bootloader.bin"  clearly works through OpenSDA and works just fine. flashloader_loader works through the other USB port (K64_USB) and programs properly, but "demo_blinky" never executes..

Even after a full reset and NOT going into bootloader mode, "demo_blinky" is not running - so I'm not even sure that the programming by "KinetisUpdater.exe" is correct.

Any help would be greatly appreciated. :smileyhappy:  Yes, I should build a bootloader and single-step through the thing using P&E...

Also, the Kinetis Bootloaer 1.1.0 docs mention about using external I2C EEPROM, but how does that get programmed and updated in the field ?

So, I'm planning on using the HID solution to update firmware in the field. So confused.

ANOTHER QUESTION:

       For production - do you typically get the processor flash pre-programmed? Or flash using P&E (slow as heck).

       I just found this doc and it appears like it'll get me in the right direction:

           AN4835.pdf - Production Flash Programming of Kinetis....

Tags (2)
0 Kudos
1 Solution
919 Views
mjbcswitzerland
Specialist V

Hi Scott

For production programming the usual method is to use EzPort or JTag with the K64. EzPort requires only 4 signals. If you have isssues with P&E it is not due to the adapter or interface but due to the SW controlling it (KDS or CW flashing is slow due to Eclipse - with a production tool it will be very fast).

You may be able to arrange a pre-programmed boot loader (you may have to pay for it to be pre-programmed though) but this will be slower - beware of the present KBOOT software because it is very slow (100k code takes > 5 minutes to program via USB; a very large program can take up to an hour!!) so other interfaces are advisable. The simple demos work well because they are only about 1k in size so you don't notice the fact that the PC program has basic errors in the present version.

There are also KBOOT compatible (and other) loaders at http://www.utasker.com/kinetis/FRDM-K64F.html

but these are programmed "in" production (still probably best is EzPort via bed of nails since it adds zero cost to the board and takes a fraction fo a second with a suitable adapter) and used later in the field for SW updating.

You can also use a development board to program production boards via EzPort since it is just an SPI Flash interface that is simple to program. There is even an EzPort example at the KWIKSTIK page: Ultra low-cost development tool for Kinetis M|Freescale ("Kinetis KwikStik-based EzPort programmer")

Regards

Mark

P.S. For in-field programming USB-MSD and/or Ethernet Web Server are recommended since they don't require end users to install any software and are platform independent (Eg. Mac users will not have issue)

Kinetis: µTasker Kinetis support

K64: µTasker Kinetis FRDM-K64F support / µTasker Kinetis TWR-K64F120M support

Boot loader: http://www.utasker.com/docs/uTasker/uTaskerSerialLoader.PDF

For the complete "out-of-the-box" Kinetis experience and faster time to market

View solution in original post

0 Kudos
3 Replies
919 Views
juanpablovega
Contributor I

When using the Flashloader_loader, it's the 0x00000000 example and not the 0X0000A000 that works.

0 Kudos
920 Views
mjbcswitzerland
Specialist V

Hi Scott

For production programming the usual method is to use EzPort or JTag with the K64. EzPort requires only 4 signals. If you have isssues with P&E it is not due to the adapter or interface but due to the SW controlling it (KDS or CW flashing is slow due to Eclipse - with a production tool it will be very fast).

You may be able to arrange a pre-programmed boot loader (you may have to pay for it to be pre-programmed though) but this will be slower - beware of the present KBOOT software because it is very slow (100k code takes > 5 minutes to program via USB; a very large program can take up to an hour!!) so other interfaces are advisable. The simple demos work well because they are only about 1k in size so you don't notice the fact that the PC program has basic errors in the present version.

There are also KBOOT compatible (and other) loaders at http://www.utasker.com/kinetis/FRDM-K64F.html

but these are programmed "in" production (still probably best is EzPort via bed of nails since it adds zero cost to the board and takes a fraction fo a second with a suitable adapter) and used later in the field for SW updating.

You can also use a development board to program production boards via EzPort since it is just an SPI Flash interface that is simple to program. There is even an EzPort example at the KWIKSTIK page: Ultra low-cost development tool for Kinetis M|Freescale ("Kinetis KwikStik-based EzPort programmer")

Regards

Mark

P.S. For in-field programming USB-MSD and/or Ethernet Web Server are recommended since they don't require end users to install any software and are platform independent (Eg. Mac users will not have issue)

Kinetis: µTasker Kinetis support

K64: µTasker Kinetis FRDM-K64F support / µTasker Kinetis TWR-K64F120M support

Boot loader: http://www.utasker.com/docs/uTasker/uTaskerSerialLoader.PDF

For the complete "out-of-the-box" Kinetis experience and faster time to market

0 Kudos
919 Views
orangeusa
Contributor III

Thanks for the input on programming - I'm looking into a 3rd party for programming the IC's before assembly for the proto run of 100 boards. The PROBLEM is that the above boot loader doesn't sound as if it's ready for prime time. And for some reason, I missed that this device (MK64F...) doesn't have a boot ROM. No big deal. I'll contact you - sounds like we need to talk. :smileyhappy:   The reference manual for this part is 1789 pages ! Yay. :smileyhappy:

0 Kudos