From c348632b262c17121867457f685d06a3111727a2 Mon Sep 17 00:00:00 2001 From: Mike Black W9MDB Date: Tue, 14 Nov 2023 17:03:40 -0600 Subject: [PATCH] Add ptt_type to rig->caps when set so it can be queried correctly --- src/conf.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/conf.c b/src/conf.c index 99fad9154..c6e991c4f 100644 --- a/src/conf.c +++ b/src/conf.c @@ -514,26 +514,32 @@ static int frontend_set_conf(RIG *rig, token_t token, const char *val) if (!strcmp(val, "RIG")) { rs->pttport.type.ptt = RIG_PTT_RIG; + rig->caps->ptt_type = RIG_PTT_RIG; } else if (!strcmp(val, "RIGMICDATA")) { rs->pttport.type.ptt = RIG_PTT_RIG_MICDATA; + rig->caps->ptt_type = RIG_PTT_RIG_MICDATA; } else if (!strcmp(val, "DTR")) { rs->pttport.type.ptt = RIG_PTT_SERIAL_DTR; + rig->caps->ptt_type = RIG_PTT_SERIAL_DTR; } else if (!strcmp(val, "RTS")) { rs->pttport.type.ptt = RIG_PTT_SERIAL_RTS; + rig->caps->ptt_type = RIG_PTT_SERIAL_RTS; } else if (!strcmp(val, "Parallel")) { rs->pttport.type.ptt = RIG_PTT_PARALLEL; + rig->caps->ptt_type = RIG_PTT_PARALLEL; } else if (!strcmp(val, "CM108")) { rs->pttport.type.ptt = RIG_PTT_CM108; + rig->caps->ptt_type = RIG_PTT_CM108; } else if (!strcmp(val, "GPIO")) { @@ -542,6 +548,7 @@ static int frontend_set_conf(RIG *rig, token_t token, const char *val) else if (!strcmp(val, "GPION")) { rs->pttport.type.ptt = RIG_PTT_GPION; + rig->caps->ptt_type = RIG_PTT_GPION; } else if (!strcmp(val, "None")) {