Documentation ¶
Index ¶
Constants ¶
View Source
const ( Pkl = "pkl" // 数据包总长度 Cmd = "op" // 数据包类型(命令类型) Seq = "seq" // 序号(一对请求与响应序号相同) HeadLen uint32 = 12 PacketMax = 5120 )
Variables ¶
This section is empty.
Functions ¶
func UnpackHead ¶
Types ¶
type RequestPdu ¶
type Sequence32 ¶
type Sequence32 interface {
NextVal() int32
}
Sequence32 32位序号生成器
var B32Seq Sequence32
type Sequence64 ¶
type Sequence64 interface {
NextVal() int64
}
Sequence64 64位序号生成器
var B64Seq Sequence64
type SequenceBCD ¶
type SequenceBCD interface {
NextVal() []byte
}
SequenceBCD BCD码序号生成器
var BcdSeq SequenceBCD
Click to show internal directories.
Click to hide internal directories.