UART in M4 Core1 IMX8QM

cancel
Showing results for 
Search instead for 
Did you mean: 

UART in M4 Core1 IMX8QM

265 Views
vinothkumars
Senior Contributor III

Hi All,

I configured M40 UART in M4 MCU. But, there is no log from M4 UART

by default rear_view_camera application used core1 not core0

But, I configured SC_P_M40_I2C0_SDA as uart in Core1 as per the hardware

"

+ err = sc_pad_set_all(ipc, SC_P_M40_I2C0_SDA , 2U, SC_PAD_CONFIG_NORMAL, SC_PAD_ISO_OFF, 0x0 ,SC_PAD_WAKEUP_OFF);/* IOMUXD_M40_I2C0_SDA register modification value */
+ if (SC_ERR_NONE != err)
+ {
+ assert(false);
+ }

"


Will you please verify my configuration proper or not.

I need clarification -> M4 core0 UART will run or not in M4 core1.


BSP: L4.14.98 + Android 9 Automotive + MCU SDK

 

 

Regards,
Vinothkumar Sekar
0 Kudos
7 Replies

255 Views
igorpadykov
NXP TechSupport
NXP TechSupport

Hi Vinothkumar

 

for that case except iomux settings one should consider proper resource allocation as described on

https://community.nxp.com/t5/i-MX-Processors-Knowledge-Base/System-Controller-Firmware-101-Resource-...

 

Best regards
igor

0 Kudos

245 Views
vinothkumars
Senior Contributor III

Thank you @igorpadykov for the quick reply.

 

But, Unable to find how to use the core0 resource to core1. Will you please give some more details.

 

Regards,
Vinothkumar Sekar
0 Kudos

234 Views
igorpadykov
NXP TechSupport
NXP TechSupport

please look at sect."Modifying default configuration" suggested link.

 

Best regards
igor

0 Kudos

228 Views
vinothkumars
Senior Contributor III

Thank you @igorpadykov 

 

Yes I checked it. But, I have to use the Cortex-M4 Core0 uart resource to Cortex-M4 Core1 for debug console.

These things I unable to find out 

 

Regards,
Vinothkumar Sekar
0 Kudos

210 Views
igorpadykov
NXP TechSupport
NXP TechSupport

>I have to use the Cortex-M4 Core0 uart resource to Cortex-M4 Core1 for debug console.

 

may be suggested to assign Core0 uart resource to Core1 partition, use flexcan example from suggested link.

 

Best regards
igor

0 Kudos

123 Views
vinothkumars
Senior Contributor III

Hi @igorpadykov ,

 

Still I unable to achieve this,

SC_P_M40_I2C0_SDA for MIMX8QM_CM4_CORE1

I tried almost all API but there is no luck,

ipc = SystemGetScfwIpcHandle();

sc_rm_get_partition(ipc,&pt_m4);

sc_rm_set_pad_movable(ipc, SC_P_M40_I2C0_SCL, SC_P_M40_I2C0_SDA, SC_TRUE);
sc_rm_assign_pad(ipc, pt_m4, SC_P_M40_I2C0_SDA);

 

#if defined(MIMX8QM_CM4_CORE0)

#define BOARD_INITPINS_TX SC_P_M40_I2C0_SDA /*!< Pin function id */

#define BOARD_INITPINS_RX SC_P_M40_I2C0_SCL /*!< Pin function id */

#elif defined(MIMX8QM_CM4_CORE1)

#define BOARD_INITPINS_TX SC_P_M41_I2C0_SDA /*!< Pin function id */

#define BOARD_INITPINS_RX SC_P_M41_I2C0_SCL /*!< Pin function id */

#else

#error pin config not set

#endif

Regards,
Vinothkumar Sekar
0 Kudos

189 Views
vinothkumars
Senior Contributor III

Thank you @igorpadykov  for the reply,

/* set as movable */

sc_rm_set_resource_movable(ipc, SC_P_M40_I2C0_SDA, SC_P_M40_I2C0_SDA, SC_TRUE);

SCFW to M4_1

Partition 0 --> SCFW (M40_I2C0_SDA)

Partition 4 --> M4_1 

 

Is it the right way ?

 

Regards,
Vinothkumar Sekar
0 Kudos