| | |
| | | * Return : |
| | | * Author : hido.ltd |
| | | *******************************************************************************/ |
| | | |
| | | extern void delay_ms(uint32_t nTimer) ; |
| | | extern uint8_t lora_sendfinal_rx_bag_flag; |
| | | void Lora_Poll(void) |
| | | { |
| | | HIDO_UINT8 u8Byte = 0; |
| | |
| | | memset(&lora_rxbuf,0,sizeof(lora_rxbuf)); |
| | | lora_rxbufnum=0; |
| | | } |
| | | } |
| | | } |
| | | memcpy(&lora_recv_devid,&lora_rxbuf[2],2); |
| | | if(lora_recv_devid==dev_id) |
| | | { |
| | |
| | | memset(&lora_rxbuf,0,sizeof(lora_rxbuf)); |
| | | lora_rxbufnum=0; |
| | | lora_sendfinalbag_flag=0; |
| | | lora_sendfinal_rx_bag_flag=0; |
| | | } |
| | | if(lora_rxbuf[4]==0x02)//接收下发修改GPS开关时间参数 |
| | | { |
| | | memcpy(&lora_recv_gpstime,&lora_rxbuf[5],2); |
| | | if(lora_recv_gpstime<=1800) |
| | | lora_recv_gpstime=1800; |
| | | g_com_map[GPS_ONTIME]=lora_recv_gpstime; |
| | | save_com_map_to_flash(); |
| | | delay_ms(100); |
| | |
| | | if(lora_rxbuf[4]==0x03)//接收下发修改静止休眠时间参数 |
| | | { |
| | | memcpy(&lora_recv_gpstime,&lora_rxbuf[5],2); |
| | | if(lora_recv_gpstime<=10) |
| | | lora_recv_gpstime=10; |
| | | g_com_map[NOMOVESLEEP_TIME]=lora_recv_gpstime; |
| | | save_com_map_to_flash(); |
| | | delay_ms(100); |