minor change
This commit is contained in:
parent
1140aa9a19
commit
e2a0f3c384
|
@ -94,10 +94,11 @@ void PWR_EnterStopMode(void)
|
|||
/* USER CODE BEGIN EnterStopMode_1 */
|
||||
|
||||
/* USER CODE END EnterStopMode_1 */
|
||||
HAL_GPIO_DeInit(GPIOA,GPIO_PIN_0);
|
||||
HAL_GPIO_WritePin(GPIOB, GPIO_PIN_All, GPIO_PIN_RESET);
|
||||
//HAL_GPIO_WritePin(GPIOC, GPIO_PIN_All, GPIO_PIN_RESET);
|
||||
HAL_GPIO_WritePin(GPIOA, GPIO_PIN_All, GPIO_PIN_RESET);
|
||||
HAL_GPIO_DeInit(GPIOA,GPIO_PIN_0);
|
||||
|
||||
HAL_SuspendTick();
|
||||
/* Clear Status Flag before entering STOP/STANDBY Mode */
|
||||
LL_PWR_ClearFlag_C1STOP_C1STB();
|
||||
|
|
|
@ -558,6 +558,7 @@ static void SendTxData(void)
|
|||
sensor_t sensor_data;
|
||||
UTIL_TIMER_Time_t nextTxIn = 0;
|
||||
|
||||
HAL_Delay(10); //eliminate bouncing back 5ms
|
||||
door_status = HAL_GPIO_ReadPin(GPIOA,GPIO_PIN_0);
|
||||
door_changed_flag = 0;
|
||||
if (door_status != door_previous_status)
|
||||
|
@ -701,11 +702,11 @@ static void OnTxTimerEvent(void *context)
|
|||
}
|
||||
#endif
|
||||
MX_GPIO_Init();
|
||||
door_status = HAL_GPIO_ReadPin(GPIOA,GPIO_PIN_0);
|
||||
//door_status = HAL_GPIO_ReadPin(GPIOA,GPIO_PIN_0);
|
||||
//door_changed_flag = 0;
|
||||
//if (door_status != door_previous_status)
|
||||
{
|
||||
door_previous_status = door_status;
|
||||
//door_previous_status = door_status;
|
||||
|
||||
|
||||
UTIL_SEQ_SetTask((1 << CFG_SEQ_Task_LoRaSendOnTxTimerOrButtonEvent), CFG_SEQ_Prio_0);
|
||||
|
|
Loading…
Reference in New Issue