This repository has been archived on 2024-08-02. You can view files and clone it, but cannot push or open issues or pull requests.
orion/emlid/updater/test_results.go

28 lines
640 B
Go
Raw Permalink Normal View History

package updater
import "context"
const (
eventGetTestResults = "get test results"
eventTestResults = "test results"
)
// TestResults are the ReachRS module's test results
//
type TestResults struct {
Device string `json:"device"`
Lora bool `json:"lora"`
MPU bool `json:"mpu"`
STC bool `json:"stc"`
UBlox bool `json:"u-blox"`
}
// TestResults returns the ReachRS module tests results
func (c *Client) TestResults(ctx context.Context) (*TestResults, error) {
res := &TestResults{}
if err := c.ReqResp(ctx, eventGetTestResults, nil, eventTestResults, res); err != nil {
return nil, err
}
return res, nil
}