Compatibility between multi-core and lwIP on RT1170

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

Compatibility between multi-core and lwIP on RT1170

Jump to solution
1,450 Views
LoicBe
Contributor II

Hi,

I'm getting started with the i.MX RT1170 chip, using EVK, and I would simply like to use multi-core message buffers with FreeRTOS along with TCP communication, using lwIP.

So far, both features are working well on the same code... when the other is commented.  As soon as the secondary core (CM4) is started using MCMGR_StartCore, the TCP communication stops.

Is there any known incompatibility between those features? If you have anything that worth exploring, I would be grateful.

Thank you,

Loïc.

0 Kudos
1 Solution
1,376 Views
jingpan
NXP TechSupport
NXP TechSupport

Hi @LoicBe ,

Yes, in BOARD_BootClockRUN it call CLOCK_SetPllBypass(kCLOCK_PllSys1, true) and CLOCK_DeinitSysPll1(). But PLL1 is enet clock source. In your application, you should disable these two call.

 

Regards,

Jing

View solution in original post

0 Kudos
5 Replies
1,422 Views
jingpan
NXP TechSupport
NXP TechSupport

Hi @LoicBe ,

In RT1170 freertos_message_buffer example, xMessageBufferSend() call sbSEND_COMPLETED() to send message. This macro is redefined to vGenerateSecondaryToPrimaryInterrupt(). That means xMessageBufferSend() can't be used both on sending message between tasks and between cores.

 

Regards,

Jing

0 Kudos
1,410 Views
LoicBe
Contributor II

Hi @jingpan,

Thank you for your answer!

I understand your explanation but I'm not sure it really fits the situation as I can run without any problem a TCP echo example with sbSEND_COMPLETED() redefined to vGenerateSecondaryToPrimaryInterrupt().  It just stops working when MCMGR_StartCore() is called.

Does it make sense with what you explained?

Thank you!

Loïc.

0 Kudos
1,407 Views
jingpan
NXP TechSupport
NXP TechSupport

Hi,

Can you give an example project?

 

Regards,

Jing

0 Kudos
1,397 Views
LoicBe
Contributor II

Hi,

Sure, here is an example of a simple mix between "multicore message buffer" and "TCP echo" sample codes.  I commented the multicore part from the app_task from the MCMGR_StartCore just so the TCP echo is working.  If you uncomment MCMGR_StartCore this is not working anymore.

After some deeper investigation it looks like this is the BOARD_BootClockRUN of the CM4 core that prevents the communication from working on the CM7 core.

Thank you for your help.

Loïc.

0 Kudos
1,377 Views
jingpan
NXP TechSupport
NXP TechSupport

Hi @LoicBe ,

Yes, in BOARD_BootClockRUN it call CLOCK_SetPllBypass(kCLOCK_PllSys1, true) and CLOCK_DeinitSysPll1(). But PLL1 is enet clock source. In your application, you should disable these two call.

 

Regards,

Jing

0 Kudos