mirror of
https://github.com/tio/tio.git
synced 2026-05-01 23:07:58 +02:00
Add visual or audible alert support on connect/disconnect
The feature is detailed via the following option:
--alert none|bell|blink
Set alert action on connect/disconnect.
It will sound the bell once or blink once on successful connect.
Likewise it will sound the bell twice or blink twice on disconnect.
Default value is "none" for no alert.
This commit is contained in:
parent
68fc159654
commit
dbc9a8e82d
12 changed files with 195 additions and 7 deletions
|
|
@ -26,6 +26,7 @@
|
|||
#include <limits.h>
|
||||
#include <termios.h>
|
||||
#include <sys/param.h>
|
||||
#include "alert.h"
|
||||
|
||||
enum timestamp_t
|
||||
{
|
||||
|
|
@ -75,6 +76,7 @@ struct option_t
|
|||
uint32_t rs485_config_flags;
|
||||
int32_t rs485_delay_rts_before_send;
|
||||
int32_t rs485_delay_rts_after_send;
|
||||
enum alert_t alert;
|
||||
};
|
||||
|
||||
extern struct option_t option;
|
||||
|
|
@ -84,3 +86,4 @@ void options_parse(int argc, char *argv[]);
|
|||
void options_parse_final(int argc, char *argv[]);
|
||||
|
||||
void line_pulse_duration_option_parse(const char *arg);
|
||||
enum alert_t alert_option_parse(const char *arg);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue