Documentation ¶
Index ¶
- Constants
- Variables
- type ConfigSystem
- type Cycle
- type DiskPercent
- type EdgexResourceAlarm
- type EveValueType
- type Event
- type Function
- type HardwarePower
- type HardwareTemperature
- type HostAlarm
- type Invoke
- type Item
- type Media
- type MediaDeviceChannel
- type MediaDeviceInfo
- type MediaInput
- type Model
- type Ntp
- type NvControl
- type Property
- type PropertyDataDefinition
- type SystemCfg
- type VideoRecordAlarm
- type WorkMode
Constants ¶
View Source
const ( FUNCTION_PROPERTY = 1 FUNCTION_FUNCTION = 2 FUNCTION_EVENT = 3 PROP_REPORT = "propReport" )
View Source
const ( READ_WRITE = 1 READ_ONLEY = 2 EVENT_ALARM = 1 EVENT_FAULT = 2 EVENT_INFO = 3 MEDIA_PLAY = "PushStream" MEDIA_CLOSE = "StopStream" MEDIA_CHANNEL = "channel" MEDIA_STREAM = "streamDestination" PROPS_DEVICE_INFO = "deviceInfo" PROPS_HARDWARE_INFO = "hardwareInfo" PROPS_SOFTWARE_INFO = "softwareInfo" PROPS_POSITION = "position" PROPS_ENCLOSURE = "enclosure" PROPS_GPSINFO = "gpsInfo" TOPOCHANGED = "topoChanged" //功能类的属性 PROPS_GPSSTORAGE = "GPSStorage" FUNC_PTCCONTROL = "PTZControl" //云台控制 FUNC_SHUTDOWN = "shutdown" //关机 FUNC_REBOOT = "reboot" //重启 FUNC_REMOTEACCESS = "remoteAccess" //远程功能 FUNC_LOGREPORT = "logReport" //本地日志 EVENT_OUTOFBOUND = "outOfBoundAlert" //围栏报警 EVENT_INFEREVENT = "InferEvent" //edgex硬编码的设置的算法推理流数据 EVENT_CPU = "cpuPercentAlarm" //cpu报警 EVENT_MEM = "memPercentAlarm" //内存报警 EVENT_DISK = "diskPercentAlarm" //硬盘报警 EVENT_HOST_TEMPERATURE = "hostTemperatureAlarm" //温度报警 EVENT_VIDEO_RECORD = "videoRecordAlarm" //视频记录报警 EVENT_RESOURCE = "edgexResourceAlarm" //资源报警 EVENT_MODE_CHANGE = "modeChange" //模式改变 IS_OBJECT_POWERS = "powers" IS_OBJECT_TEMPERATURES = "temperatures" )
Variables ¶
View Source
var CONFIG_QUERY = []string{1: "tsl", 2: "dp", 3: "algo", 4: "sys", 5: "ota.customfirmware", 6: "ota.image", 7: "ota.mcu", 8: "ota.ema", 9: "license", 10: "ota.edgex", 11: "ota.adapter"}
View Source
var EVENTS_STATIC = []string{EVENT_MODE_CHANGE, EVENT_CPU, EVENT_MEM, EVENT_DISK, EVENT_HOST_TEMPERATURE, EVENT_VIDEO_RECORD, EVENT_RESOURCE}
View Source
var EVENT_TYPES = []string{1: "alarm", 2: "fault", 3: "info"}
View Source
var FUNCS_STATIC = []string{FUNC_PTCCONTROL, FUNC_SHUTDOWN, FUNC_REBOOT, FUNC_REMOTEACCESS, FUNC_LOGREPORT}
View Source
var HARDWARE_INFO = []string{"cpuPercent", "hostTemperature", "memPercent", "diskPercent", "powers", "temperatures"}
View Source
var PROPS_STATIC = []string{PROPS_DEVICE_INFO, PROPS_HARDWARE_INFO, PROPS_SOFTWARE_INFO}
Functions ¶
This section is empty.
Types ¶
type Cycle ¶
type Cycle struct { //以下所有参数单位都是秒,特殊指定除外 Heartbeat int `json:"heartbeat,omitempty"` GpsInfo int `json:"gpsInfo,omitempty"` }
配置数据结构
type DiskPercent ¶
type DiskPercent struct { Mountpoint string `json:"mountpoint"` DiskPercent int `json:"diskPercent"` }
远程系统配置
type EdgexResourceAlarm ¶
type EdgexResourceAlarm struct { Total int `json:"total"` Used int `json:"used"` Free int `json:"free"` UsedPercent float64 `json:"usedPercent"` }
远程系统配置
type EveValueType ¶
type Event ¶
type Event struct { Id string `json:"id"` Name string `json:"name"` DataType string `json:"dataType,omitempty"` ValueType EveValueType `json:"valueType"` PropertyReadType int `json:"propertyReadType,omitempty"` // 属性_读写类型 1:读写 2:只读 }
type HardwarePower ¶
type HardwarePower struct { Name string `json:"name"` Power struct { Average string `json:"average"` Current string `json:"current"` } `json:"power"` }
远程系统配置
type HardwareTemperature ¶
type HardwareTemperature struct { Name string `json:"name"` Temperature string `json:"temperature"` }
远程系统配置
type HostAlarm ¶
type HostAlarm struct { CpuPercent int `json:"cpuPercent"` MemPercent int `json:"memPercent"` DiskPercent int `json:"diskPercent"` HostTemperature int `json:"hostTemperature"` }
远程系统配置
type Item ¶
type Item struct { Id string `json:"id,omitempty"` // FunctionType int `json:"functionType"` // 功能类型 1:属性 2:行为 3:事件 Name string `json:"name"` // 名称 Code string `json:"code"` // 标识符 PropertyDataType string `json:"propertyDataType,omitempty"` // 属性_数据类型 PropertyReadType int `json:"propertyReadType,omitempty"` // 属性_读写类型 1:读写 2:只读 PropertyDataDefinition map[string]interface{} `json:"propertyDataDefinition,omitempty"` // 属性_数据定义 PropertyExpand map[string]interface{} `json:"propertyExpand,omitempty"` // 属性_扩展描述 ActionCall []map[string]interface{} `json:"actionCall,omitempty"` // 行为_调用参数 ActionReturn []map[string]interface{} `json:"actionReturn,omitempty"` // 行为_返回参数 EventType int `json:"eventType,omitempty"` // 事件类型 1:告警 2:故障 3:信息 Events []map[string]interface{} `json:"events,omitempty"` // 事件参数 Original string `json:"original,omitempty"` // JSON报文 }
type Media ¶
type Media struct { Function string `json:"function"` Inputs []MediaInput `json:"inputs"` }
func MediaCloseInputs ¶
func MediaPlayInputs ¶
type MediaDeviceChannel ¶
type MediaDeviceChannel struct { Address string `json:"address"` Children interface{} `json:"children"` CivilCode string `json:"civilCode"` DeviceID string `json:"deviceId"` LivePublisher interface{} `json:"livePublisher"` LiveSubSP string `json:"liveSubSP"` Manufacturer string `json:"manufacturer"` Model string `json:"model"` Name string `json:"name"` Owner string `json:"owner"` ParentID string `json:"parentId"` Parental int64 `json:"parental"` RecordEndTime string `json:"recordEndTime"` RecordPublisher interface{} `json:"recordPublisher"` RecordStartTime string `json:"recordStartTime"` Records interface{} `json:"records"` RegisterWay int64 `json:"registerWay"` SafetyWay int64 `json:"safetyWay"` Secrecy int64 `json:"secrecy"` Status string `json:"status"` }
type MediaDeviceInfo ¶
type MediaInput ¶
type Model ¶
type Ntp ¶
type Ntp struct { Enabled bool `json:"enabled"` Interval int `json:"interval"` MainServer string `json:"mainServer"` SecondServer string `json:"secondServer"` }
远程系统配置
type NvControl ¶
type NvControl struct { NvpMode int `json:"nvpMode"` JetsonClock bool `json:"jetsonClock"` FanMode int `json:"fanMode"` FanSpeed int `json:"fanSpeed"` }
远程系统配置
type PropertyDataDefinition ¶
type SystemCfg ¶
type SystemCfg struct { SystemStatusCollectInterval int `json:"systemStatusCollectInterval"` SystemStatusReportInMiniMode bool `json:"systemStatusReportInMiniMode"` TdengineKeep int `json:"tdengineKeep"` OffdataRange int `json:"offdataRange"` WorkMode WorkMode `json:"workMode"` License string `json:"license"` DeviceDescription string `json:"deviceDescription"` Ntp Ntp `json:"ntp"` NvControl NvControl `json:"nvControl"` HostAlarm HostAlarm `json:"hostAlarm"` DeviceHeartbeat int `json:"deviceHeartbeat"` }
远程系统配置
Click to show internal directories.
Click to hide internal directories.