Documentation ¶
Overview ¶
Package config implements functions to assist with attribute evaluation in the SLAM service. Warning: The code in this package might be transient. Stability is not guaranteed.
Index ¶
- func DetermineDeleteProcessedData(logger golog.Logger, deleteData *bool, useLiveData bool) bool
- func DetermineUseLiveData(logger golog.Logger, liveData *bool, sensors []string) (bool, error)
- func GetOptionalParameters(config *Config, defaultPort string, defaultDataRateMsec, defaultMapRateSec int, ...) (string, int, int, bool, bool, error)
- func SetupDirectories(dataDirectory string, logger golog.Logger) error
- func SetupGRPCConnection(ctx context.Context, port string, dialMaxTimeoutSec int, logger golog.Logger) (pb.SLAMServiceClient, func() error, error)
- type Config
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DetermineDeleteProcessedData ¶
DetermineDeleteProcessedData will determine the value of the deleteProcessData attribute based on the useLiveData and deleteData input parameters.
func DetermineUseLiveData ¶
DetermineUseLiveData will determine the value of the useLiveData attribute based on the liveData input parameter and sensor list.
func GetOptionalParameters ¶ added in v0.1.30
func GetOptionalParameters(config *Config, defaultPort string, defaultDataRateMsec, defaultMapRateSec int, logger golog.Logger, ) (string, int, int, bool, bool, error)
GetOptionalParameters sets any unset optional config parameters to the values passed to this function, and returns them.
func SetupDirectories ¶ added in v0.1.27
SetupDirectories creates the data directory at the specified path along with its data, map, and config subdirectories.
func SetupGRPCConnection ¶ added in v0.1.27
func SetupGRPCConnection( ctx context.Context, port string, dialMaxTimeoutSec int, logger golog.Logger, ) (pb.SLAMServiceClient, func() error, error)
SetupGRPCConnection uses the defined port to create a GRPC client for communicating with the SLAM algorithms.
Types ¶
type Config ¶ added in v0.1.34
type Config struct { Sensors []string `json:"sensors"` ConfigParams map[string]string `json:"config_params"` DataDirectory string `json:"data_dir"` UseLiveData *bool `json:"use_live_data"` DataRateMsec int `json:"data_rate_msec"` MapRateSec *int `json:"map_rate_sec"` Port string `json:"port"` DeleteProcessedData *bool `json:"delete_processed_data"` }
Config describes how to configure the SLAM service.