| | |
| | | HIDO_INT32 AIR780EDriver_PowerOn(void) |
| | | { |
| | | air780_power_state = 1; |
| | | |
| | | update_led_power_state(); |
| | | return HIDO_OK; |
| | | } |
| | | |
| | |
| | | HIDO_INT32 AIR780EDriver_PowerOff(void) |
| | | { |
| | | air780_power_state = 0; |
| | | |
| | | update_led_power_state(); |
| | | return HIDO_OK; |
| | | } |
| | | |
| | |
| | | * Author : 杜键 |
| | | * Modified Date: : 2018年5月22日 |
| | | *******************************************************************************/ |
| | | void AIR780EUartInit(void) |
| | | { |
| | | io_pin_mux_set(_4G_USART_RX_Pin,IO_FUNC4); |
| | | ST_UartInit stUartInit; |
| | | |
| | | /* 串口初始化 */ |
| | | stUartInit.m_eRxMode = UART_RX_MODE_INT; |
| | | stUartInit.m_eTxMode = UART_TX_MODE_POLL; |
| | | stUartInit.m_pu8RxBuf = l_au8AIR780EUartRxBuf; |
| | | stUartInit.m_u32RxBufSize = AIR780E_UART_RX_BUF_SIZE; |
| | | stUartInit.m_pu8TxBuf = l_au8AIR780EUartTxBuf; |
| | | stUartInit.m_u32TxBufSize = AIR780E_UART_TX_BUF_SIZE; |
| | | stUartInit.m_u32TxQueueMemberCnt = AIR780E_UART_TX_QUEUE_MEMBER_CNT; |
| | | stUartInit.m_u32BaudRate = 9600; |
| | | if(Uart_Init(UART_ID_4G, &stUartInit) != HIDO_OK) |
| | | { |
| | | |
| | | } |
| | | } |
| | | HIDO_INT32 AIR780EDriver_Init(void) |
| | | { |
| | | ST_UartInit stUartInit; |
| | |
| | | stUartInit.m_pu8TxBuf = l_au8AIR780EUartTxBuf; |
| | | stUartInit.m_u32TxBufSize = AIR780E_UART_TX_BUF_SIZE; |
| | | stUartInit.m_u32TxQueueMemberCnt = AIR780E_UART_TX_QUEUE_MEMBER_CNT; |
| | | stUartInit.m_u32BaudRate = 115200; |
| | | stUartInit.m_u32BaudRate = 9600; |
| | | if(Uart_Init(UART_ID_4G, &stUartInit) != HIDO_OK) |
| | | { |
| | | return HIDO_ERR; |