Freedom OpenSDA Firmware Issues Reported on Windows 10

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

Freedom OpenSDA Firmware Issues Reported on Windows 10

Freedom OpenSDA Firmware Issues Reported on Windows 10

It has been reported that OpenSDA v2/2.1 bootloader could be corrupted when the board is plugged into a Windows 10 machine. An updated OpenSDA bootloader that fixes this issue is available at www.NXP.com/openSDA. There is also a blog article by Arm addressing this issue.

To reprogram the bootloader on affected boards, you will require an external debugger, such as Segger JLink or Keil ULink programmer attached to the JTAG port connected to the K20 OpenSDA MCU. For your convenience, the binaries of the OpenSDA v2.2 bootloader is attached at the bottom of this post.

If using a Segger JLink, download the latest JLink Software and Documentation pack and use the following JLink.exe commands to connect to the K20 OpenSDA MCU:

  • Connect
  • MK20DX128xxx5
  • S
  • 4000

pastedImage_2.png

And then use the following commands to reflash the bootloader:

  • erase
  • loadbin <your Bootloader Binary> 0x00000000

pastedImage_4.png

Here is another post on how to recover bricked OpenSDA boards and to prevent it getting re-bricked.


To check more information regarding OpenSDA on your boards, please go to www.nxp.com/opensda.

Comments

Hi, it seems like i have the same problem with FRDM KV31F board when I plugged it in for BOOTLOADER mode to Win 10 machine. After I disconnected the board, it can no longer be detected at all in any other PCs. Is there any other solutions to this problem without the external debugger? I am a hobbyist/student and certainly can't afford the external debuggers.

Many thanks

Can we get an update to the status of this issue?

Hi Iggy,

see https://mcuoneclipse.com/2016/06/26/how-to-recover-the-opensda-v2-x-bootloader/

how another FRDM board can be used to program the bootloader.

I hope this helps,

Erich

Hi Pete,

I'm using that beta v2.1 bootloader (see https://mcuoneclipse.com/2016/06/26/how-to-recover-the-opensda-v2-x-bootloader/  and How to recover FRDM-K22F? - Question | mbed ) for several days now with the FRDM-K64F and Windows 10 (64bit), and no issue with the bootloader overwrite. The only thing is that this V2.2 bootloader is using 0x8000 as base address for the application, so any V2.0 app (e.g. Segger or P&E) does not work. I have to load 0x8000 version. This means that for example the Segger MSD firmware (see https://mcuoneclipse.com/2016/06/19/segger-opensda-firmware-with-virtual-msd/) for the FRDM-K64F cannot be used, as yet again this firmware assumes a base address of 0x5000. I hope the OpenSDA v2.2 will come in two variants (0x5000 and 0x8000). Apart of that, it is working fine for me so far.

I hope this helps,

Erich

what about FRDM-K28F?

Really confused about the version , how to upgrade to openSDA 2.2 for K22 F ? 

