MK10DX256VLK7 doesn't run standalone, just when debugging. Verified it's running from FLASH, not RAM.

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

MK10DX256VLK7 doesn't run standalone, just when debugging. Verified it's running from FLASH, not RAM.

ソリューションへジャンプ
3,540件の閲覧回数
carloscuev
Contributor V

I'm using MK10DX256VLK7 with internal oscillator, the problem is that it runs just when I'm debugging (I use Segger J-Link) but it doesn't run standalone, I'm sure I'm writing the code to FLASH, I have selected the FLASH target and verified code is running from FLASH. Any thoughts about what I'm doing wrong? Thanks.

MK10DX256VLK7.png

1 解決策
2,067件の閲覧回数
Jorge_Gonzalez
NXP Employee
NXP Employee

Hello Carlos:

I guess the problem is that you might be compiling with a "semihosting" ewl library.

Please go to Project -> Properties -> C/C++ Build -> Settings -> Librarian, and make sure that you do not have selected any of the "XXX_hosted" options. You can go with ewl_noio.

Libraries.png

Hope this solves the problem.

Regards!

Jorge Gonzalez

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

元の投稿で解決策を見る

3 返答(返信)
2,068件の閲覧回数
Jorge_Gonzalez
NXP Employee
NXP Employee

Hello Carlos:

I guess the problem is that you might be compiling with a "semihosting" ewl library.

Please go to Project -> Properties -> C/C++ Build -> Settings -> Librarian, and make sure that you do not have selected any of the "XXX_hosted" options. You can go with ewl_noio.

Libraries.png

Hope this solves the problem.

Regards!

Jorge Gonzalez

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

2,067件の閲覧回数
carloscuev
Contributor V

That was the problem, thank you very much Jorge, now I see how inadvertently enabled this when creating my project:

Semihosting.png

This means now I have no Debugger Console IO support right?

0 件の賞賛
返信
2,068件の閲覧回数
Jorge_Gonzalez
NXP Employee
NXP Employee

Good to know it worked.

You are right, without one of those "hosted" libraries you have no debugger console support. It is always better to use a UART and a terminal program. In case you really need printfs, you can use the ConsoleIO component. Check the next tutorial:

Tutorial: Printf() with (and without) Processor Expert | MCU on Eclipse

Regards!

Jorge Gonzalez

0 件の賞賛
返信