mirror of
https://github.com/meshtastic/protobufs.git
synced 2026-04-20 22:13:55 +00:00
Clean up LogRecord
This commit is contained in:
parent
020ef9eea8
commit
e7ab73e2a9
3 changed files with 75 additions and 21 deletions
60
docs/docs.md
60
docs/docs.md
|
|
@ -6,9 +6,9 @@
|
|||
- [mesh.proto](#mesh.proto)
|
||||
- [ChannelSettings](#.ChannelSettings)
|
||||
- [Data](#.Data)
|
||||
- [DebugString](#.DebugString)
|
||||
- [DeviceState](#.DeviceState)
|
||||
- [FromRadio](#.FromRadio)
|
||||
- [LogRecord](#.LogRecord)
|
||||
- [MeshPacket](#.MeshPacket)
|
||||
- [MyNodeInfo](#.MyNodeInfo)
|
||||
- [NodeInfo](#.NodeInfo)
|
||||
|
|
@ -24,6 +24,7 @@
|
|||
- [Constants](#.Constants)
|
||||
- [GpsOperation](#.GpsOperation)
|
||||
- [LocationSharing](#.LocationSharing)
|
||||
- [LogRecord.Level](#.LogRecord.Level)
|
||||
- [RegionCode](#.RegionCode)
|
||||
- [RouteError](#.RouteError)
|
||||
|
||||
|
|
@ -120,21 +121,6 @@ internally in the case of CLEAR_TEXT and CLEAR_READACK)
|
|||
|
||||
|
||||
|
||||
<a name=".DebugString"></a>
|
||||
|
||||
### DebugString
|
||||
Debug output from the device
|
||||
|
||||
|
||||
| Field | Type | Label | Description |
|
||||
| ----- | ---- | ----- | ----------- |
|
||||
| message | [string](#string) | | |
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<a name=".DeviceState"></a>
|
||||
|
||||
### DeviceState
|
||||
|
|
@ -182,7 +168,7 @@ FIFO will be populated.
|
|||
| my_info | [MyNodeInfo](#MyNodeInfo) | | Tells the phone what our node number is, can be -1 if we've not yet joined a mesh. |
|
||||
| node_info | [NodeInfo](#NodeInfo) | | One packet is sent for each node in the on radio DB starts over with the first node in our DB |
|
||||
| radio | [RadioConfig](#RadioConfig) | | In rev1 this was the radio BLE characteristic |
|
||||
| debug_string | [DebugString](#DebugString) | | set to send debug console output over our protobuf stream |
|
||||
| log_record | [LogRecord](#LogRecord) | | set to send debug console output over our protobuf stream |
|
||||
| config_complete_id | [uint32](#uint32) | | sent as true once the device has finished sending all of the responses to want_config recipient should check if this ID matches our original request nonce, if not, it means your config responses haven't started yet |
|
||||
| rebooted | [bool](#bool) | | Sent to tell clients the radio has just rebooted. Set to true if present. Not used on all transports, currently just used for the serial console. |
|
||||
| secondary_channel | [ChannelSettings](#ChannelSettings) | | One of the secondary channels, they are all sent during config download |
|
||||
|
|
@ -192,6 +178,29 @@ FIFO will be populated.
|
|||
|
||||
|
||||
|
||||
<a name=".LogRecord"></a>
|
||||
|
||||
### LogRecord
|
||||
Debug output from the device.
|
||||
|
||||
To minimize the size of records inside the device code, if a time/source/level is not set
|
||||
on the message it is assumed to be a contuinuation of the previously sent message. This allows
|
||||
the device code to use fixed maxlen 64 byte strings for messages, and then extend as needed by
|
||||
emitting multiple records.
|
||||
|
||||
|
||||
| Field | Type | Label | Description |
|
||||
| ----- | ---- | ----- | ----------- |
|
||||
| message | [string](#string) | | |
|
||||
| time | [fixed32](#fixed32) | | Seconds since 1970 - or 0 for unknown/unset |
|
||||
| source | [string](#string) | | Usually based on thread name - if known |
|
||||
| level | [LogRecord.Level](#LogRecord.Level) | | Not yet set |
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<a name=".MeshPacket"></a>
|
||||
|
||||
### MeshPacket
|
||||
|
|
@ -508,6 +517,23 @@ How our location is shared with other nodes (or the local phone)
|
|||
|
||||
|
||||
|
||||
<a name=".LogRecord.Level"></a>
|
||||
|
||||
### LogRecord.Level
|
||||
Log levels, chosen to match python logging conventions.
|
||||
|
||||
| Name | Number | Description |
|
||||
| ---- | ------ | ----------- |
|
||||
| UNSET | 0 | |
|
||||
| CRITICAL | 50 | |
|
||||
| ERROR | 40 | |
|
||||
| WARNING | 30 | |
|
||||
| INFO | 20 | |
|
||||
| DEBUG | 10 | |
|
||||
| TRACE | 5 | |
|
||||
|
||||
|
||||
|
||||
<a name=".RegionCode"></a>
|
||||
|
||||
### RegionCode
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue