libopencm3
A free/libre/open-source firmware library for various ARM Cortex-M3 microcontrollers.
i2c_common_v2.c File Reference
Include dependency graph for i2c_common_v2.c:

Go to the source code of this file.

Functions

void i2c_peripheral_enable (uint32_t i2c)
 I2C Peripheral Enable. More...
 
void i2c_peripheral_disable (uint32_t i2c)
 I2C Peripheral Disable. More...
 
void i2c_send_start (uint32_t i2c)
 I2C Send Start Condition. More...
 
void i2c_send_stop (uint32_t i2c)
 I2C Send Stop Condition. More...
 
void i2c_clear_stop (uint32_t i2c)
 I2C Clear Stop Flag. More...
 
void i2c_set_own_7bit_slave_address (uint32_t i2c, uint8_t slave)
 I2C Set the 7 bit Slave Address for the Peripheral. More...
 
void i2c_set_own_10bit_slave_address (uint32_t i2c, uint16_t slave)
 I2C Set the 10 bit Slave Address for the Peripheral. More...
 
void i2c_send_data (uint32_t i2c, uint8_t data)
 I2C Send Data. More...
 
uint8_t i2c_get_data (uint32_t i2c)
 I2C Get Data. More...
 
void i2c_enable_analog_filter (uint32_t i2c)
 
void i2c_disable_analog_filter (uint32_t i2c)
 
void i2c_set_digital_filter (uint32_t i2c, uint8_t dnf_setting)
 Set the I2C digital filter. More...
 
void i2c_set_prescaler (uint32_t i2c, uint8_t presc)
 
void i2c_set_data_setup_time (uint32_t i2c, uint8_t s_time)
 
void i2c_set_data_hold_time (uint32_t i2c, uint8_t h_time)
 
void i2c_set_scl_high_period (uint32_t i2c, uint8_t period)
 
void i2c_set_scl_low_period (uint32_t i2c, uint8_t period)
 
void i2c_enable_stretching (uint32_t i2c)
 
void i2c_disable_stretching (uint32_t i2c)
 
void i2c_set_7bit_addr_mode (uint32_t i2c)
 
void i2c_set_10bit_addr_mode (uint32_t i2c)
 
void i2c_set_7bit_address (uint32_t i2c, uint8_t addr)
 
void i2c_set_10bit_address (uint32_t i2c, uint16_t addr)
 
void i2c_set_write_transfer_dir (uint32_t i2c)
 
void i2c_set_read_transfer_dir (uint32_t i2c)
 
void i2c_set_bytes_to_transfer (uint32_t i2c, uint32_t n_bytes)
 
bool i2c_is_start (uint32_t i2c)
 
void i2c_enable_autoend (uint32_t i2c)
 
void i2c_disable_autoend (uint32_t i2c)
 
bool i2c_nack (uint32_t i2c)
 
bool i2c_busy (uint32_t i2c)
 
bool i2c_transmit_int_status (uint32_t i2c)
 
bool i2c_transfer_complete (uint32_t i2c)
 
bool i2c_received_data (uint32_t i2c)
 
void i2c_enable_interrupt (uint32_t i2c, uint32_t interrupt)
 I2C Enable Interrupt. More...
 
void i2c_disable_interrupt (uint32_t i2c, uint32_t interrupt)
 I2C Disable Interrupt. More...
 
void i2c_enable_rxdma (uint32_t i2c)
 I2C Enable reception DMA. More...
 
void i2c_disable_rxdma (uint32_t i2c)
 I2C Disable reception DMA. More...
 
void i2c_enable_txdma (uint32_t i2c)
 I2C Enable transmission DMA. More...
 
void i2c_disable_txdma (uint32_t i2c)
 I2C Disable transmission DMA. More...
 
void i2c_transfer7 (uint32_t i2c, uint8_t addr, const uint8_t *w, size_t wn, uint8_t *r, size_t rn)
 Run a write/read transaction to a given 7bit i2c address If both write & read are provided, the read will use repeated start. More...
 
void i2c_set_speed (uint32_t i2c, enum i2c_speeds speed, uint32_t clock_megahz)
 Set the i2c communication speed. More...