Documentation ¶
Index ¶
Constants ¶
View Source
const ( SOH byte = 0x01 // YModem协议的起始帧标志 128字节数据包 STX byte = 0x02 // YModem-1K协议的起始帧标志 1024字节数据包 EOT byte = 0x04 // 传输结束标志 ACK byte = 0x06 // 确认接收字符 NAK byte = 0x15 // 未确认接收字符 CAN byte = 0x18 // 取消传输字符 POLL byte = 0x43 // 轮询字符,用于请求发送 )
定义YModem协议中的控制字符
Variables ¶
View Source
var ErrDataTooLong = errors.New("data too long")
Functions ¶
This section is empty.
Types ¶
type Frame ¶
type Frame struct {
// contains filtered or unexported fields
}
func BuildDataFrames ¶
BuildDataFrames 构造数据帧
func BuildStartFrame ¶
BuildStartFrame 构造起始帧
Click to show internal directories.
Click to hide internal directories.