51 #ifndef LT_SMBusGroup_H_ 52 #define LT_SMBusGroup_H_ 71 virtual ~Executable() {}
75 class WriteByte :
public Executable
82 WriteByte(
LT_SMBus *e, uint8_t a, uint8_t c, uint8_t d);
86 class WriteBytes :
public Executable
94 WriteBytes(
LT_SMBus *e, uint8_t *a, uint8_t *c, uint8_t *d, uint8_t n);
98 class WriteWord :
public Executable
105 WriteWord(
LT_SMBus *e, uint8_t a, uint8_t c, uint16_t d);
109 class WriteBlock :
public Executable
117 WriteBlock(
LT_SMBus *e, uint8_t a, uint8_t c, uint8_t *b, uint16_t bl);
121 class SendByte :
public Executable
127 SendByte(
LT_SMBus *e, uint8_t a, uint8_t c);
134 Executable *executable;
145 bool addToQueue(Executable *);
200 uint16_t block_out_size,
202 uint16_t block_in_size
uint8_t readByte(uint8_t address, uint8_t command)
SMBus read byte command.
uint8_t writeReadBlock(uint8_t address, uint8_t command, uint8_t *block_out, uint16_t block_out_size, uint8_t *block_in, uint16_t block_in_size)
SMBus write then read block command.
void beginStoring()
Group Protocol Begin.
void execute()
Group Protocol Execute queued commands.
void writeByte(uint8_t address, uint8_t command, uint8_t data)
SMBus write byte command.
LT_SMBusGroup(LT_SMBus *)
union LT_union_int32_4bytes data
void writeBlock(uint8_t address, uint8_t command, uint8_t *block, uint16_t block_size)
SMBus write block command.
LT_I2CBus: Routines to communicate to I2C by Wire Library.
void writeWord(uint8_t address, uint8_t command, uint16_t data)
SMBus write word command.
void writeBytes(uint8_t *addresses, uint8_t *commands, uint8_t *data, uint8_t no_addresses)
SMBus write byte command for a list of addresses.
uint16_t readWord(uint8_t address, uint8_t command)
SMBus read word command.
void sendByte(uint8_t address, uint8_t command)
SMBus send byte command.
uint8_t readBlock(uint8_t address, uint8_t command, uint8_t *block, uint16_t block_size)
SMBus read block command.
LTC SMBus Support: Implementation for a shared SMBus layer.