| @@ -7,3 +7,5 @@ build/ | |||||
| *.iq | *.iq | ||||
| *.raw | *.raw | ||||
| *.bak | *.bak | ||||
| *.zip | |||||
| *.exe | |||||
| @@ -153,9 +153,17 @@ func runTXMode(cfg cfgpkg.Config, driver platform.SoapyDriver, autoStart bool, a | |||||
| // OutputDrive controls composite signal level, NOT hardware gain. | // OutputDrive controls composite signal level, NOT hardware gain. | ||||
| // Hardware TX gain is always 0 dB (max power). Use external attenuator for power control. | // Hardware TX gain is always 0 dB (max power). Use external attenuator for power control. | ||||
| soapyCfg := platform.SoapyConfig{ | soapyCfg := platform.SoapyConfig{ | ||||
| Driver: cfg.Backend.Device, | |||||
| Driver: cfg.Backend.Driver, | |||||
| Device: cfg.Backend.Device, | |||||
| CenterFreqHz: cfg.FM.FrequencyMHz * 1e6, | CenterFreqHz: cfg.FM.FrequencyMHz * 1e6, | ||||
| GainDB: 0, // 0 dB = max TX power on PlutoSDR | GainDB: 0, // 0 dB = max TX power on PlutoSDR | ||||
| DeviceArgs: map[string]string{}, | |||||
| } | |||||
| if cfg.Backend.URI != "" { | |||||
| soapyCfg.DeviceArgs["uri"] = cfg.Backend.URI | |||||
| } | |||||
| for k, v := range cfg.Backend.DeviceArgs { | |||||
| soapyCfg.DeviceArgs[k] = v | |||||
| } | } | ||||
| soapyCfg.SampleRateHz = cfg.EffectiveDeviceRate() | soapyCfg.SampleRateHz = cfg.EffectiveDeviceRate() | ||||
| @@ -32,6 +32,9 @@ | |||||
| "backend": { | "backend": { | ||||
| "kind": "pluto", | "kind": "pluto", | ||||
| "device": "usb:", | "device": "usb:", | ||||
| "driver": "", | |||||
| "uri": "", | |||||
| "deviceArgs": {}, | |||||
| "outputPath": "", | "outputPath": "", | ||||
| "deviceSampleRateHz": 2280000 | "deviceSampleRateHz": 2280000 | ||||
| }, | }, | ||||
| @@ -50,10 +50,13 @@ type FMConfig struct { | |||||
| } | } | ||||
| type BackendConfig struct { | type BackendConfig struct { | ||||
| Kind string `json:"kind"` | |||||
| Device string `json:"device"` | |||||
| OutputPath string `json:"outputPath"` | |||||
| DeviceSampleRateHz float64 `json:"deviceSampleRateHz"` // actual SDR device rate; 0 = same as compositeRateHz | |||||
| Kind string `json:"kind"` | |||||
| Driver string `json:"driver,omitempty"` | |||||
| Device string `json:"device"` | |||||
| URI string `json:"uri,omitempty"` | |||||
| DeviceArgs map[string]string `json:"deviceArgs,omitempty"` | |||||
| OutputPath string `json:"outputPath"` | |||||
| DeviceSampleRateHz float64 `json:"deviceSampleRateHz"` // actual SDR device rate; 0 = same as compositeRateHz | |||||
| } | } | ||||
| type ControlConfig struct { | type ControlConfig struct { | ||||