Hi Alven,

  On the FRDM-K22F, you would need to connect an external debugger (like a Segger JLink or Keil U-Link) to the J12 header. Then program in the .bin file attached to this post, which will update the OpenSDA bootloader to version 2.2. Plug the board into your computer and it should enumerate as a mass storage device. Then you can drag-and-drop the latest DAPLink OpenSDA application for the FRDM-K22F on it (https://www.nxp.com/assets/downloads/data/en/ide-debug-compile-build-tools/OpenSDAv2.2_DAPLink_frdmk... ) and then you are all updated. 

-Anthony 

The FRDM-K28F already comes with the OpenSDA 2.2 bootloader, so no update is necessary for that board. 

On the FRDM-K22F, after updating the OpenSDA v2.2, should I also update the

CMSIS-DAP BOOTLOADER ?

You're updating the bootloader when you program in the .bin file that was attached to this post. That's why you need the external debugger probe, since at the moment it's the only way to update the bootloader part. 

Then after updating the bootloader, you need to load in an OpenSDA app, like the DAPLink app I linked to in my post, to get your board fully updated. 

-Anthony 

Hello, 

I attempted to use this guide to load a new binary onto my twr-kv58220m board using a j-link. However, the j-link refuses to connect to the board and gives the following:

error connecting to twr-kv58x.PNG

It seems the board wants to continuously reset. Anybody have any ideas on how I can get around this?

UPDATE: I managed to use a different computer to load a different bootloader ("SDA bootloader") onto the board and now I can code the board using USB or JTAG again. Not really a solution but a possible workaround. Hope this helps..

-Mike

I just went through a process with my board and finally realized that I was specifying the MCU ID instead of the ID of the part that hosts the SDA.  I have a FRDM-K66 board, but the SDA runs on a MK20DX128VFM5.  D'Oh.

That said. I'm not out of the woods yet, but I was seeing all sorts of frustration before I realized how I was getting it wrong.

My #frdm-k82f is brick state.  I am trying to load the 0244_k20dx_bl_0x8000 file to MK20DX128XXX5. I am getting flash error even after executing "unlock Kinetis" Please find the screenshot. Can any one help me to find the issue.EraseError.png

Hi,

since jtag is a standard, is it possible to use an AVR jtag programmer as "mySmartUSB MK3" instead of the JLink, or is it only for AVR boards?

Many thanks in advance.

-Valerio

Hi all,

I have just met the same issue on my FRDM-K22F.

I have Keil uVision V5 and ULINK2 as debugger, and I'm still uncertain how to program the bootloader .bin file on uVision.

If you have any workarounds, could you advise me ?

Thanks,

Shuichi

I think you may have connected your J-Link to the wrong connector - check that you have conncted it to the SWD connector near to the USB ports, not the one at the other end of the board.

Hey shuichiy, all

Exact same issues as you. Running a LS1012ARDB where a FRDM-K22F is running on it - and of course I run a WIN10 host - bang!

Since I also am using KEIL MDK Pro (Light is enough for flash, no restrictions) and a ULINK Pro JTAG probe I managed to flash the K22.

However, and that is a bit annoying: only HEX files can be flashed that way, means you must first transform your BIN into a HEX. I use srec_cat.exe as suggested by KEIL.

..\srecord-1.63-win32>srec_cat.exe 0244_k20dx_bl_0x8000_OK.bin -Binary -o 0244_k20dx_bl_0x8000_OK.hex -Intel

Such a HEX file effectively flashes on the K22. For that you must of course have en empty uVision project in place, no code but correct "Target 1" and associated configurations (here: NXP MK22FX512AVLH12). You also must ensure on the RDB power is on AND the front USB (DAP) is also connected so flash occurs.

So for me I think I did all correctly but doubt if BIN to HEX conversion did something wrong or if my KEIL "Target 1" configuration is wrong (I doubt).

Can anybody help? If I am able to realize this then I can share my findings here of course - am certainly not the only one with that problem. Please some answers!

Thx Christophe

Anybody here? Thx Christophe

It's almost 2020 and I guess it would be too much trouble for these boards to come already updated to run with Windows 10.  

I have a FRDM-K64F board and a Segger J-Link mini edu.  Using J-Link Commander V6.60c I'm getting a "Cannot connect to target".  Not sure why

Here is the J-Link Commander text:

SEGGER J-Link Commander V6.60c (Compiled Dec 23 2019 16:15:43)
DLL version V6.60c, compiled Dec 23 2019 16:14:31

Connecting to J-Link via USB...O.K.
Firmware: J-Link EDU Mini V1 compiled Dec 13 2019 11:16:57
Hardware version: V1.00
S/N: 801016825
License(s): FlashBP, GDB
VTref=0.000V


Type "connect" to establish a target connection, '?' for help
J-Link>connect
Please specify device / core. <Default>: MK20DX128XXX5
Type '?' for selection dialog
Device>MK20DX128XXX5
Please specify target interface:
J) JTAG (Default)
S) SWD
T) cJTAG
TIF>S
Specify target interface speed [kHz]. <Default>: 4000 kHz
Speed>4000
Device "MK20DX128XXX5" selected.


