ether2ser 0.1.0
Ethernet <-> synchronous V.24 bridge firmware for RP2040 + W5500
Loading...
Searching...
No Matches
cli_usb_cdc.c File Reference
#include "cli_usb_cdc.h"
#include <stddef.h>
#include <stdint.h>
#include <stdio.h>
#include <string.h>
#include "pico/error.h"
#include "pico/stdio.h"
#include "system/common.h"
#include "system/event_queue.h"
Include dependency graph for cli_usb_cdc.c:

Go to the source code of this file.

Macros

#define CLI_BUFFER_SIZE   128
 
#define CLI_EVENT_POOL_SIZE   EVENT_QUEUE_CAPACITY
 
#define ASCII_BACKSPACE   0x08
 
#define ASCII_DELETE   0x7F
 
#define ASCII_FIRST_PRINTABLE   32
 
#define ASCII_LAST_PRINTABLE   126
 
#define CLI_MAX_CHARS_PER_POLL   16U
 

Functions

void cli_poll (void)
 Poll USB CDC for CLI input, echo, and emit line events.
 

Macro Definition Documentation

◆ ASCII_BACKSPACE

#define ASCII_BACKSPACE   0x08

Definition at line 34 of file cli_usb_cdc.c.

◆ ASCII_DELETE

#define ASCII_DELETE   0x7F

Definition at line 35 of file cli_usb_cdc.c.

◆ ASCII_FIRST_PRINTABLE

#define ASCII_FIRST_PRINTABLE   32

Definition at line 36 of file cli_usb_cdc.c.

◆ ASCII_LAST_PRINTABLE

#define ASCII_LAST_PRINTABLE   126

Definition at line 37 of file cli_usb_cdc.c.

◆ CLI_BUFFER_SIZE

#define CLI_BUFFER_SIZE   128

Definition at line 32 of file cli_usb_cdc.c.

◆ CLI_EVENT_POOL_SIZE

#define CLI_EVENT_POOL_SIZE   EVENT_QUEUE_CAPACITY

Definition at line 33 of file cli_usb_cdc.c.

◆ CLI_MAX_CHARS_PER_POLL

#define CLI_MAX_CHARS_PER_POLL   16U

Definition at line 38 of file cli_usb_cdc.c.

Function Documentation

◆ cli_poll()

void cli_poll ( void  )

Poll USB CDC for CLI input, echo, and emit line events.

Definition at line 40 of file cli_usb_cdc.c.

References ASCII_BACKSPACE, ASCII_DELETE, ASCII_FIRST_PRINTABLE, ASCII_LAST_PRINTABLE, CLI_BUFFER_SIZE, CLI_EVENT_POOL_SIZE, CLI_MAX_CHARS_PER_POLL, EV_CLI_LINE, event_queue_push(), LOG_DEBUG, LOG_ERROR, LOG_PLAIN, and event_t::type.

Referenced by event_loop().

Here is the call graph for this function:
Here is the caller graph for this function: