cfg_i2c1_pb6_pb7.h File Reference

Common configuration for STM32 I2C. More...

Detailed Description

Common configuration for STM32 I2C.

Alexandre Abadie

Definition in file cfg_i2c1_pb6_pb7.h.

#include "periph_cpu.h"
+ Include dependency graph for cfg_i2c1_pb6_pb7.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

I2C configuration

#define I2C_0_ISR   isr_i2c1
#define I2C_NUMOF   ARRAY_SIZE(i2c_config)
static const i2c_conf_t i2c_config []

Variable Documentation

◆ i2c_config

const i2c_conf_t i2c_config[]
Initial value:
= {
.dev = I2C1,
.speed = I2C_SPEED_NORMAL,
.scl_pin = GPIO_PIN(PORT_B, 6),
.sda_pin = GPIO_PIN(PORT_B, 7),
.scl_af = GPIO_AF1,
.sda_af = GPIO_AF1,
.bus = APB1,
.rcc_mask = RCC_APB1ENR_I2C1EN,
.irqn = I2C1_IRQn
use alternate function 1
APB1 bus.
Definition: periph_cpu.h:146
#define GPIO_PIN(x, y)
Define a CPU specific GPIO pin generator macro.
Definition: periph_cpu.h:35
normal mode: ~100 kbit/s
Definition: i2c.h:183
port B
Definition: periph_cpu.h:37

Definition at line 32 of file cfg_i2c1_pb6_pb7.h.