This commit is contained in:
2024-10-24 01:16:25 +07:00
parent 40a6b71865
commit 6bef3f45cd
5 changed files with 84 additions and 80 deletions

13
spot.go
View File

@ -25,7 +25,7 @@ type TelnetSpot struct {
CallsignWorked bool
}
func ProcessTelnetSpot(re *regexp.Regexp, spotRaw string, SpotChan chan TelnetSpot, Countries Countries) {
func ProcessTelnetSpot(re *regexp.Regexp, spotRaw string, SpotChanToFlex chan TelnetSpot, SpotChanToHTTPServer chan TelnetSpot, Countries Countries) {
match := re.FindStringSubmatch(spotRaw)
if len(match) != 0 {
@ -76,7 +76,14 @@ func ProcessTelnetSpot(re *regexp.Regexp, spotRaw string, SpotChan chan TelnetSp
}
// send spot to SpotChan to Flex Client to send the spot to Flex radio
SpotChan <- spot
if Cfg.General.FlexRadioSpot {
SpotChanToFlex <- spot
}
// send FlexSpot to HTTP Server
if Cfg.General.HTTPServer {
SpotChanToHTTPServer <- spot
}
if spot.NewDXCC {
Log.Debugf("(** New DXCC **) DX: %s - Spotter: %s - Freq: %s - Band: %s - Mode: %s - Comment: %s - Time: %s - Command: %v, FlexSpot: %v",
@ -195,7 +202,7 @@ func (spot *TelnetSpot) GuessMode() {
if freqInt >= 7074 && freqInt < 7078 {
spot.Mode = "FT8"
}
if freqInt >= 7078 && freqInt <= 7200 {
if freqInt >= 7078 && freqInt <= 7300 {
spot.Mode = "LSB"
}
case "30M":