Browse Source

Add rig settings for frequency and tone.

:wq
master
Jeroen Vreeken 2 years ago
parent
commit
cd136f225b
2 changed files with 29 additions and 0 deletions
  1. +4
    -0
      freedv_eth.conf
  2. +25
    -0
      io.c

+ 4
- 0
freedv_eth.conf View File

@ -46,6 +46,10 @@
#rig_ptt_type = NONE
#rig_dcd_type = NONE
#rig_conf_set = dtr_state ON
#rig_ctcss_sql = 719
#rig_ctcss_tone = 719
#rig_freq_rx = 145000000
#rig_freq_tx = 435000000
## Control text
## Use VC bits for control (1=VC bits, 0=data frames)


+ 25
- 0
io.c View File

@ -316,6 +316,31 @@ int io_hl_init(rig_model_t rig_model, int dcd_th, ptt_type_t ptt, char *ptt_file
return -2;
}
char *rig_ctcss_sql = freedv_eth_config_value("rig_ctcss_sql", NULL, NULL);
if (rig_ctcss_sql) {
printf("rig ctcss squelch: %s\n", rig_ctcss_sql);
tone_t tone = atoi(rig_ctcss_sql);
rig_set_ctcss_sql(rig, RIG_VFO_CURR, tone);
}
char *rig_ctcss_tone = freedv_eth_config_value("rig_ctcss_tone", NULL, NULL);
if (rig_ctcss_tone) {
printf("rig ctcss tone: %s\n", rig_ctcss_tone);
tone_t tone = atoi(rig_ctcss_tone);
rig_set_ctcss_tone(rig, RIG_VFO_CURR, tone);
}
char *rig_freq_rx = freedv_eth_config_value("rig_freq_rx", NULL, NULL);
if (rig_freq_rx) {
printf("rig frequency for rx: %s\n", rig_freq_rx);
freq_t freq = atof(rig_freq_rx);
rig_set_freq(rig, RIG_VFO_RX, freq);
}
char *rig_freq_tx = freedv_eth_config_value("rig_freq_tx", NULL, NULL);
if (rig_freq_tx) {
printf("rig frequency for tx: %s\n", rig_freq_tx);
freq_t freq = atof(rig_freq_tx);
rig_set_freq(rig, RIG_VFO_TX, freq);
}
/* Init to sane status */
rig_set_ptt(rig, RIG_VFO_CURR, RIG_PTT_OFF);
rig_get_dcd(rig, RIG_VFO_CURR, (dcd_t*)&rig_thread_dcd);


Loading…
Cancel
Save