X-Git-Url: https://codewiz.org/gitweb?a=blobdiff_plain;f=bertos%2Fcpu%2Favr%2Fdrv%2Ftwi_avr.h;h=2d496df7e228d3372c07b4f8991002495f13e225;hb=2ec062d0fa64791fc844d8385a8cf06e8df5dab6;hp=a55cf64b13d143f6de6bf5d42d96833cca08c664;hpb=345f93de1963f49bdb194d2b06c8c5d7ba0a3e5f;p=bertos.git diff --git a/bertos/cpu/avr/drv/twi_avr.h b/bertos/cpu/avr/drv/twi_avr.h index a55cf64b..2d496df7 100644 --- a/bertos/cpu/avr/drv/twi_avr.h +++ b/bertos/cpu/avr/drv/twi_avr.h @@ -33,37 +33,23 @@ * \version $Id$ * * \author Stefano Fedrigo - * \author Bernardo Innocenti + * \author Bernie Innocenti * * \brief Driver for the AVR ATMega TWI (interface) */ -/*#* - *#* $Log$ - *#* Revision 1.5 2006/07/19 12:56:26 bernie - *#* Convert to new Doxygen style. - *#* - *#* Revision 1.4 2006/03/20 17:49:49 bernie - *#* Make the TWI driver more generic to work with devices other than EEPROMS. - *#* - *#* Revision 1.3 2005/04/11 19:10:28 bernie - *#* Include top-level headers from cfg/ subdir. - *#* - *#* Revision 1.2 2005/02/18 11:19:52 bernie - *#* Update copyright info. - *#* - *#*/ -#ifndef DRV_TWI_H -#define DRV_TWI_H +#ifndef DRV_I2C_H +#define DRV_I2C_H #include -bool twi_start_w(uint8_t id); -bool twi_start_r(uint8_t id); -void twi_stop(void); -bool twi_put(const uint8_t data); -bool twi_send(const void *_buf, size_t count); -bool twi_recv(void *_buf, size_t count); -void twi_init(void); +bool i2c_start_w(uint8_t id); +bool i2c_start_r(uint8_t id); +void i2c_stop(void); +bool i2c_put(const uint8_t data); +bool i2c_send(const void *_buf, size_t count); +int i2c_get(bool ack); +bool i2c_recv(void *_buf, size_t count); +void i2c_init(void); -#endif /* DRV_EEPROM_H */ +#endif /* DRV_I2C_H */