Documentation ¶
Index ¶
- Constants
- type Client
- func (c *Client) Address(ctx context.Context) (out string, err error)
- func (c *Client) BatteryLevel(ctx context.Context) (out uint8, err error)
- func (c *Client) Close() error
- func (c *Client) Download(ctx context.Context, dst, src string) (chan FSTransferProgress, error)
- func (c *Client) FirmwareUpgrade(ctx context.Context, upgType UpgradeType, files ...string) (chan infinitime.DFUProgress, error)
- func (c *Client) HeartRate(ctx context.Context) (out uint8, err error)
- func (c *Client) LoadResources(ctx context.Context, path string) (<-chan infinitime.ResourceLoadProgress, error)
- func (c *Client) Mkdir(ctx context.Context, paths ...string) error
- func (c *Client) MkdirAll(ctx context.Context, paths ...string) error
- func (c *Client) Motion(ctx context.Context) (out infinitime.MotionValues, err error)
- func (c *Client) Notify(ctx context.Context, title, body string) error
- func (c *Client) ReadDir(ctx context.Context, dir string) (out []FileInfo, err error)
- func (c *Client) Remove(ctx context.Context, paths ...string) error
- func (c *Client) RemoveAll(ctx context.Context, paths ...string) error
- func (c *Client) Rename(ctx context.Context, old, new string) error
- func (c *Client) SetTime(ctx context.Context, t time.Time) error
- func (c *Client) StepCount(ctx context.Context) (out uint32, err error)
- func (c *Client) Upload(ctx context.Context, dst, src string) (chan FSTransferProgress, error)
- func (c *Client) Version(ctx context.Context) (out string, err error)
- func (c *Client) WatchBatteryLevel(ctx context.Context) (<-chan uint8, error)
- func (c *Client) WatchHeartRate(ctx context.Context) (<-chan uint8, error)
- func (c *Client) WatchMotion(ctx context.Context) (<-chan infinitime.MotionValues, error)
- func (c *Client) WatchStepCount(ctx context.Context) (<-chan uint32, error)
- func (c *Client) WeatherUpdate(ctx context.Context) error
- type FSData
- type FSTransferProgress
- type FileInfo
- type FwUpgradeData
- type NotifyData
- type UpgradeType
Constants ¶
View Source
const DefaultAddr = "/tmp/itd/socket"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
func NewFromConn ¶ added in v0.0.6
func NewFromConn(conn io.ReadWriteCloser) *Client
func (*Client) BatteryLevel ¶
func (*Client) FirmwareUpgrade ¶
func (c *Client) FirmwareUpgrade(ctx context.Context, upgType UpgradeType, files ...string) (chan infinitime.DFUProgress, error)
func (*Client) LoadResources ¶ added in v0.0.8
func (c *Client) LoadResources(ctx context.Context, path string) (<-chan infinitime.ResourceLoadProgress, error)
LoadResources loads resources onto the watch from the given file path to the resources zip
func (*Client) Motion ¶
func (c *Client) Motion(ctx context.Context) (out infinitime.MotionValues, err error)
func (*Client) WatchBatteryLevel ¶
func (*Client) WatchHeartRate ¶
func (*Client) WatchMotion ¶
func (c *Client) WatchMotion(ctx context.Context) (<-chan infinitime.MotionValues, error)
func (*Client) WatchStepCount ¶
type FSTransferProgress ¶ added in v0.0.6
type FwUpgradeData ¶ added in v0.0.6
type FwUpgradeData struct { Type UpgradeType Files []string }
type NotifyData ¶ added in v0.0.6
type UpgradeType ¶
type UpgradeType uint8
const ( UpgradeTypeArchive UpgradeType = iota UpgradeTypeFiles )
Click to show internal directories.
Click to hide internal directories.