| | |
| | | // LED_TR_OFF; |
| | | current_time=GetLPTime(); |
| | | //motor_state=2; |
| | | if(g_com_map[MOTOR_ONTIME]>0) |
| | | if(g_com_map[MOTOR_ONTIME_INDEX]>0) |
| | | { |
| | | g_com_map[MOTOR_ONTIME]--; |
| | | g_com_map[MOTOR_ONTIME_INDEX]--; |
| | | motor_state = 1; |
| | | } |
| | | switch(motor_state) |
| | |
| | | uint32_t temp; |
| | | extern uint8_t sleep_flag,m_bEUARTTxEn; |
| | | uint16_t waitusart_timer; |
| | | extern double pressure,temperature; |
| | | //void HAL_UART_RxCpltCallback(UART_HandleTypeDef *UartHandle) |
| | | //{ |
| | | // /* Set transmission flag: trasfer complete*/ |
| | |
| | | LED_LG_ON; |
| | | Program_Init(); |
| | | LIS3DH_Data_Init(); |
| | | BarInit(); |
| | | Dw1000_Init(); |
| | | Dw1000_App_Init(); |
| | | |
| | |
| | | { static uint16_t blink_count=0; |
| | | SystemClock_Config(); |
| | | g_start_send_flag = 0; |
| | | |
| | | GetPressAndTemp(); |
| | | // if(current_count>slot_startcount&¤t_count<slot_startcount+interval_count) |
| | | // { |
| | | // HAL_GPIO_WritePin(LED0_GPIO, GPIO_PIN_9, GPIO_PIN_SET); |