S9KEAZN16AMLH only runs on debugger

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

S9KEAZN16AMLH only runs on debugger

979 Views
ianchuter
Contributor II

Hi 

I can only get applications to run when they are started by the dubugger. If the debugger is removed from a running board it will continue, but stops after a power cycle. 

I have disabled semihosting and I'm using the release configuration into flash - any ideas how to be able to run standalone?

Labels (1)
0 Kudos
11 Replies

800 Views
ianchuter
Contributor II

Hi, I'm using the S32 Design Studio.

I've set the library support to "newlib_nano no2I/O" - I believe this is the equivalent of the picture. 

Can you tell me where in S23DS I can double check that I'm writing to flash?

0 Kudos

800 Views
kerryzhou
NXP TechSupport
NXP TechSupport

Hi Lan,

   Double check your question again.

  Do you mean, the code already download to the board, then when the debugger is connect, the code can run, if you remove the debug, the code can't run?

  Or, do you mean, when in debug mode, the app can works, when you exit debug mode, just download the code to the board, it can work?

  Please confirm it.

  Besides, please check you are using RAM or FLASH? And your hardware, RESET pin need to have external pull up and 0.1uf capacitor to ground.

  Please try the debug code instead of release code.


Have a great day,
Kerry

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

0 Kudos

800 Views
ianchuter
Contributor II

Hi

If I start a debug session, the code runs. If I unplug the debugger, the code continues to run. 

If I cycle the power, the code does not run.

If I flash the device (not start a debug session), the code does not run. 

The is the same with debug and release configuration. 

Reset pin has 10k pullup to 5V and 100nF to 0V.

Can you tell me how to check if I am running from RAM or flash in S32 Design Studio?

0 Kudos

800 Views
kerryzhou
NXP TechSupport
NXP TechSupport

Hi Lan,

pastedImage_1.png

The above picture is choosing the RAM, if you want to download to flash, please choose debug FLASH in the properties.

From your phenomena description, it seems you build your code in RAM, not in FLASH.

Please check the IDE properties again.

Any updated information, please let me know!


Have a great day,
Kerry

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

0 Kudos

800 Views
ianchuter
Contributor II

Hi

My project only has debug and release configurations, for some reason it was not created with flash and ram ones.

What options actually define where a configuration will place the application?

0 Kudos

800 Views
kerryzhou
NXP TechSupport
NXP TechSupport

Hi Lan,

   If you are convenient, you can send me your problem project, you can delete all the important code which is important to you, just leave the smallest project which can reflect the problem, I would like to help you to check it on my side.


Have a great day,
Kerry

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

0 Kudos

800 Views
ianchuter
Contributor II

Hi

Thank you, an emptied version of the project is available here: Dropbox - KEA 

0 Kudos

800 Views
kerryzhou
NXP TechSupport
NXP TechSupport

Hi lan Chuter,

   I can't open the link which you give me.

  Could you attach it in this post directly? You attach the project use advanced editor.


Have a great day,
Kerry

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

0 Kudos

800 Views
ianchuter
Contributor II

Hi

Project attached.

Kind regards

Ian

0 Kudos

800 Views
kerryzhou
NXP TechSupport
NXP TechSupport

Hi Lan Chuter,

    I got the email from your local NXP FAE, your problem is caused by your hardware NMI, you pulled NMI(ptb4) low with a resistor before POR, that is the root problem.

  Normally, in KEA hardware, we recommend customers to add external 4.7K to 10K pull up resistor in the NMI pin.


Have a great day,
Kerry

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

0 Kudos

800 Views
kerryzhou
NXP TechSupport
NXP TechSupport

Hi Ian,

  What the IDE you are using? And where the code you are downloading, Flash or RAM?

  You must make sure your code is downloaded to the flash not the RAM.

  Then if you still have the problem, and you also use the CW, please check this picture:

pastedImage_1.png

Properties should select ewl_hosted in Librarian.

Wish it helps you!


Have a great day,
Kerry

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

0 Kudos