From 9ea4534803e193d02d54b24d7f879050a70e47e0 Mon Sep 17 00:00:00 2001 From: William Harrington Date: Tue, 14 Jan 2025 17:00:53 -0600 Subject: Add speak.conf and updates for setting flow control. Helpful when using different speech devices using different flow control methods. --- spo256/getspo.c | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) (limited to 'spo256/getspo.c') diff --git a/spo256/getspo.c b/spo256/getspo.c index 5ff64d7..de3eeeb 100644 --- a/spo256/getspo.c +++ b/spo256/getspo.c @@ -37,9 +37,22 @@ int getspo(CONFIG *cfg) fatal(EX_UNAVAILABLE, "spo256: %s: cannot access\n", p); stty = getstty(spo); interactive(stty, FALSE); - setflowctrl(stty, FC_HARD); continue; } + + if(NULL != (p = get_config(cfg, "flowctrl"))) + { + if(atol(p) == 0) + setflowctrl(stty, FC_NONE); + else if(atol(p) == 1) + setflowctrl(stty, FC_HARD); + else if(atol(p) == 2) + setflowctrl(stty, FC_SOFT); + else if(atol(p) == 3) + setflowctrl(stty, FC_FULL); + else + setflowctrl(stty, FC_NONE); + } if(NULL != (p = get_config(cfg, "speed"))) { -- cgit v1.2.3-54-g00ecf