twi_at91.h
Go to the documentation of this file.00001
00039 #ifndef DRV_AT91_TWI_H
00040 #define DRV_AT91_TWI_H
00041
00042 #include <cfg/compiler.h>
00043
00044 typedef int16_t twi_iaddr_t;
00045
00046 #define TWI_NO_IADDR (-1)
00047
00048 void twi_init(void);
00049 bool twi_read(uint8_t id, twi_iaddr_t byte1, twi_iaddr_t byte2, twi_iaddr_t byte3, void *_buf, size_t len);
00050 bool twi_write(uint8_t id, twi_iaddr_t byte1, twi_iaddr_t byte2, twi_iaddr_t byte3, const void *_buf, size_t len);
00051
00052 #endif