M7 UART application prints garbage values because of Uboot on A53

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

M7 UART application prints garbage values because of Uboot on A53

470 次查看
puravp
Contributor II

Hello,

I have a S32G274A board from MicroSys which has ST6 serial port for UART communication. I am trying to run an application on M7 core which basically prints 'Hello World'.

When I run the application from T32 debugger, it works but when I am flashing the application on the QSPI and then trying to load the application via:

sf probe 6:0; sf read 0x34001000 0 0x002ff390; dcache off; startm7 0x34001000 

It prints bHell= World! or sometimes Bello World and sometimes something else. It looks like the u boot and my application both are accessing the same port and hence this issue occurs.

 

How can I solve this? Or how can I exit the u boot after startm7 command? 'Exit' command doesnot work.

0 项奖励
回复
3 回复数

427 次查看
chenyin_h
NXP Employee
NXP Employee

Hello, @puravp 

Thanks for your confirmation.

From my experience, a possible method raised only for your reference:

1. Add a flag in uboot serial function

2. When calling startm7, modify this command to firstly set the flag mentioned on step1, then the serial function will check the flag and will not call the low level console function(the UART driver), so that there will not be any prints from uboot.

3. When M7 application started, since the output from uboot could not be shown on the console, the output of M7 application may not be impact by the uboot output. 

Another possible way is to deinit the UART driver after calling the startm7 command, and re-init the UART in your M7 code before your prints, it may also fulfill your requirements.

 

BR

Chenyin

0 项奖励
回复

439 次查看
puravp
Contributor II

Hello Chenyin,

Thanks for your reply.

Unfortunately, on my board there is only 1 UART port. Is there a way to quit the U-boot right after the startm7?

Thanks

Purav

0 项奖励
回复

451 次查看
chenyin_h
NXP Employee
NXP Employee

Hello, @puravp 

Thanks for your post.

Yes, the A53 side and M7 side both access the same UART may result similar issue, a possible method is to use the alternative UART for M7 to avoid such issue.

If you are working with RDB2, then the UART1 could be directly used, since you are working with custom board, not sure if the UART1 exists on your board, I suggest checking it firstly.

 

BR

Chenyin

0 项奖励
回复