projects
/
fw
/
altos
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
altos: Make cmd echo per-connection instead of global
[fw/altos]
/
src
/
ao.h
diff --git
a/src/ao.h
b/src/ao.h
index 2d2bbf82ac247459cbf68f1e5e5101a28ba4886d..9b375894e0f20cd4c41aeaf110b88bbaed52324e 100644
(file)
--- a/
src/ao.h
+++ b/
src/ao.h
@@
-403,6
+403,14
@@
ao_cmd_register(__code struct ao_cmds *cmds);
void
ao_cmd_init(void);
void
ao_cmd_init(void);
+#if HAS_CMD_FILTER
+/*
+ * Provided by an external module to filter raw command lines
+ */
+uint8_t
+ao_cmd_filter(void);
+#endif
+
/*
* ao_dma.c
*/
/*
* ao_dma.c
*/
@@
-927,6
+935,9
@@
ao_serial_set_stdin(uint8_t stdin);
void
ao_serial_putchar(char c) __critical;
void
ao_serial_putchar(char c) __critical;
+void
+ao_serial_drain(void) __critical;
+
#define AO_SERIAL_SPEED_4800 0
#define AO_SERIAL_SPEED_9600 1
#define AO_SERIAL_SPEED_19200 2
#define AO_SERIAL_SPEED_4800 0
#define AO_SERIAL_SPEED_9600 1
#define AO_SERIAL_SPEED_19200 2
@@
-1167,8
+1178,10
@@
struct ao_stdio {
char (*pollchar)(void);
void (*putchar)(char c) __reentrant;
void (*flush)(void);
char (*pollchar)(void);
void (*putchar)(char c) __reentrant;
void (*flush)(void);
+ uint8_t echo;
};
};
+extern __xdata struct ao_stdio ao_stdios[];
extern __data int8_t ao_cur_stdio;
extern __data int8_t ao_num_stdios;
extern __data int8_t ao_cur_stdio;
extern __data int8_t ao_num_stdios;
@@
-1177,6
+1190,9
@@
flush(void);
extern __xdata uint8_t ao_stdin_ready;
extern __xdata uint8_t ao_stdin_ready;
+uint8_t
+ao_echo(void);
+
void
ao_add_stdio(char (*pollchar)(void),
void (*putchar)(char) __reentrant,
void
ao_add_stdio(char (*pollchar)(void),
void (*putchar)(char) __reentrant,