I cannot successfully compile a project, I give in - please help!! :(

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

I cannot successfully compile a project, I give in - please help!! :(

Jump to solution
3,585 Views
justinreina
Contributor III

Hi,

I just purchased a Freedom KL25Z dev unit (FRDM-KL25Z) and am trying to use it. I am following NXP's provided Getting Started Guide located here

 

Getting Started Guide

FRDM-KL25Z|Freedom Development Platform|Kinetis MCU|NXP

 

Current State (Stuck!)

I have installed the IDE and Toolchain and have gotten to try to build my own project. I can build the lib (ksdk_platform_lib_KL25Z4), but the Linker fails on all attempts (hello_world attempt)!

 

See attached 'getting started procedure - trial 1.txt' for fairly detailed notes on my procedure leading up to failure. I've re-tried this a second time, and it failed again.

 

Request

Help, please!! What am I doing wrong, and how to correct?

 

 

This is like "Hello World 101", and is embarassing that I am stuck. Any and all help is Greatly appreciated!!

 

-Justin

Original Attachment has been moved to: getting-started-procedure---trial-1.txt.zip

Labels (1)
Tags (1)
1 Solution
2,765 Views
BlackNight
NXP Employee
NXP Employee

Hi Justin,

have a read at https://mcuoneclipse.com/2016/08/01/bricking_and_recovering_opensda_boards_in_windows_8_and_10/ , I think this should solve your problem (I hope), at least I was able to recover on my side.

I have added a short video with the steps to the above post too.

I hope this helps,

Erich

View solution in original post

32 Replies
2,264 Views
justinreina
Contributor III

And now, it works!!!!! THANK YOU ERICH! :smileyhappy: Beer time, yep!

0 Kudos
2,264 Views
BlackNight
NXP Employee
NXP Employee

Hi Justin,

Great to hear that it works now, and I hope you enjoyed your beer.

I'm sorry, I did not know that the group policy editor is only part of the Pro Edition :-(. Googling around I see that Microsoft does that already from Windows Vista on that way. And I feel very sorry that you had to spend money for an Windows update. I hate to write that after some googling that was not really necessary, as it is possible to make that change in the registry (regedit) as well. I hope that in the home edition using regedit is possible too? I have updated the the post with a section "Using Windows Registry" so this way is documented too.

Erich

2,264 Views
justinreina
Contributor III

this may sound cheesy but it's serious, as long as the final delivered solution, your article, provides the solution, it is totally fine by me! The money invested by me here is simply an investment in my machine and workstation, in review :)!

0 Kudos
2,264 Views
justinreina
Contributor III

I am using Windows 10, Windows 7 - sheesh! :smileywink:...

I tried your procedure, on both boards and both failed. See attached 'sun am-1 procedure.txt' and 'terminal.png' for illustration.

Thoughts? :smileysad:...

0 Kudos
2,264 Views
BlackNight
NXP Employee
NXP Employee

Hi Justin,

if you are using Windows 10, then this explains everything. That problem started with Windows 8 (see https://mcuoneclipse.com/2013/10/12/frdm-board-bootloader-fails-with-windows-8-1-preview/ ). I still have a notebook with Windows 7 around for this kind of problems (NXP is not the only company facing this problem: lots of hardware/boards produced before Windows 8 have this kind of problems).

There is one thing you could try (noted in comments of https://mcuoneclipse.com/2014/11/01/illustrated-step-by-step-instructions-updating-the-freescale-fre... ):

check out http://answers.microsoft.com/en-us/windows/forum/windows8_1-hardware/how-do-i-prevent-system-volume-...  if this works on your machine (I have not tried that myself).

I hope this helps,

Erich

0 Kudos
2,263 Views
BlackNight
NXP Employee
NXP Employee

Hi Justin,

stay tuned! I think I have found a way how you can recover the board without the need for a Windows 7 machine. I'm drafting right now an article and hopefully I can publish it on http://mcuoneclipse.com/  tonight (we have a national holiday today).

Erich

2,264 Views
justinreina
Contributor III

Hey Erich,

Are we serious here? THIS IS RAD, THANK YOU!!! I'll be around if needed to test, inspect or give feedback on anything! Just contact my by email if needed for faster response :smileyhappy:

-Justin

justinmreina@gmail.com

0 Kudos
2,264 Views
BlackNight
NXP Employee
NXP Employee

Hi Justin,

yes, I have ordered a new board from Farnell to see what happens, it arrived today.

My FRDM-KL25Z board had the V1.09 bootloader (the old one). This happened to me (please if this is the same for you):

a) originally plugin in the board, the small green LED came up, and board was recognized properly

b) powering it up in BOOTLOADER mode (Reset pressed), the board came up as BOOTLOADER, then the green small LED is off for a while, then blinks an error code, then off again, etc

c) in BOOTLOADER mode, clicking on the info.html file, it shows a version of 0.00 for the application in the web browser

d) powering the board normally, it does not enumerate, and the small green LED is always off (board bricked)

Same for you?

Erich

0 Kudos
2,264 Views
justinreina
Contributor III

In short, yep. In more detail -

I plugged in OpenSDA-USB to a powered down board, let Windows recognize the board and then inspected in File Explorer and Device Manager. Both boards displayed the same result for the two configurations of RST

RST depressed:

  •     Appeared in Device Manager->Disk Drive->FSL FSL/PEMICRO MSD USB Device
  •     Appeared in File Explorer-> BOOTLOADER(I:\)
  •     Green LED toggles 8 times at ~2Hz, repeating about every two seconds

RST not depressed:

    No response, they both appear bricked. No enumeration, no LEDs, nadda!

What may be the root cause here, sheesh! :smileysad:

0 Kudos
2,264 Views
BlackNight
NXP Employee
NXP Employee

Hi Justin,

ok, good, this is what I'm seeing too. And I was able to recover from this. Should be able to finish my article shortly.

Erich

2,766 Views
BlackNight
NXP Employee
NXP Employee

Hi Justin,

have a read at https://mcuoneclipse.com/2016/08/01/bricking_and_recovering_opensda_boards_in_windows_8_and_10/ , I think this should solve your problem (I hope), at least I was able to recover on my side.

I have added a short video with the steps to the above post too.

I hope this helps,

Erich

2,264 Views
justinreina
Contributor III

Yikes!! ... this is immensely embarrassing, and perceivably naive - how do you access the Group Policy Editor (gpedit) in Windows 10?? I have spent almost ten minutes now trying to uncover it and every google search result of a how-to fails... XX(! #1 how on earth can they all fail, and #2 why am I so bad at this?

Erich, if you could help, I would immensly appreciate it. As I can't open gpedit, I can't try your solution!! :smileysad:

EDIT (update & gpedit soln): Well after 10 minutes with MS tech support, it appears that the Group Policy Editor is a feature restricted to Windows 10 Pro, sheesh! So if you have the Home edition as I did, you will need to for over $99.99, yikes. I did, now I'll give Erich's solution here a try!! :smileyhappy:

0 Kudos
2,264 Views
justinreina
Contributor III

Hi Dan,

I tried your FW update procedure outlined by MCUonEclipse on this board this morning, but dang it, this didn't work.

Here was the result

  • Bootloader version still showed as 1.09
  • doesn't blink correctly (step 8 of ), or even show in File Explorer!
  • now no longer shows up as a Port or Disk Drive in Device Manager, or show in File Explorer
  • concl: this board is toast?

ok, must be a bad board right? Welp, nope... my second board came from Digikey this morning. I repeated the same process with this board, AND IT FAILED FOR THIS BOARD TOO! See 'newBoard_steps.txt' for detailed procedure for connecting and trying the new Digikey board this morning.

One interesting note

  • On first power-up of the new board, the RGB demo illuminated once, and then went dark. On USB cycling and RESET toggling it the RGB demo never illuminated again?

Questions / Next Steps

  • Maybe I just really am that bad of an engineer, and I am causing this. If not though, what the hell is wrong here, why is this occuring and how to fix??

One question of curiosity

  • My boards both state '2013 FREESCALE'. Why is Digikey selling three year old boards? May this be the cause, these are too old?? It is strange to me how the RGB demo only happened one time and then would not repeat, how after the update failed the boards took a hard dive and how this has occured on TWO seperate units. Are these just too old?

Woe is me, please help me get up and running!! This is embarassing, and it is sad... XX(!!

0 Kudos
2,264 Views
BlackNight
NXP Employee
NXP Employee

Hi Justin,

maybe I have missed it, but what host operating system are you using?

You only need to update the FRDM-KL25Z board bootloader if you are using Windows 10 or 8, but you need a Windows 7 machine for the update of the bootloader!

So can you confirm you are using a Windows 7 machine?

Here a few things where we could identify the problem:

1) Power/Plug in the board with the reset button pressed. It shall show up as BOOTLADER, with the following device in the device manager:

pastedImage_1.png

2) If you power the board with the P&E firmware loaded, it shall show up as FRDM-KL25Z, with the following devices:

