(&self, f: &mut fmt::Formatter<'_>)
| 29 | |
| 30 | impl fmt::Debug for DeviceTelemetry { |
| 31 | fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { |
| 32 | f.debug_struct("DeviceTelemetry") |
| 33 | .field("temp_c", &self.temperature_c.unwrap_or(-1.0)) |
| 34 | .field("link_mbps", &self.link_throughput_mbps.unwrap_or(0)) |
| 35 | .field("errors", &self.transmission_errors) |
| 36 | .field("dropped", &self.dropped_frames) |
| 37 | .finish() |
| 38 | } |
| 39 | } |
| 40 | |
| 41 | /// 简单的状态指示灯 |
nothing calls this directly
no outgoing calls
no test coverage detected