Documentation
¶
Index ¶
- Constants
- Variables
- func AbsoluteFilename() string
- func Directory() string
- type Data
- type LoadedConfiguration
- func (c *LoadedConfiguration) Contest() core.Contest
- func (c *LoadedConfiguration) HamlibAddress() string
- func (c *LoadedConfiguration) Keyer() core.Keyer
- func (c *LoadedConfiguration) KeyerHost() string
- func (c *LoadedConfiguration) KeyerPort() int
- func (c *LoadedConfiguration) KeyerPresets() []core.KeyerPreset
- func (c *LoadedConfiguration) KeyerType() core.KeyerType
- func (c *LoadedConfiguration) SpotSources() []core.SpotSource
- func (c *LoadedConfiguration) Station() core.Station
- func (c *LoadedConfiguration) TCIAddress() string
Constants ¶
View Source
const Filename = "hellocontest.json"
Variables ¶
View Source
var Default = Data{ Station: pb.Station{ Callsign: "DL0ABC", Operator: "DL1ABC", Locator: "AA00zz", }, Contest: pb.Contest{ Name: "Default", QsosGoal: 48, PointsGoal: 60, MultisGoal: 12, }, Keyer: pb.Keyer{ Wpm: 25, SpMacros: []string{ "{{.MyCall}}", "rr {{.MyReport}} {{.MyNumber}} {{.MyXchange}}", "tu gl", "nr {{.MyNumber}} {{.MyXchange}} {{.MyNumber}} {{.MyXchange}}", }, RunMacros: []string{ "cq {{.MyCall}} test", "{{.TheirCall}} {{.MyReport}} {{.MyNumber}} {{.MyXchange}}", "tu {{.MyCall}} test", "nr {{.MyNumber}} {{.MyXchange}} {{.MyNumber}} {{.MyXchange}}", }, }, KeyerPresets: []core.KeyerPreset{ { Name: "Default", SPMacros: []string{ "{{.MyCall}}", "rr {{.MyReport}} {{.MyNumber}} {{.MyXchange}}", "tu gl", "nr {{.MyNumber}} {{.MyXchange}} {{.MyNumber}} {{.MyXchange}}", }, RunMacros: []string{ "cq {{.MyCall}} test", "{{.TheirCall}} {{.MyReport}} {{.MyNumber}} {{.MyXchange}}", "tu {{.MyCall}} test", "nr {{.MyNumber}} {{.MyXchange}} {{.MyNumber}} {{.MyXchange}}", }, }, }, KeyerType: "tci", KeyerHost: "localhost", KeyerPort: 6789, HamlibAddress: "localhost:4532", TCIAddress: "localhost:40001", SpotSources: []core.SpotSource{ { Name: "Skimmer", HostAddress: "localhost:7373", Type: 2, Username: "dl0abc", }, }, }
Functions ¶
func AbsoluteFilename ¶ added in v0.3.0
func AbsoluteFilename() string
Types ¶
type Data ¶
type Data struct {
Station pb.Station
Contest pb.Contest
Keyer pb.Keyer
KeyerPresets []core.KeyerPreset `json:"keyer_presets"`
KeyerType core.KeyerType `json:"keyer_type"`
KeyerHost string `json:"keyer_host"`
KeyerPort int `json:"keyer_port"`
HamlibAddress string `json:"hamlib_address"`
TCIAddress string `json:"tci_address"`
SpotSources []core.SpotSource `json:"spot_sources"`
}
type LoadedConfiguration ¶
type LoadedConfiguration struct {
// contains filtered or unexported fields
}
func Load ¶
func Load() (*LoadedConfiguration, error)
Load loads the configuration from the default location (see github.com/ftl/cfg/LoadJSON()).
func (*LoadedConfiguration) Contest ¶ added in v0.6.0
func (c *LoadedConfiguration) Contest() core.Contest
func (*LoadedConfiguration) HamlibAddress ¶
func (c *LoadedConfiguration) HamlibAddress() string
func (*LoadedConfiguration) Keyer ¶ added in v0.6.0
func (c *LoadedConfiguration) Keyer() core.Keyer
func (*LoadedConfiguration) KeyerHost ¶
func (c *LoadedConfiguration) KeyerHost() string
func (*LoadedConfiguration) KeyerPort ¶
func (c *LoadedConfiguration) KeyerPort() int
func (*LoadedConfiguration) KeyerPresets ¶ added in v0.12.0
func (c *LoadedConfiguration) KeyerPresets() []core.KeyerPreset
func (*LoadedConfiguration) KeyerType ¶ added in v0.12.0
func (c *LoadedConfiguration) KeyerType() core.KeyerType
func (*LoadedConfiguration) SpotSources ¶ added in v0.13.0
func (c *LoadedConfiguration) SpotSources() []core.SpotSource
func (*LoadedConfiguration) Station ¶ added in v0.6.0
func (c *LoadedConfiguration) Station() core.Station
func (*LoadedConfiguration) TCIAddress ¶ added in v0.7.0
func (c *LoadedConfiguration) TCIAddress() string
Click to show internal directories.
Click to hide internal directories.