pastedImage_0.png

For the copy operation outlined in https://mcuoneclipse.com/2014/11/01/illustrated-step-by-step-instructions-updating-the-freescale-fre..., do not use the file from the zip file directly. Unpack the files first. Use the DOS cmd.exe copy command and not the Windows Explorer. Disable any explorer extensions, firewalls or virus scanners.

In the debug connection, you have to use OpenSDA as interface:

pastedImage_2.png

I hope this helps,

Erich

0 Kudos
2,264 Views
justinreina
Contributor III

Hi Dan,

In prep for the arrival of my new FRDM-KL25Z and FRDM-KL82Z tomorrow, I wanted to take the safest possible path forward, to ensure I don't fail again with these boards ;)!

I've written up my detailed and explicit, perhaps semi-verbose procedure for tomorrow, I've attached it (getting started procedure - rd 3.txt), could you take a peek and let me know your thoughts? My expectation is that this is super-over-the-board on detail, just plug, play then run, but I cannot fathom the terror and fear that may come from a second failure! Sheesh!! ;)!

Could you review the attached proposed procedure for tomorrow, and let me know if ok? :smileyhappy:

Thanks,

  Justin

0 Kudos
2,264 Views
danielchen
NXP TechSupport
NXP TechSupport

Hi Justin:

The factory boards come shipped with an outdated firmware and application, To make the board working with Windows 8 it requires a bootloader update. To really use the board, the latest firmware needs to be loaded on the board too. could you try to update the firmware to see whether it helps?

Here is the step by step guide by my colleague.

https://mcuoneclipse.com/2014/11/01/illustrated-step-by-step-instructions-updating-the-freescale-fre...

Regards

Daniel

2,264 Views
justinreina
Contributor III

Hey Dan,

I reinstalled the drivers following your instructions, validated the drive in File Explorer and the two items in Device Manager.

Present Items after driver reinstall

  • (File Explorer) FTDM-KL25Z(I:)
  • (Disk Drives) FSL FSL/PEMICRO MSD USB Device
  • (Ports) OpenSDA - CDC Serial Port (http://) (COM23)

Still no ports showing up for my debug launch, same as last time. Yikes, thoughts?

To note your LED is on in your picture, mine stays off. Also to note, I have purchased a new FRDM-KL25Z board, should be in within a few days.

Sheesh / thank you!! :smileyhappy:

0 Kudos
2,264 Views
avinashgupta
Contributor II

OpenSDA supports two modes

  1. MSD Flash Programmer (to burn files to target MCU,  i.e. KL25Z128 by drag drop on USB drive interface)
  2. Debugger interface

These two are called OpenSDA applications.

To use the debugger application you need to load it into the OpenSDA chip.

For that press and hold reset button and connect usb cable to OpenSDA USB. This will also install as USB drive, but this time it won't program the target MCU but program the OpenSDA MCU.

From the following link you can download latest OpenSDA applications

http://www.pemicro.com/downloads/download_file.cfm?download_id=378

Find the correct application file for your Freedom Board (MSD-DEBUG-FRDM-KL25Z_Pemicro_v118.sda2016-07-31 12_46_53-Device Manager.png)

and copy/paste to the BOOTLOADER flash drive

WAIT TILL FULL FILE IS TRANSFERRED!Then disconnect and reconnect. Now it will work like a debugger and not a flash programmer.

0 Kudos
2,264 Views
danielchen
NXP TechSupport
NXP TechSupport

HI Justin:

I suggest you make clean your project, then click ""debug"

pastedImage_0.png

and make it again. Then you can see the port info.

pastedImage_1.png

Please try it.

Regards

Daniel

0 Kudos
2,264 Views
justinreina
Contributor III

Hi Dan,

I gave this a shot just now, and same response, none listed :smileysad:

-Justin

0 Kudos