Documentation ¶
Index ¶
Constants ¶
View Source
const ( Normal = iota //正常0 High //高报1 Low //低报2 Internal //探测器内部错误3 Communication //通讯错误4 Shield //主机屏蔽探测器5 SlaveHitch //探测器故障6 MainHitch //主电故障 PrepareHitch //备电故障 MainFailback //主电故障恢复 PrepareFailback //备电故障恢复 DATA = "data" ALARM = "alarm" HITCH = "hitch" ONLINE = "online" //上线 OFFLINE = "offline" //下线 ONLINE_INT = 1 //上线 OFFLINE_INT = 0 //下线 HostController = 1 //主机 Detector = 2 //探测器 )
View Source
const MAX_PARTITIONS = 10
Change max partitions as you need.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Data ¶
type DeviceMsg ¶
type DeviceMsg struct { Ts time.Time `json:"ts"` DataType string `json:"dataType"` Level int `json:"level"` DeviceId string `json:"deviceId"` GroupId int `json:"groupId"` Status string `json:"status"` DeviceType int `json:"deviceType"` Name string `json:"name" ` SlaveId int `json:"slaveId"` SlaveName string `json:"slaveName"` Address string `json:"address"` Data string `json:"data"` Unit string `json:"unit"` PropertyName string `json:"propertyName"` Signal int `json:"signal"` OrgId int `json:"orgId"` }
func (DeviceMsg) TaosDatabase ¶
If this is setted, sql will use db.table for tablename
func (DeviceMsg) TaosSTable ¶
Auto create table using stable and tags
type Event ¶
type Metadata ¶
type Metadata struct { Iccid string `json:"iccid"` Co int `json:"co"` List []*SlaveMetadata `json:"list"` }
type SlaveMetadata ¶
Click to show internal directories.
Click to hide internal directories.