修改驱动程序

This commit is contained in:
2584532475@qq.com committed 2023-05-19 18:02:00 +08:00
1 parent 063c3fcc07
commit a69c1a58d6
39 files changed
+1627 -641

No files matched your search

+13 -13
View File
@@ -38,7 +38,6 @@
* Output
* EVENT_OUT
* EXTI
PA4 ------> COMP_DAC11_group
PA5 ------> COMP_DAC12_group
*/
void MX_GPIO_Init(void)
@@ -57,6 +56,9 @@ void MX_GPIO_Init(void)
/*Configure GPIO pin Output Level */
HAL_GPIO_WritePin(ETH_RST_GPIO_Port, ETH_RST_Pin, GPIO_PIN_RESET);
/*Configure GPIO pin Output Level */
HAL_GPIO_WritePin(GPIOA, ETH_PW_Pin|GSM_PW_Pin, GPIO_PIN_RESET);
/*Configure GPIO pin Output Level */
HAL_GPIO_WritePin(GPIOB, U485_RT_Pin|LORA_TX_Pin|LORA_RX_Pin|SPI2_NSS_Pin, GPIO_PIN_RESET);
@@ -64,9 +66,6 @@ void MX_GPIO_Init(void)
HAL_GPIO_WritePin(GPIOE, LORA_M1_Pin|RELAY1_Pin|RELAY2_Pin|S4851_RT_Pin
|S4852_RT_Pin, GPIO_PIN_RESET);
/*Configure GPIO pin Output Level */
HAL_GPIO_WritePin(GSM_PW_GPIO_Port, GSM_PW_Pin, GPIO_PIN_RESET);
/*Configure GPIO pin Output Level */
HAL_GPIO_WritePin(GSM_RST_GPIO_Port, GSM_RST_Pin, GPIO_PIN_RESET);
@@ -84,10 +83,17 @@ void MX_GPIO_Init(void)
HAL_GPIO_Init(ETH_STA_GPIO_Port, &GPIO_InitStruct);
/*Configure GPIO pins : PAPin PAPin */
GPIO_InitStruct.Pin = DAC1_Pin|DAC2_Pin;
GPIO_InitStruct.Pin = ETH_PW_Pin|GSM_PW_Pin;
GPIO_InitStruct.Mode = GPIO_MODE_OUTPUT_PP;
GPIO_InitStruct.Pull = GPIO_NOPULL;
GPIO_InitStruct.Speed = GPIO_SPEED_FREQ_LOW;
HAL_GPIO_Init(GPIOA, &GPIO_InitStruct);
/*Configure GPIO pin : PtPin */
GPIO_InitStruct.Pin = DAC2_Pin;
GPIO_InitStruct.Mode = GPIO_MODE_ANALOG;
GPIO_InitStruct.Pull = GPIO_NOPULL;
HAL_GPIO_Init(GPIOA, &GPIO_InitStruct);
HAL_GPIO_Init(DAC2_GPIO_Port, &GPIO_InitStruct);
/*Configure GPIO pins : PBPin PBPin PBPin PBPin */
GPIO_InitStruct.Pin = U485_RT_Pin|LORA_TX_Pin|LORA_RX_Pin|SPI2_NSS_Pin;
@@ -111,13 +117,6 @@ void MX_GPIO_Init(void)
GPIO_InitStruct.Pull = GPIO_NOPULL;
HAL_GPIO_Init(LORA_DI0_GPIO_Port, &GPIO_InitStruct);
/*Configure GPIO pin : PtPin */
GPIO_InitStruct.Pin = GSM_PW_Pin;
GPIO_InitStruct.Mode = GPIO_MODE_OUTPUT_PP;
GPIO_InitStruct.Pull = GPIO_NOPULL;
GPIO_InitStruct.Speed = GPIO_SPEED_FREQ_LOW;
HAL_GPIO_Init(GSM_PW_GPIO_Port, &GPIO_InitStruct);
/*Configure GPIO pin : PtPin */
GPIO_InitStruct.Pin = GSM_RST_Pin;
GPIO_InitStruct.Mode = GPIO_MODE_OUTPUT_PP;
@@ -131,6 +130,7 @@ void MX_GPIO_Init(void)
GPIO_InitStruct.Pull = GPIO_NOPULL;
HAL_GPIO_Init(GPIOD, &GPIO_InitStruct);
}
/* USER CODE BEGIN 2 */