DbgMuxFrame: add tentative FlowControl message definition
This commit is contained in:
parent
7c2094dc44
commit
88553524a3
9
proto.py
9
proto.py
|
@ -39,7 +39,7 @@ class DbgMuxFrame:
|
||||||
ConnTerminate = 0x6d, # 'm'
|
ConnTerminate = 0x6d, # 'm'
|
||||||
ConnTerminated = 0x6e, # 'n'
|
ConnTerminated = 0x6e, # 'n'
|
||||||
ConnData = 0x6f, # 'o'
|
ConnData = 0x6f, # 'o'
|
||||||
# TODO: = 0x70, # 'p'
|
FlowControl = 0x70, # 'p'
|
||||||
Ack = 0x71, # 'q'
|
Ack = 0x71, # 'q'
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@ -89,6 +89,12 @@ class DbgMuxFrame:
|
||||||
'Data' / GreedyBytes,
|
'Data' / GreedyBytes,
|
||||||
)
|
)
|
||||||
|
|
||||||
|
# MsgType.FlowControl structure
|
||||||
|
MsgFlowControl = Struct(
|
||||||
|
'ConnRef' / Int16ul,
|
||||||
|
'DataBlockLimit' / Int8ul,
|
||||||
|
)
|
||||||
|
|
||||||
# Complete message definition
|
# Complete message definition
|
||||||
Msg = Switch(this.MsgType, default=GreedyBytes, cases={
|
Msg = Switch(this.MsgType, default=GreedyBytes, cases={
|
||||||
MsgType.Enquiry : Const(b''),
|
MsgType.Enquiry : Const(b''),
|
||||||
|
@ -101,5 +107,6 @@ class DbgMuxFrame:
|
||||||
MsgType.ConnTerminate : MsgConnTerminate,
|
MsgType.ConnTerminate : MsgConnTerminate,
|
||||||
MsgType.ConnTerminated : MsgConnTerminated,
|
MsgType.ConnTerminated : MsgConnTerminated,
|
||||||
MsgType.ConnData : MsgConnData,
|
MsgType.ConnData : MsgConnData,
|
||||||
|
MsgType.FlowControl : MsgFlowControl,
|
||||||
MsgType.Ack : Const(b''),
|
MsgType.Ack : Const(b''),
|
||||||
})
|
})
|
||||||
|
|
Loading…
Reference in New Issue