LPC54606 Reinvoke UART ISP

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

LPC54606 Reinvoke UART ISP

850 次查看
gph
Contributor III

Hi,

I'am trying to Reinvoke ISP UART0 from IAP with no success.

ECRP say ISP and IAP mode are authorized.

The function Reinvoke is called and doesn't return (no error).

But the ISP tested with FlashMagic doesn't respond.

The bootloader is called, because if i set the ISP0 pin to low level, it's Ok.

But my need is to go in ISP mode without open the box and put the pin to ground.

Why when calling IAP with ispmode=6 the UART doesn't work ?

Does anyone have any advice ?

Thanks, Philippe

 

标签 (1)
0 项奖励
回复
5 回复数

832 次查看
Alice_Yang
NXP TechSupport
NXP TechSupport

Hello @gph 

 

I highly recommend you refer to: 

https://community.nxp.com/t5/LPC-Microcontrollers/Problem-with-ReinvokeISP-on-LPC54618/m-p/1351500  

 

Please contact me if still have issue. Thank you.

 

BR

Alice

0 项奖励
回复

825 次查看
gph
Contributor III
Hello,
Thanks.

I see this one and other post on forum, but no way.
My problem seems it's the bootloader who doesn't start in UART mode ...
Even when i specify mode 6.
0 项奖励
回复

800 次查看
Alice_Yang
NXP TechSupport
NXP TechSupport

Hello @gph 

 

Can UART PORT function properly with the ISP pin?

If yes, please  share your project  and  steps. I'd be glad to help you review them.

Thanks!

 

BR

Alice

0 项奖励
回复

729 次查看
gph
Contributor III

Hi,

Yes with ISP pin it's working well.

I can't post all project. But here after related things.

 

Electronic part :

gph_0-1747818098936.png

 

Code part : 

function called after reset and initialisation who start ISP if tag present in eeprom.

static void ISPCheck(void)
{
	uint8_t isp[3]={'?','?','?'};
	uint32_t st=0;
	uint8_t ispmode=6U;

	if(E2P_I2C_Read(EP2_ISPADDRESS, isp, sizeof(isp))==kStatus_Success)
	{
		if(isp[0]=='I' && isp[1]=='S' && isp[2]=='P')
		{
			LED_J_Set(false);
			isp[0]='?';
			isp[1]='?';
			isp[2]='?';
			E2P_I2C_Write(EP2_ISPADDRESS, isp, sizeof(isp));
			//delayms(100);
			//CLI_DirectPrintLine("!!! MODE ISP !!!");
			USART_Deinit(FLEXCOMM0_PERIPHERAL);
			//delayms(100);
			//__disable_irq();
			GPIO_PinWrite(GPIO, 0, 4, 0);
			delayms(100);
		    IAP_ReinvokeISP(ispmode, &st);	// Ne retourne pas si OK
		    CLI_DirectPrintLine("ISP : Fail !");
		}
//		else
//			CLI_DirectPrintLine("ISP : No request");
	}
	else
		CLI_DirectPrintLine("ISP : Read Error");
}

 

 

 

0 项奖励
回复

722 次查看
Alice_Yang
NXP TechSupport
NXP TechSupport

Hello @gph 

I reviewed the content you shared。

I recommend debugging the code step-by-step to check the value of the variable ispmode before calling IAP_ReinvokeISP(ispmode, &st).

Additionally, use logic analysis to measure the signals on UART0 TX/RX and verify their integrity.

I also suggest you testing the demo first via the link below:

https://community.nxp.com/t5/LPC-Microcontrollers-Knowledge/LPC54XXX-How-To-Use-USB-Port-To-Update-F... 

 

BR

Alice

0 项奖励
回复