| | |
| | | #include "HIDO_Timer.h" |
| | | #include "TCPClient.h" |
| | | #include "mk_spi.h" |
| | | #include "pan_port.h" |
| | | //#include "pan_port.h" |
| | | #include "mk_timer.h" |
| | | //#include "pan_param.h" |
| | | //#include "pan_rf.h" |
| | | #include "lora_3029.h" |
| | | #include "lora_1268.h" |
| | | //#include "pan_rf.h" |
| | | #include "PCA9555.h" |
| | | #include "mk_phy.h" |
| | | #include "HIDO_Timer.h" |
| | | #define DEBUG_MODE |
| | | extern int simple_main(void); |
| | | extern int temp_main(void); |
| | |
| | | #define WARING_LIMIT_TIME 10 |
| | | #define UPDATE_TIME 10 |
| | | |
| | | /****************************************************************引脚宏定义**************************************************/ |
| | | #define ADC_PIN IO_PIN_0 |
| | | #define UART0_TX IO_PIN_5 |
| | | #define UART0_RX IO_PIN_6 |
| | | #define UART1_TX IO_PIN_1 |
| | | #define UART1_RX IO_PIN_14 |
| | | |
| | | |
| | | /****************************************************************引脚宏定义**************************************************/ |
| | | void test_Delay_us(uint16_t time); |
| | | void Lora_UploadHeartBeartPoll(void); |
| | | extern uint8_t mUsartReceivePack[100]; |
| | | extern uint8_t mUsart2ReceivePack[150]; |
| | | extern uint8_t state5V_prase_flag,gps_prase_flag; |
| | | extern int distance; |
| | | extern uint8_t anchordata_num; |
| | | extern uint8_t anchordata_num; //bat_percent |
| | | uint32_t dev_id; |
| | | uint8_t group_id; |
| | | uint16_t tag_frequency; |
| | |
| | | { |
| | | uart_receive(UART_ID1,m_EUART_DMA_RXBuf,EUART_RX_BUF_SIZE,uart_receive_callback); |
| | | } |
| | | |
| | | static void adc_callback(void *data, uint32_t number) |
| | | { |
| | | uint32_t *result = (uint32_t *)data; |
| | |
| | | } |
| | | // LOG_INFO(TRACE_MODULE_APP, "The voltage is %%%d \r\n",bat_percent); |
| | | } |
| | | //static void timer_callback(void *dev, uint32_t time) |
| | | //{ |
| | | // enum TIMER_DEV_T id = *(enum TIMER_DEV_T *)dev; |
| | | // LOG_INFO(TRACE_MODULE_APP, "Timer %d elapsed time %d\r\n", id, time); |
| | | //} |
| | | //void UartInit(void) |
| | | //{ |
| | | //board_pins_config(); |
| | |
| | | nomove_count++; |
| | | } |
| | | uint8_t flag_sleeptimer,flag_secondtask,secondtask_count; |
| | | uint8_t lora_wg_up=0; |
| | | extern uint8_t lora_tx_flag; |
| | | static void sleep_timer_callback(void *dev, uint32_t time) |
| | | { |
| | | g_start_send_flag=1; |
| | | // #ifdef DEBUG_BOXING |
| | | //// gpio_pin_clr(IO_PIN_5);//测试 |
| | | // gpio_pin_set(IO_PIN_5);//测试 |
| | | // lora_wg_up=1; |
| | | |
| | | lora_tx_flag++; |
| | | // lora_qiehuan++; |
| | | // IO_control_init(); |
| | | // UWBPoll(); |
| | | // |
| | |
| | | //GPS工作逻辑 |
| | | |
| | | } |
| | | |
| | | void phy_timer_callback(uint32_t time) |
| | | { |
| | | lora_tx_flag++; |
| | | } |
| | | |
| | | void uart0_receive_callback() |
| | | { |
| | | uart_receive(UART_ID0,m_EUART_DMA_RXBuf,EUART_RX_BUF_SIZE,uart0_receive_callback); |
| | | } |
| | | |
| | | |
| | | static void voltage_input_handler(enum IO_PIN_T pin) |
| | | { |
| | | |
| | | } |
| | | static void move_handler(enum IO_PIN_T pin) |
| | | { |
| | | nomove_count=0; |
| | | } |
| | | |
| | | uint8_t flag_4G_recdata; |
| | | static void _4gUsart_handler(enum IO_PIN_T pin) |
| | | { |
| | |
| | | { |
| | | Usart1ParseDataCallback = UsartParseDataHandler;//需改为默认为gps处理,UsartParseDataHandler为升级处理当调试时候改为 |
| | | parameter_init_anchor();//g_com_map表初始化角色默认为基站 |
| | | g_com_map[DEV_ID]=0x6789; |
| | | g_com_map[GROUP_ID]=9; |
| | | g_com_map[DEV_ID]=0x1234; |
| | | // g_com_map[GROUP_ID]=1; |
| | | dev_id=g_com_map[DEV_ID];//这里不太对 |
| | | group_id=g_com_map[GROUP_ID];//组ID |
| | | tag_frequency = 1000/g_com_map[COM_INTERVAL];//测距频率这个存的是测距时间 |
| | |
| | | port = g_com_map[TCP_PORT]; |
| | | g_com_map[VERSION] = (1<<8)|11; |
| | | LOG_INFO(TRACE_MODULE_APP,"设备ID: %x .\r\n",dev_id); |
| | | LOG_INFO(TRACE_MODULE_APP,"固件版本:UWB-4G手环 V%d.%d. \r\n",g_com_map[VERSION]>>8,g_com_map[VERSION]&0xff); |
| | | LOG_INFO(TRACE_MODULE_APP,"固件版本:BGK-mk+蓝牙V%d.%d. \r\n",g_com_map[VERSION]>>8,g_com_map[VERSION]&0xff); |
| | | LOG_INFO(TRACE_MODULE_APP,"服务器地址: %d.%d.%d.%d:%d.\r\n",ip0,ip1,ip2,ip3,port); |
| | | } |
| | | |
| | | |
| | | |
| | | void IdleTask(void) |
| | | { |
| | | if(gpio_pin_get_val(INPUT_5V_Pin)) |
| | | { |
| | | |
| | | if(state5v==0) |
| | | { |
| | | state5v=1; |
| | | state5V_prase_flag=state5v; |
| | | gps_prase_flag=0;//解除gps解析 |
| | | uart1_change_from_gps_to_debug();//测试 |
| | | // uart_receive(UART_ID1,m_EUART_DMA_RXBuf,EUART_RX_BUF_SIZE,uart_receive_callback);//开启dma |
| | | //UartInit(); |
| | | } |
| | | |
| | | //UART_CheckSend(); |
| | | } else { |
| | | if(state5v==1) |
| | | { |
| | | g_com_map[MODBUS_MODE] = 0; |
| | | state5v=0; |
| | | state5V_prase_flag=state5v; |
| | | gps_prase_flag=1;//恢复gps解析 |
| | | uart1_change_from_debug_to_gps();//测试 |
| | | // uart_receive(UART_ID1,m_EUART_DMA_RXBuf,EUART_RX_BUF_SIZE,uart_receive_callback);//开启dma |
| | | //UartDeinit(); |
| | | } |
| | | } |
| | | UART_CheckReceive(); |
| | | { |
| | | UART0_CheckReceive(); |
| | | } |
| | | |
| | | int bind_check(void) |
| | | { |
| | | if(g_com_map[BIND_DEV_ID]!=0x00) |
| | |
| | | uart_close(UART_ID1);//解绑原来串口1 |
| | | uart_close(UART_ID0);//解绑原来串口0 |
| | | } |
| | | void test_Delay_us(uint16_t time) |
| | | { |
| | | for(int i=time;i>0;i--) |
| | | { |
| | | for(int j=1;j>0;j--) |
| | | { |
| | | __NOP(); |
| | | } |
| | | } |
| | | |
| | | } |
| | | #define TEST_SPI_MASTER 0 |
| | | #define TEST_SPI_POLL_MODE 0 |
| | | #define TEST_SPI_INTERUPT_MODE 1 |
| | | #define TEST_SPI_DMA_MODE 2 |
| | | #define TEST_SPI_MODE TEST_SPI_POLL_MODE |
| | | void spi_gpio_init() |
| | | |
| | | void Board_gpio_init() |
| | | { |
| | | // SPI0 MOSI/MISO/CLK/CS |
| | | //SPI0/MOSI/MISO/CLK/CS |
| | | io_pin_mux_set(LORA_CS, IO_FUNC0); |
| | | gpio_pin_set_dir(LORA_CS , GPIO_DIR_OUT, 0); |
| | | io_pull_set(LORA_CS, IO_HIGH_Z, IO_PULL_UP_NONE); |
| | | |
| | | |
| | | io_pin_mux_set(LORA_MOSI, IO_FUNC2); |
| | | io_pin_mux_set(LORA_MISO, IO_FUNC2); |
| | | io_pin_mux_set(LORA_CLK, IO_FUNC2); |
| | | io_pin_mux_set(LORA_DIO, IO_FUNC0);//spi中断 |
| | | io_pin_mux_set(LORA_DIO, IO_FUNC0); |
| | | |
| | | |
| | | // //ADC |
| | | // io_pin_mux_set(ADC_PIN, IO_FUNC1); |
| | | // io_pull_set(ADC_PIN, IO_HIGH_Z, IO_PULL_UP_NONE); |
| | | |
| | | //串口0 |
| | | io_pin_mux_set(UART0_RX, IO_FUNC4); |
| | | io_pin_mux_set(UART0_TX, IO_FUNC4); |
| | | |
| | | board_debug_console_open(TRACE_PORT_UART0); |
| | | uart_receive(UART_ID0,m_EUART_DMA_RXBuf,EUART_RX_BUF_SIZE,uart0_receive_callback);//开启dma |
| | | |
| | | //串口1 |
| | | io_pin_mux_set(UART1_RX, IO_FUNC4); |
| | | io_pin_mux_set(UART1_TX, IO_FUNC4); |
| | | } |
| | | void spi_init() |
| | | { |
| | |
| | | uint32_t successful_cnt=0; |
| | | uint8_t flag_4guart_needinit=0; |
| | | #define TX_LEN 10 |
| | | #define RX_LEN 10 |
| | | uint8_t tx_test_buf[TX_LEN] = {0, 1, 2, 3, 4, 5, 6, 7, 8, 9}; |
| | | uint8_t RF_RX_temp[RX_LEN]={0}; |
| | | #define RX_LEN 200 |
| | | |
| | | extern uint8_t RX_Buffer[RX_LEN]; |
| | | extern uint16_t BufferSize; |
| | | static uint16_t source_id; |
| | | extern struct RxDoneMsg RxDoneParams; |
| | | |
| | | |
| | | extern uint16_t current_count; |
| | | extern uint8_t rec_index,rec_secdelay; |
| | | extern uint8_t yuyin_no_sleep_flag,no_rx_flag; |
| | | |
| | | |
| | | /********************************************************************************************************/ |
| | | /********************************************************************************************************/ |
| | | /********************************************************************************************************/ |
| | | //static uint16_t delaytime = 771; |
| | | //extern uint16_t wg_report_freq,wg_report_id; |
| | | //extern uint32_t wg_lost_count; |
| | | //extern uint8_t shengji_flag; |
| | | //extern uint8_t lora_jianting_flag,report_ancnum; |
| | | //uint8_t imu_enable,motor_enable; |
| | | //uint32_t time_flag_lorarx=0; |
| | | //uint32_t lora_huanxing_count=0; |
| | | //uint16_t Lora_wangguanid=0; |
| | | //wg_state_enum wg_state = WG_Lost; |
| | | //uint16_t wangguan_up_id; |
| | | //uint8_t LoraUp_flag; |
| | | //uint16_t rec_wenjian_daxiao; |
| | | //uint16_t recnum[3]; |
| | | //uint16_t recv_flag=0; |
| | | //uint16_t tx_flag=0; |
| | | //uint16_t CRC16=0; |
| | | //uint16_t DEST_ID=0; |
| | | //uint16_t rec_value,rec_delaytime,rx_count,datalen_offset; |
| | | //uint16_t Loratx_flag=0; |
| | | //uint16_t Lorarx_flag=0; |
| | | //uint16_t Lorarx_time_out_flag=0; |
| | | //uint8_t tx_buf[5]={0,1,0,1,1}; |
| | | //uint32_t sleep_time_count=0; |
| | | //uint32_t uwb_ceju_count=0; |
| | | wg_state_enum wg_state = WG_Lost; |
| | | /********************************************************************************************************/ |
| | | static void Lora_irq_handler(enum IO_PIN_T pin) |
| | | { |
| | | ceshi++; |
| | | rf_irq_process(); |
| | | //g_start_send_flag=1; |
| | | // if(rf_get_transmit_flag() == RADIO_FLAG_TXDONE) |
| | | // { |
| | | // rf_set_transmit_flag(RADIO_FLAG_IDLE); |
| | | // rf_enter_continous_rx(); |
| | | //// rf_delay_ms(1000); |
| | | //// if(rf_continous_tx_send_data(tx_test_buf, TX_LEN) != OK) |
| | | //// { |
| | | ////// rf_enter_continous_rx(); |
| | | //// } |
| | | //// else |
| | | //// { |
| | | //// error_cnt ++; |
| | | //// } |
| | | // } |
| | | if(rf_get_recv_flag() == RADIO_FLAG_RXDONE) |
| | | { |
| | | rf_set_recv_flag(RADIO_FLAG_IDLE); |
| | | memcpy(RF_RX_temp,RxDoneParams.Payload,RxDoneParams.Size); |
| | | if(RF_RX_temp[0]==0x48&&RF_RX_temp[1]==0x58) |
| | | { |
| | | LORA_REV_uwb_up=1; |
| | | |
| | | } |
| | | // rf_enter_continous_rx(); //重新进入接收模式 |
| | | //UwbRange(); |
| | | // DDL_Printf("Rx : SNR: %f ,RSSI: %d \r\n", RxDoneParams.Snr, RxDoneParams.Rssi); |
| | | //int i=0; |
| | | // for(i = 0; i < RxDoneParams.Size; i++) |
| | | // { |
| | | // printf("0x%02x ", RxDoneParams.Payload[i]); |
| | | // } |
| | | // error_cnt ++; |
| | | } |
| | | if((rf_get_recv_flag() == RADIO_FLAG_RXTIMEOUT) || (rf_get_recv_flag() == RADIO_FLAG_RXERR)) |
| | | { |
| | | rf_set_recv_flag(RADIO_FLAG_IDLE); |
| | | } |
| | | { |
| | | RadioIrqProcess(); |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | void Board_LORA_NVIC_Init(GPIO_IRQ_HANDLER_T irq_handler) //LORA 中断配置 |
| | | { |
| | | // io_pin_mux_set(_4G_USART_RX_Pin,IO_FUNC0);//把原先io 变为普通GPIO |
| | |
| | | io_pull_set(LORA_DIO, IO_HIGH_Z, IO_PULL_UP_NONE); |
| | | gpio_enable_irq(LORA_DIO, GPIO_IRQ_TYPE_RISING_EDGE, irq_handler); |
| | | } |
| | | extern uint8_t pca9555writedata_input[10];//暂存输入寄存器所有配置的数组 |
| | | static void pca_handler(enum IO_PIN_T pin) |
| | | { |
| | | PCA9555_readdata(PCA9555_DEVICE_ADDR,pca9555writedata_input);//读输入寄存器的值 |
| | | check_input_change(); |
| | | } |
| | | uint8_t io14_state; |
| | | uint16_t lora_freq=0; |
| | | uint16_t lora_up_count=0; |
| | | uint8_t TXBuffer[8]={0,1,2,3,4,5,6,7}; |
| | | uint8_t test_buf[10]={0,1,1,1,1,1,1,1,1,1}; |
| | | int main(void) |
| | | { |
| | | board_clock_run(); |
| | | // boot_deinit(); |
| | | // board_pins_config(); |
| | | board_debug_console_open(TRACE_PORT_UART1); |
| | | // boot_deinit(); |
| | | // board_debug_console_open(TRACE_PORT_UART1); |
| | | // Reset reason |
| | | reset_cause_get(); |
| | | reset_cause_clear(); |
| | | |
| | | // Load calibration parameters from NVM |
| | | // uint32_t internal_flash = (REG_READ(0x40000018) >> 17) & 0x1; |
| | | // uint32_t external_flash = (REG_READ(0x40010030) >> 28) & 0x3; |
| | | // if (internal_flash || external_flash == 1) |
| | | // { |
| | | // WsfNvmInit(); |
| | | // board_calibration_params_load(); |
| | | // flash_close(FLASH_ID0); |
| | | // } |
| | | // else |
| | | // { |
| | | // board_calibration_params_default(); |
| | | // } |
| | | |
| | | reset_cause_clear(); |
| | | // Chip calibration |
| | | calib_chip(); |
| | | |
| | | // Disable watchdog timer |
| | | wdt_close(WDT_ID0); |
| | | // LOG_INFO(TRACE_MODULE_APP, "UWB simple example\r\n"); |
| | | |
| | | // open system timer |
| | | //sys_timer_open(); |
| | | |
| | | // // TODO 4G |
| | | // Uart_Register(UART_ID_4G, UART_ID0); |
| | | // Internet_Init(); |
| | | // TCPClient_Init(); |
| | | |
| | | gpio_open(); |
| | | |
| | | spi_gpio_init(); |
| | | Board_gpio_init(); |
| | | //board_led_init(); |
| | | |
| | | spi_init(); |
| | | Board_LORA_NVIC_Init(Lora_irq_handler); |
| | | Lora_init(); |
| | | rf_set_default_para(); |
| | | // |
| | | rf_enter_continous_rx(); |
| | | // rf_set_transmit_flag(RADIO_FLAG_TXDONE); |
| | | // rf_set_transmit_flag(RADIO_FLAG_TXDONE); |
| | | // if(rf_continous_tx_send_data(tx_test_buf, TX_LEN) != 0) |
| | | // { |
| | | // error_cnt++; |
| | | // } |
| | | // else |
| | | // { |
| | | // successful_cnt ++; |
| | | // } |
| | | |
| | | |
| | | // while (rf_get_transmit_flag() == RADIO_FLAG_IDLE) ; |
| | | // |
| | | // rf_set_transmit_flag(RADIO_FLAG_IDLE); |
| | | |
| | | // adc_open(&usr_adc_cfg); |
| | | // IIC2_Init(); |
| | | // Accelerometer_Init(); |
| | | // IO_control_init(); |
| | | // io_pin_mux_set(SCL_PIN, IO_FUNC0);//测试测距波形 |
| | | // gpio_pin_set_dir(SCL_PIN , GPIO_DIR_OUT, 0); |
| | | // io_pull_set(SCL_PIN , IO_PULL_DOWN, IO_PULL_UP_LEVEL4); |
| | | // gps_air780_power_change(0,1);//开启gps,4G |
| | | ////加速度计初始化必须在IO_control_init之前因为复用SDA引脚 |
| | | // adc_get(&sample[0], NUM_SAMPLES, adc_callback);//adc采样 |
| | | Program_Init(); |
| | | // uart_receive(UART_ID1,m_EUART_DMA_RXBuf,EUART_RX_BUF_SIZE,uart_receive_callback); |
| | | // |
| | | //// Initialize low power mode |
| | | // power_init(); |
| | | // AIR780E_Reset(); //4G模块重启,耗时1.5秒,这个是无法同步的关键 |
| | | sleep_timer_open(true, SLEEP_TIMER_MODE_RELOAD, sleep_timer_callback); |
| | | IIC2_Init(); |
| | | Accelerometer_Init(); |
| | | PCA9555_init(); |
| | | Lora_1268_Init(); |
| | | SwitchLoraSettings(478,7,22); |
| | | Program_Init(); |
| | | |
| | | sleep_timer_start(__MS_TO_32K_CNT(1000));//测试 |
| | | #ifdef DEBUG_BOXING |
| | | io_pin_mux_set(IO_PIN_5,IO_FUNC0); |
| | | gpio_pin_set_dir(IO_PIN_5,GPIO_DIR_OUT,0); |
| | | io_pull_set(IO_PIN_5,IO_PULL_DOWN,IO_PULL_UP_LEVEL4); |
| | | #endif |
| | | // board_acceleration_detection_init(move_handler); |
| | | sleep_timer_open(true, SLEEP_TIMER_MODE_RELOAD, sleep_timer_callback); |
| | | sleep_timer_start(__MS_TO_32K_CNT(1000));//测试 |
| | | |
| | | |
| | | Uwbinit(); |
| | | while (1) |
| | | { |
| | | if(LORA_REV_uwb_up) |
| | | { |
| | | LORA_REV_uwb_up=0; |
| | | UwbRange(); |
| | | } |
| | | if(g_start_send_flag) |
| | | { |
| | | g_start_send_flag=0; |
| | | |
| | | } |
| | | |
| | | |
| | | // UwbRange(); |
| | | // rf_irq_process(); |
| | | // if(rf_get_transmit_flag() == RADIO_FLAG_TXDONE) |
| | | // { |
| | | // rf_set_transmit_flag(RADIO_FLAG_IDLE); |
| | | // rf_delay_ms(1000); |
| | | // if(rf_continous_tx_send_data(tx_test_buf, TX_LEN) != 0) |
| | | // { |
| | | // error_cnt++; |
| | | // } |
| | | // else |
| | | // { |
| | | // successful_cnt ++; |
| | | //// DDL_Printf("Tx cnt %d\r\n", cnt ); |
| | | // } |
| | | // } |
| | | |
| | | |
| | | //// |
| | | // |
| | | //// io14_state=gpio_pin_get_val(LORA_DIO); |
| | | // rf_set_transmit_flag(RADIO_FLAG_IDLE); |
| | | // rf_delay_ms(1000); |
| | | // rf_enter_continous_tx(); |
| | | //// rf_set_transmit_flag(RADIO_FLAG_TXDONE); |
| | | // if(rf_continous_tx_send_data(tx_test_buf, TX_LEN) != OK) |
| | | // { |
| | | //// rf_enter_continous_rx(); |
| | | // } |
| | | // else |
| | | // { |
| | | // successful_cnt ++; |
| | | // } |
| | | |
| | | |
| | | |
| | | |
| | | // while (rf_get_transmit_flag() == RADIO_FLAG_IDLE) ; |
| | | // |
| | | // rf_set_transmit_flag(RADIO_FLAG_IDLE); |
| | | |
| | | // if(flag_TCP_reconnectting||IfTCPConnected()) |
| | | // { |
| | | // |
| | | // // LOG_INFO(TRACE_MODULE_APP, "处理4G任务\r\n"); |
| | | // air780_led_on(); |
| | | // if(flag_4guart_needinit) |
| | | // { |
| | | // flag_4guart_needinit = 0; |
| | | // AIR780EUartInit(); |
| | | // } |
| | | // Internet_Poll(); |
| | | // HIDO_ATLitePoll(); |
| | | // HIDO_TimerPoll(); |
| | | // TCPClient_Poll(); |
| | | // air780_led_off(); |
| | | // } |
| | | // if(flag_secondtask) |
| | | // { |
| | | // flag_secondtask = 0; |
| | | // SecondTask(); |
| | | // } |
| | | // IdleTask(); |
| | | // //3种情况后都要发包和休眠 |
| | | // //if(send_flag){ |
| | | // //message_construct(); |
| | | // //send_udp; |
| | | // //air780_success_state=0;//关闭4G成功发送灯 |
| | | // //blink_led(&air780_success_state);//成功测距闪烁4G状态灯 |
| | | // //air780_success_state=0; |
| | | // //} |
| | | //#ifndef DEBUG_MODE |
| | | ////if(flag_sleeptimer) |
| | | // if(!gpio_pin_get_val(INPUT_5V_Pin)&&((IfTCPConnected()&&Socket_IsSendQueueEmpty(0))||!flag_TCP_reconnectting&&!IfTCPConnected())) //进入休眠条件(与关系,全满足才进):1.没有5V输入 2 TCP已连接时发送队列为空||TCP无连接时不在重连状态。 |
| | | // { |
| | | // if(!flag_4guart_needinit) |
| | | // { |
| | | // LOG_INFO(TRACE_MODULE_APP, "4G RX 中断打开\r\n"); |
| | | // board_4GUsart_detection_init(_4gUsart_handler); |
| | | |
| | | // } |
| | | // flag_sleeptimer =0; |
| | | // LOG_INFO(TRACE_MODULE_APP, "进入休眠\r\n"); |
| | | // flag_4guart_needinit = 1; |
| | | |
| | | // trace_flush(); |
| | | // uint32_t lock = int_lock(); |
| | | // //LOG_INFO(TRACE_MODULE_APP, "进入低功耗"); |
| | | // power_enter_power_down_mode(0); |
| | | // int_unlock(lock); |
| | | // } |
| | | //#endif |
| | | { |
| | | Lora_Tx_Poll(); |
| | | IdleTask(); |
| | | } |
| | | } |