|
Paparazzi UAS
v5.18.0_stable
Paparazzi is a free software Unmanned Aircraft System.
|
Go to the documentation of this file.
33 #if defined(USE_PIPE0_WRITER) || defined(USE_PIPE0_READER)
37 #ifdef USE_PIPE0_WRITER
38 PRINT_CONFIG_VAR(USE_PIPE0_WRITER)
41 #ifdef USE_PIPE0_READER
42 PRINT_CONFIG_VAR(USE_PIPE0_READER)
45 #if defined(USE_PIPE1_WRITER) || defined(USE_PIPE1_READER)
49 #ifdef USE_PIPE1_WRITER
50 PRINT_CONFIG_VAR(USE_PIPE1_WRITER)
53 #ifdef USE_PIPE1_READER
54 PRINT_CONFIG_VAR(USE_PIPE1_READER)
57 #if defined(USE_PIPE2_WRITER) || defined(USE_PIPE2_READER)
61 #ifdef USE_PIPE2_WRITER
62 PRINT_CONFIG_VAR(USE_PIPE2_WRITER)
65 #ifdef USE_PIPE2_READER
66 PRINT_CONFIG_VAR(USE_PIPE2_READER)
75 p->rx_extract_idx = 0;
77 p->device.periph = (
void *)
p;
97 return available >= len ? available : 0;
111 p->tx_buf[
p->tx_insert_idx] = data;
121 memcpy(&(
p->tx_buf[
p->tx_insert_idx]), data, len);
122 p->tx_insert_idx += len;
void WEAK pipe_put_buffer(struct pipe_periph *p, long fd, const uint8_t *data, uint16_t len)
uint8_t pipe_getch(struct pipe_periph *p)
Get the last character from the receive buffer.
int WEAK pipe_check_free_space(struct pipe_periph *p, long *fd, uint16_t len)
Check if there is enough free space in the transmit buffer.
#define PIPE_TX_BUFFER_SIZE
arch independent PIPE API
int pipe_char_available(struct pipe_periph *p)
Get number of bytes available in receive buffer.
void pipe_send_message(struct pipe_periph *p, long fd)
Send a message.
void pipe_periph_init(struct pipe_periph *p, char *read_name, char *write_name)
Initialize the PIPE peripheral.
void pipe_arch_periph_init(struct pipe_periph *p, char *read_name, char *write_name)
Initialize the PIPE peripheral.
void WEAK pipe_put_byte(struct pipe_periph *p, long fd, uint8_t data)
Add one data byte to the tx buffer.