Documentation ¶
Index ¶
- Variables
- func CampaignId() string
- func Err() <-chan error
- func Init(config *koanf.Koanf) error
- func Output() <-chan string
- func WithAggregated(amr types.AggregatedMeasurementRequest, flags ...CommandFlags) *sensorManager
- func WithRaw(rmr types.RawMeasurementRequest, flags ...CommandFlags) *sensorManager
- type CommandFlags
- type StatusEnum
Constants ¶
This section is empty.
Variables ¶
View Source
var DefaultFlags = CommandFlags{
Command: "orfs_sensor",
}
Functions ¶
func CampaignId ¶
func CampaignId() string
Returns the current campaign ID (assigned by the backend).
func Init ¶
Initializes a SensorManager singleton. Also loads default command line flags from the configuration.
func Output ¶
func Output() <-chan string
Open channel where command output is sent after completion.
func WithAggregated ¶
func WithAggregated(amr types.AggregatedMeasurementRequest, flags ...CommandFlags) *sensorManager
Starts an aggregated measurement campaign by running orfs_sensor with the given flags.
func WithRaw ¶
func WithRaw(rmr types.RawMeasurementRequest, flags ...CommandFlags) *sensorManager
Starts a raw measurement campaign by running orfs_sensor with the given flags
Types ¶
type CommandFlags ¶
type CommandFlags struct { AvgFactor string `yaml:"averagingFactor" flag:"-a"` FftBatchLen string `yaml:"fftBatchLength" flag:"-b"` ClkOffset string `yaml:"clockOffset" flag:"-c"` DevIndex string `yaml:"devIndex" flag:"-d"` Log2FFTsize string `yaml:"log2FFTsize" flag:"-f"` Gain string `yaml:"gain" flag:"-g"` ClkCorrPeriod string `yaml:"clockCorrectionPeriod" flag:"-k"` SchemaFile string `yaml:"schemaFile" flag:"-m"` SslCollector string `yaml:"sslCollector" flag:"-n"` SOverlap string `yaml:"segmentOverlap" flag:"-o"` FreqOverlap string `yaml:"frequencyOverlap" flag:"-q"` MinTimeRes string `yaml:"minTimeResolution" flag:"-r"` SampRate string `yaml:"samplingRate" flag:"-s"` MonitorTime string `yaml:"monitorTime" flag:"-t"` Window string `yaml:"windowingFunction" flag:"-w"` AbsoluteTime string `yaml:"absoluteTime" flag:"-x"` HoppingStrategy string `yaml:"hoppingStrategy" flag:"-y"` MeasurementType string `yaml:"measurementType" flag:"-z"` // These should be ignored by koanf even if found in the configuration SensorId string CampaignId string MinFreq string MaxFreq string Command string }
type StatusEnum ¶
type StatusEnum string
Type StatusEnum describes the current status of the sensor
const ( Free StatusEnum = "FREE" Busy StatusEnum = "BUSY" Error StatusEnum = "ERROR" )
Click to show internal directories.
Click to hide internal directories.