Wirepas SDK
waps_uart.h
Go to the documentation of this file.
1 /* Copyright 2017 Wirepas Ltd. All Rights Reserved.
2  *
3  * See file LICENSE.txt for full license details.
4  *
5  */
6 
7 #ifndef APP_WAPSUART_H__
8 #define APP_WAPSUART_H__
9 
10 #include <stdbool.h>
11 #include <stdint.h>
12 #include "waps/comm/waps_comm.h"
13 
39 bool Waps_uart_init(new_frame_cb_f frame_cb,
40  uint32_t baud,
41  bool flow_ctrl,
42  void * tx_buffer,
43  void * rx_buffer);
44 
49 void Waps_uart_powerReset(void);
50 
59 bool Waps_uart_send(const void * buffer, uint32_t size);
60 
65 void Waps_uart_flush(void);
66 
74 void Waps_uart_setIrq(bool state);
75 
79 void Waps_uart_AutoPowerOn(void);
80 
84 void Waps_uart_AutoPowerOff(void);
85 
89 void Waps_uart_keepPowerOn(void);
90 
94 void Waps_uart_powerOff(void);
95 
99 uint32_t Waps_uart_powerExec(void);
100 
104 void Waps_uart_clean(void);
105 #endif
Waps_uart_AutoPowerOff
void Waps_uart_AutoPowerOff(void)
Disable automatic RX power.
waps_comm.h
Waps_uart_powerOff
void Waps_uart_powerOff(void)
Grafecully power down UART, if autopower-feature is used.
Waps_uart_powerExec
uint32_t Waps_uart_powerExec(void)
Callback task for power manager.
Waps_uart_powerReset
void Waps_uart_powerReset(void)
Power config. Disable UART auto-powering on Sinks and LL Nodes.
Waps_uart_clean
void Waps_uart_clean(void)
Clean waps from old data.
Waps_uart_AutoPowerOn
void Waps_uart_AutoPowerOn(void)
Enable automatic RX power.
new_frame_cb_f
bool(* new_frame_cb_f)(void *, uint32_t)
Definition: waps_comm.h:14
Waps_uart_send
bool Waps_uart_send(const void *buffer, uint32_t size)
WAPS UART send, send a block of data via serial port Automatically applies SLIP encoding to data and ...
Waps_uart_setIrq
void Waps_uart_setIrq(bool state)
Set indication that something is pending.
Waps_uart_init
bool Waps_uart_init(new_frame_cb_f frame_cb, uint32_t baud, bool flow_ctrl, void *tx_buffer, void *rx_buffer)
WAPS UART initialize, after this, WAPS UART is ready to transmit and receive serial data.
Waps_uart_keepPowerOn
void Waps_uart_keepPowerOn(void)
Keep power on (receiver is receiving)
Waps_uart_flush
void Waps_uart_flush(void)
Flush UART module TX buffer. Waits for operation (pend) to complete before returning.