Code stuck in BOARD_InitDebugConsole();

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

Code stuck in BOARD_InitDebugConsole();

跳至解决方案
5,360 次查看
whiteliondd6
Contributor I

I am using KE16Z64VLD4 MCU for my application and using MCUXpresso IDE and  SDK_2.x_FRDM-KE16Z SDK. but code is stuck in

 BOARD_InitDebugConsole();     >>     DbgConsole_Init(BOARD_DEBUG_UART_INSTANCE, BOARD_DEBUG_UART_BAUDRATE, BOARD_DEBUG_UART_TYPE, uartClkSrcFreq);    >>  assert(kStatus_SerialManager_Success == status);

How to solve this ? and I want to use Debug console so, it is necessary to solve the problem.

0 项奖励
回复
1 解答
5,336 次查看
Robin_Shen
NXP TechSupport
NXP TechSupport

#define BOARD_DEBUG_UART_CLKSRC kCLOCK_IpSrcSysOscAsync in board.h, but Problem in initialization of clock you don't have external crystal.

BOARD_DEBUG_UART_CLKSRC   kCLOCK_IpSrcSysOscAsync.png

Would you please check difference between the your custom board and FRDM-KE16Z?
For example:
LPUART0 is used?
PORTB0 (pin 27) is used as LPUART0_RX?
PORTB1 (pin 26) is used as LPUART0_TX?

 

Best Regards,
Robin

在原帖中查看解决方案

0 项奖励
回复
4 回复数
5,344 次查看
Robin_Shen
NXP TechSupport
NXP TechSupport

Hi

Does the board configuration of your KE16Z64VLD4 application same as FRDM-KE16Z? If not you need to modify it.

board.png

Or you can refer the LPUART examples in SDK: (...\SDK_2_11_0_FRDM-KE16Z.zip\boards\frdmke16z\driver_examples\lpuart)

Best Regards,
Robin
-------------------------------------------------------------------------------
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 项奖励
回复
5,339 次查看
whiteliondd6
Contributor I

Yes, I have check it is same as KE16Z. I also go through UART SDK example but, didn't find the solution. Further support is required.

0 项奖励
回复
5,337 次查看
Robin_Shen
NXP TechSupport
NXP TechSupport

#define BOARD_DEBUG_UART_CLKSRC kCLOCK_IpSrcSysOscAsync in board.h, but Problem in initialization of clock you don't have external crystal.

BOARD_DEBUG_UART_CLKSRC   kCLOCK_IpSrcSysOscAsync.png

Would you please check difference between the your custom board and FRDM-KE16Z?
For example:
LPUART0 is used?
PORTB0 (pin 27) is used as LPUART0_RX?
PORTB1 (pin 26) is used as LPUART0_TX?

 

Best Regards,
Robin

0 项奖励
回复
5,319 次查看
whiteliondd6
Contributor I

Thank you for this solution. Now, I'm using SIRC(4MHz) as a clock source for debug console but, PRINTF function is not working although code is running nicely and having 0 errors and 0 warnings. I assigned LPUART0 for debug console. Attaching Screenshots.

0 项奖励
回复