AN12218SW Bootloader doesn't properly reset SCG->FIRCDIV and PCC->LPUART prior to app jump.

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

AN12218SW Bootloader doesn't properly reset SCG->FIRCDIV and PCC->LPUART prior to app jump.

ソリューションへジャンプ
1,383件の閲覧回数
lucianomoretti
Contributor IV

While debugging peripheral clocking issues after jumping from the bootloader I found the following in the clocks.c reset_clock() function:

SCG->FIRCDIV |= SCG_FIRCDIV_FIRCDIV2(0b000); /* Disable FIRC divider */


This code does not change the FIRDIV register because it is an "or" with zeros.

The corrected code is:

SCG->FIRCDIV &= ~SCG_FIRCDIV_FIRCDIV2(0b111); /* Disable FIRC divider */

 

The code also does not restore the clock source for the LPUARTs in the Uart.c void UART_Reset(LPUART_Type *pUART) function to the original clock source of '0', leaving it set to clock source 3 as set in the UART_Init function.

0 件の賞賛
返信
1 解決策
1,375件の閲覧回数
lukaszadrapa
NXP TechSupport
NXP TechSupport

Hi,

thank you for bringing this into our attention, I will report it. The application note should be updated in the near future.

Regards,

Lukas

元の投稿で解決策を見る

0 件の賞賛
返信
1 返信
1,376件の閲覧回数
lukaszadrapa
NXP TechSupport
NXP TechSupport

Hi,

thank you for bringing this into our attention, I will report it. The application note should be updated in the near future.

Regards,

Lukas

0 件の賞賛
返信