Browse Source

Allways define i2c prototypes

rfm69
Xose Pérez 6 years ago
parent
commit
e34a21ff82
1 changed files with 21 additions and 23 deletions
  1. +21
    -23
      code/espurna/config/prototypes.h

+ 21
- 23
code/espurna/config/prototypes.h View File

@ -56,29 +56,27 @@ bool gpioReleaseLock(unsigned char gpio);
// ----------------------------------------------------------------------------- // -----------------------------------------------------------------------------
// I2C // I2C
// ----------------------------------------------------------------------------- // -----------------------------------------------------------------------------
#if I2C_SUPPORT void i2cScan();
void i2cScan(); void i2cClearBus();
void i2cClearBus(); bool i2cGetLock(unsigned char address);
bool i2cGetLock(unsigned char address); bool i2cReleaseLock(unsigned char address);
bool i2cReleaseLock(unsigned char address); unsigned char i2cFindAndLock(size_t size, unsigned char * addresses);
unsigned char i2cFindAndLock(size_t size, unsigned char * addresses); void i2c_wakeup(uint8_t address);
uint8_t i2c_write_buffer(uint8_t address, uint8_t * buffer, size_t len);
void i2c_wakeup(uint8_t address); uint8_t i2c_write_uint8(uint8_t address, uint8_t value);
uint8_t i2c_write_buffer(uint8_t address, uint8_t * buffer, size_t len); uint8_t i2c_write_uint8(uint8_t address, uint8_t reg, uint8_t value);
uint8_t i2c_write_uint8(uint8_t address, uint8_t value); uint8_t i2c_write_uint8(uint8_t address, uint8_t reg, uint8_t value1, uint8_t value2);
uint8_t i2c_write_uint8(uint8_t address, uint8_t reg, uint8_t value); uint8_t i2c_write_uint16(uint8_t address, uint16_t value);
uint8_t i2c_write_uint8(uint8_t address, uint8_t reg, uint8_t value1, uint8_t value2); uint8_t i2c_write_uint16(uint8_t address, uint8_t reg, uint16_t value);
uint8_t i2c_write_uint16(uint8_t address, uint16_t value); uint8_t i2c_read_uint8(uint8_t address);
uint8_t i2c_write_uint16(uint8_t address, uint8_t reg, uint16_t value); uint8_t i2c_read_uint8(uint8_t address, uint8_t reg);
uint8_t i2c_read_uint8(uint8_t address); uint16_t i2c_read_uint16(uint8_t address);
uint8_t i2c_read_uint8(uint8_t address, uint8_t reg); uint16_t i2c_read_uint16(uint8_t address, uint8_t reg);
uint16_t i2c_read_uint16(uint8_t address); uint16_t i2c_read_uint16_le(uint8_t address, uint8_t reg);
uint16_t i2c_read_uint16(uint8_t address, uint8_t reg); int16_t i2c_read_int16(uint8_t address, uint8_t reg);
uint16_t i2c_read_uint16_le(uint8_t address, uint8_t reg); int16_t i2c_read_int16_le(uint8_t address, uint8_t reg);
int16_t i2c_read_int16(uint8_t address, uint8_t reg); void i2c_read_buffer(uint8_t address, uint8_t * buffer, size_t len);
int16_t i2c_read_int16_le(uint8_t address, uint8_t reg);
void i2c_read_buffer(uint8_t address, uint8_t * buffer, size_t len);
#endif
// ----------------------------------------------------------------------------- // -----------------------------------------------------------------------------
// MQTT // MQTT


|||||||
x
 
000:0
Loading…
Cancel
Save