Modify the PWEKEY and RESET_N pins of EC801E

This commit is contained in:
songyanguang
2025-06-18 11:21:23 +08:00
parent 2c647495af
commit 4eb5f245cb
4 changed files with 14 additions and 6 deletions
@@ -215,7 +215,8 @@ void InitBoardHardware() {
#ifdef BSP_USING_UART
InitHwUart();
InstallConsole("uart1", SERIAL_DRV_NAME_1, SERIAL_1_DEVICE_NAME_0);
KPrintf("console init completed.\n");
KPrintf("\nconsole init completed.\n");
KPrintf("compiled on: %s at %s\n", __DATE__, __TIME__);
#endif
readRomConfiguration(); // 读取配置信息到外部变量CFG中
@@ -315,12 +315,19 @@ int InitHwLte(void) {
USART_Cmd(USART2, ENABLE);
/* Enable module pin */
GPIO_InitStructure_Lte.GPIO_Pin = GPIO_Pin_7;
GPIO_InitStructure_Lte.GPIO_Speed = GPIO_Speed_50MHz;
GPIO_InitStructure_Lte.GPIO_Mode = GPIO_Mode_Out_PP;
GPIO_Init(GPIOA, &GPIO_InitStructure_Lte);
GPIO_SetBits(GPIOA, GPIO_Pin_7);
Delay_Ms(500); // >= 300ms
GPIO_ResetBits(GPIOA, GPIO_Pin_7);
GPIO_InitStructure_Lte.GPIO_Pin = GPIO_Pin_6;
GPIO_InitStructure_Lte.GPIO_Speed = GPIO_Speed_50MHz;
GPIO_InitStructure_Lte.GPIO_Mode = GPIO_Mode_Out_PP;
GPIO_Init(GPIOA, &GPIO_InitStructure_Lte);
GPIO_SetBits(GPIOA, GPIO_Pin_6);
Delay_Ms(2000);
Delay_Ms(1000); // >= 500ms
GPIO_ResetBits(GPIOA, GPIO_Pin_6);
return ret;