zhangzengfei
2023-08-10 0718b07276198334437f52aa5c6c07cca2002225
msg/msg.go
@@ -12,6 +12,13 @@
   Details    []*PLCAddress `gorm:"-" json:"Details"`
}
type PLCAddress struct {
   StartAddress int    `json:"startAddress"` // 数据起始地址
   Length       int    `json:"length"`       // 数据长度
   Type         string `json:"type"`         // 数据类型
   FieldName    string `json:"fieldName"`    // 对应系统字段
}
type PLCResponse struct {
   DeviceID   string    `json:"deviceId"`
   DeviceName string    `json:"deviceName"`
@@ -21,19 +28,12 @@
   PLCData    []PLCData `json:"plcData"`
}
type PLCAddress struct {
   StartAddress int    `json:"startAddress"` // 数据起始地址
   Length       int    `json:"length"`       // 数据长度
   Type         string `json:"type"`         // 数据类型
   FieldName    string `json:"fieldName"`    // 对应系统字段
}
type PLCData struct {
   StartAddress int    `json:"startAddress"` // 数据起始地址
   Length       int    `json:"length"`       // 数据长度
   Type         string `json:"type"`         // 数据类型
   FieldName    string `json:"fieldName"`    // 对应系统字段
   Data         []byte // 从plc读取的原始数据
   RawData      []byte `json:"rawData"`      // 从plc读取的原始数据
}
type ApsDeviceApiResponse struct {