Documentation ¶
Index ¶
- Variables
- func GetEnvStr(key, value string) string
- type CronJob
- type IotSDK
- func (sdk *IotSDK) ReplyCameraCapture(subject string, ok bool)
- func (sdk *IotSDK) Run(works []func(), jobs []*CronJob, handleMsg func(iotSDK *IotSDK, msg []byte))
- func (sdk *IotSDK) SavePicture(pr PictureRequest) error
- func (sdk *IotSDK) SendPresignedURLMsg()
- func (sdk *IotSDK) SetDeviceAttributes(attributeMap map[uint32]string)
- func (sdk *IotSDK) SetDeviceTelemetries(telemetryMap map[uint32]float64, now *timestamppb.Timestamp)
- type PictureRequest
Constants ¶
This section is empty.
Variables ¶
View Source
var ( //WSURL websocket服务地址 WSURL = GetEnvStr("WS_URL", "ws://localhost:8080/ws/iot/device") )
Functions ¶
Types ¶
type IotSDK ¶
type IotSDK struct { DeviceInfo *pb.LoginReplyMsg // contains filtered or unexported fields }
IotSDK IotSDK
func (*IotSDK) ReplyCameraCapture ¶
ReplyCameraCapture ..
func (*IotSDK) SendPresignedURLMsg ¶
func (sdk *IotSDK) SendPresignedURLMsg()
SendPresignedURLMsg ..
func (*IotSDK) SetDeviceAttributes ¶
SetDeviceAttributes set device attributes
func (*IotSDK) SetDeviceTelemetries ¶
func (sdk *IotSDK) SetDeviceTelemetries(telemetryMap map[uint32]float64, now *timestamppb.Timestamp)
SetDeviceTelemetries upload device telemetries
Click to show internal directories.
Click to hide internal directories.