Conversation
tyeth
left a comment
There was a problem hiding this comment.
d2b.write needs removing, and d2b.event proving out along with an including b2d.write
| message D2B { | ||
| oneof payload { | ||
| Event event = 1; | ||
| Write write = 2; |
There was a problem hiding this comment.
Surely Event is enough and d2b.write will be unused?
| */ | ||
| message Add { | ||
| string name = 1; /** Unique name identifying this telemetry component (e.g. "rssi", "free_heap"). */ | ||
| float period = 2; /** Reporting interval, in seconds. */ |
There was a problem hiding this comment.
Document how this is used if a boot counter versus a periodic update
| string name = 1; /** Name of the telemetry component to remove. */ | ||
| } | ||
|
|
||
| /** |
There was a problem hiding this comment.
Could you provide an example of when a device would use a Write message within this API?
| * Each telemetry metric (e.g. "rssi", "free_heap", "boot_count") is its own component instance. | ||
| */ | ||
| message Add { | ||
| string name = 1; /** Unique name identifying this telemetry component (e.g. "rssi", "free_heap"). */ |
There was a problem hiding this comment.
Is name unique enough? Will we only have one telemetry-type component (i.e: RSSI) per device?
name is a unbounded string size - could you also add a .options file for the telemetry.proto ?
There was a problem hiding this comment.
I think name is probably unique enough. Can you think of an example where it might not be?
There was a problem hiding this comment.
Can't, let's keep name but add the .options file for max_size for that string
This PR adds a new
DeviceStatsTelemetry proto hanging of signal.d2b, allowing RSSI or latency_ms to be sent up to the broker.Long term we may wish to consider the broker sending the device it's currently reported battery level to be fed to displays. In theory it might make sense to keep the i2c battery sensor value locally when reporting it, but we cannot assume a voltage level = battery sensor so we have to add a way to track if sensors are battery monitors or rely on the broker disambiguating/using-an-action and then feeding back to device.