SE050 Middleware heap overflow observed

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

SE050 Middleware heap overflow observed

789 Views
pranavitraj
Contributor I

Hey there,

I’m trying to integrate the Se050 with the LPC55S.

The physical connections are as follows:

- Host MCU -> Se050 -> Sensor (on I2C)

When the bus communications intervene between the Host MCU and Se050, it hangs.

 

The following sequence is applied to recover it 

 

- I2C recovery using GPIOs

- Reinitialize the Se050 by executing the following sequence:

  - sss_close_session()

  - open_boot_session()

 

During the open session, I encountered an error indicating that the open session failed. With a retry mechanism and a 100ms wait period between each retry, if the first attempt fails, I’m able to communicate again with the Se050. However, to simulate this condition, we manually caused the I2C hang multiple times and discovered that the heap memory overflows when the reinit and open session fails with timeout error.

 

Is this a known issue?
please provide any workarounds. 

Labels (1)
Tags (1)
0 Kudos
Reply
4 Replies

301 Views
pranavitraj
Contributor I

Hi Kan,

Any suggetion for above.

here is specific call stack for no termination

systick_delay() at timer_kinetis_bm.c
sm_sleep() at timer_kinetis_bm.c
BackOffDelay_Wait() at i2c_lpc55sxx.c
kinetisI2cStatusToAxStatus() at i2c_lpc55sxx.c
axI2CRead() at i2c_lpc55sxx.c 
phPalEse_i2c_read() at phNxpEsePal_i2c.c 
phNxpEse_readPacket() at phNxpEse_Api.c
phNxpEse_read() at phNxpEse_Api.c 
phNxpEseProto7816_GetRawFrame() at phNxpEseProto7816_3.c 
phNxpEseProto7816_ProcessResponse() at phNxpEseProto7816_3.c
TransceiveProcess() at phNxpEseProto7816_3.c

there is no termination for the number of times nack it waits forever 


also we see one problem related to the 
deinit and reinit of se050 sequence 

after deinit which is a END_OF_APDU command SE did not reply for 5 seconds 
can you please suggest for this also or is it known time ???

Regards
Pranav

0 Kudos
Reply

405 Views
pranavitraj
Contributor I

Hi kan

can you please help on above query 

0 Kudos
Reply

743 Views
Kan_Li
NXP TechSupport
NXP TechSupport

Hi @pranavitraj ,

 

Would you please specify the MW version that you are testing with? and which demo is referred? We may try to reproduce this issue here.

 

Thanks for your patience!

 

Have a great day,
Kan


-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!
- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------

0 Kudos
Reply

574 Views
pranavitraj
Contributor I

Hi Kan,

 

I tried the newer version of the middleware which resolved the heap issue.

 

Thank you so much for your support and time.

 

Just one more small observation: during the same test, the se_reinit sometimes got stuck waiting for an ACK. This happened specifically when we received continuous NACKs from the SE device because there was no termination. Please suggest a solution for this as well.

 

0 Kudos
Reply