tester: add a mock for command-oriented i2c devices

This commit is contained in:
Kenneth Bell
2021-05-11 22:18:09 -07:00
committed by Ron Evans
parent bd2530abee
commit 6b58fdc95a
5 changed files with 142 additions and 2 deletions
+3
View File
@@ -10,6 +10,9 @@ type I2CDevice interface {
// WriteRegister implements I2C.WriteRegister.
WriteRegister(r uint8, buf []byte) error
// Tx implements I2C.Tx
Tx(w, r []byte) error
// Addr returns the Device address.
Addr() uint8
}