1
0
Fork 0
mirror of https://github.com/kidoman/embd synced 2025-07-04 12:27:45 +02:00

i2c: added ReadBytes to I2CBus

This commit is contained in:
Gavin Cabbage 2015-08-29 00:42:44 -04:00 committed by Max Matveev
parent 8ca822e51e
commit eb03848208
2 changed files with 24 additions and 0 deletions

2
i2c.go
View file

@ -4,6 +4,8 @@ package embd
// I2CBus interface is used to interact with the I2C bus.
type I2CBus interface {
// ReadByte reads a byte from the given address.
ReadBytes(addr byte, num int) (value []byte, err error)
// ReadByte reads a byte from the given address.
ReadByte(addr byte) (value byte, err error)
// WriteByte writes a byte to the given address.