MCPcopy Create free account
hub / github.com/facebook/time / cmdResult

Method cmdResult

sa53/protocol/protocol.go:282–288  ·  view source on GitHub ↗

cmdResult is the firmware-side write+read helper. Distinct from Cmd so the firmware upgrade flow keeps its validated behavior (no drain, fixed-buffer reader).

(cmd string)

Source from the content-addressed store, hash-verified

280// firmware upgrade flow keeps its validated behavior (no drain, fixed-buffer
281// reader).
282func (m *Mac) cmdResult(cmd string) (string, error) {
283 _, err := m.port.Write([]byte(cmd))
284 if err != nil {
285 return "", err
286 }
287 return m.readResult()
288}
289
290// Reset is to reset the MAC
291func (m *Mac) Reset() error {

Callers 3

ReadFirmwareMethod · 0.95
ResetMethod · 0.95
UpgradeMethod · 0.95

Calls 2

readResultMethod · 0.95
WriteMethod · 0.45

Tested by

no test coverage detected