Connecting to target via SWD
Cannot connect to target.
J-Link>

Hi Leon,

Your log shows:

>>Device "MK20DX128XXX5" selected.

which is the problem in my view. Your debug connection tries to connect to the K20 (OpenSDA circuit) and not to the K64F?

So instead talking to the K20, use the following device in the J-link Commander:

MK64FN1M0xxx12

Make sure you are connecting to the correct SWD debug header, see

https://mcuoneclipse.files.wordpress.com/2017/07/debugging-frdm-k64f-with-linkserver-lpc-link2.png 

The article Using the FRDM-K64F with CodeWarrior | MCU on Eclipse  shows the different debug options for the board too.

I hope this helps,

Erich

I thought I was suppose to connect to the K20 using the 10 pin header closest to the chip.  I was able to connect after selecting the JTAG target interface.  I was able to load the file 0244_k20dx_bl_0x50000.bin onto the board.  Now when I plug the FRDM-K64F in it come up as MAINTENANCE drive.  This is both with and without holding the reset button.  There is one file called DETAILS.TXT in it.  Before updating the board would show up as BOOTLOADER drive when holding the reset button.  That drive would have one htm file showing that wouldn't open.  After about 20 seconds that drive would then disappear.

Now I have dragged k20dx_frdmk64f_if_crc_legacy_0x5000.bin into the MAINTENANCE drive and the board shows up as a FRDM-K64FD drive so I think I'm making progress.  I was then able to install mbedWinSerial_16466.exe and I can now see a mbed Serial Port showing up in the Device Manager.

Hi Leon,

Have you successfully recovered the board? I did it as your steps, and it shows up the virtual port (I use J-LINK) on the computer. However, the red LED is up together with green led, do you have the same issue? There is something wrong.

I just purchased two FRDM-K64F boards through Mouser. I connected a board to a USB port. I ran Keil Vision IDE and the debug interface appears as MBED CMSIS-DAP. A folder with a name MBED opened with mbed.htm and fail.txt in it. The content of fail.txt is a single word TIMEOUT. The board kept resetting itself periodically.

I clicked on mbed.htm and the mbed login page showed up in the web browser. After I logged in, it took me to https://os.mbed.com/platforms/FRDM-K64F/

I followed the step by step firmware upgrade instructions then the board seemed dead. When I plugged it to USB port, Keil IDE does not recognize it anymore neither does KDS.

I came to this thread and thought it could be the Windows 10 issue so I got out my Windows 7 computer from the storage, plugged the board to the USB port. The board did not reset periodically anymore. The folder has only mbed.htm but no fail.txt. I was able to repeat the step by step instructions to upgrade the firmware. I installed the same version of Keil IDE and was able to download and debug programs.

When I connected the board back to the Windows 10 computer, a folder with the name DAPLINK opened and there were mbed.htm and DETAILS.TXT in it. The Keil IDE sees the debug adapter as DAPLink CMSIS-DAP. Now I can download and debug programs in Windows 10.

Windows 10 was released July 2015. The FRDM-K64F boards have silkscreen of NXP (c) 2016. Does this mean NXP abandoned support for the older Freescale products? Should I avoid developing anything new based on these devices? 

Yes I did get the board working again using the J-Link EDU mini.  I don't remember all the details anymore.  I haven't had a chance to play with is since.  I'm guessing that I should have followed the instructions to update the firmware before ever plugging into a Windows 10 computer.  After it got corrupted, the only way to fix it was to buy something like the Segger J-Link to install the firmware.

From my Jan 1st post it looks like I was able to load that 0244_k20dx_bl_0x50000.bin file onto the K20 chip using the J-Link.  After that the K64 started to show up as MAINTENANCE.  From there it looks like I dragged the k20dx_frdmk64f_if_crc_legacy_0x5000.bin file into that drive.

No ratings
Version history
Last update:
‎04-28-2016 03:29 PM
Updated by: