Add debug log ring buffer with timestamps, log CLI subcommand
This commit is contained in:
@@ -13,6 +13,17 @@ type ResponseInfo struct {
|
||||
FirmwareName string
|
||||
}
|
||||
|
||||
type RequestLog struct{}
|
||||
|
||||
type LogEntry struct {
|
||||
TimestampUS uint32
|
||||
Message string
|
||||
}
|
||||
|
||||
type ResponseLog struct {
|
||||
Entries []LogEntry
|
||||
}
|
||||
|
||||
type RequestTest struct {
|
||||
Name string
|
||||
}
|
||||
@@ -44,6 +55,8 @@ func init() {
|
||||
msgpack.RegisterExt(3, (*ResponsePICOBOOT)(nil))
|
||||
msgpack.RegisterExt(4, (*RequestInfo)(nil))
|
||||
msgpack.RegisterExt(5, (*ResponseInfo)(nil))
|
||||
msgpack.RegisterExt(6, (*RequestLog)(nil))
|
||||
msgpack.RegisterExt(7, (*ResponseLog)(nil))
|
||||
msgpack.RegisterExt(127, (*RequestTest)(nil))
|
||||
msgpack.RegisterExt(126, (*ResponseTest)(nil))
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user