From 22aee2ff31aa0eb7aae8b51e5ae3bc4939113737 Mon Sep 17 00:00:00 2001 From: Mike Black W9MDB Date: Mon, 7 Aug 2023 23:30:29 -0500 Subject: [PATCH] Update simulators --- simulators/simic7100.c | 1 + simulators/simic7300.c | 17 +++++++++++++++++ 2 files changed, 18 insertions(+) diff --git a/simulators/simic7100.c b/simulators/simic7100.c index f19b074c7..f05e44c44 100644 --- a/simulators/simic7100.c +++ b/simulators/simic7100.c @@ -200,6 +200,7 @@ void frameParse(int fd, unsigned char *frame, int len) frame[4] = 0xfb; frame[5] = 0xfd; + hl_usleep(20*1000); n = write(fd, frame, 6); break; diff --git a/simulators/simic7300.c b/simulators/simic7300.c index 8ac113245..be9f316ad 100644 --- a/simulators/simic7300.c +++ b/simulators/simic7300.c @@ -31,6 +31,7 @@ int civ_731_mode = 0; vfo_t current_vfo = RIG_VFO_A; int split = 0; int keyspd = 85; // 85=20WPM +int band=8; // we make B different from A to ensure we see a difference at startup float freqA = 14074000; @@ -365,6 +366,22 @@ void frameParse(int fd, unsigned char *frame, int len) case 0x1a: // miscellaneous things switch (frame[5]) { + case 0x01: // band + if (frame[6] == 0xfd) + { + frame[6] = band; + frame[7] = 0xfd; + n = write(fd,frame,8); + } + else + { + band = frame[6]; + printf("Band select=%d\n",band); + frame[4] = 0xfb; + frame[5] = 0xfe; + n = write(fd,frame,6); + } + break; case 0x03: // width if (current_vfo == RIG_VFO_A || current_vfo == RIG_VFO_MAIN) { frame[6] = widthA; } else { frame[6] = widthB; }