Toggle navigation
Documentation
The friendly Operating System for the Internet of Things
Loading...
Searching...
No Matches
cfg_i2c_default.h
Go to the documentation of this file.
1
/*
2
* Copyright (C) 2014-2016 Freie Universität Berlin
3
* 2015 Zolertia SL
4
*
5
* This file is subject to the terms and conditions of the GNU Lesser
6
* General Public License v2.1. See the file LICENSE in the top level
7
* directory for more details.
8
*/
9
22
#ifndef CFG_I2C_DEFAULT_H
23
#define CFG_I2C_DEFAULT_H
24
25
#include "periph_cpu.h"
26
27
#ifdef __cplusplus
28
extern
"C"
{
29
#endif
30
35
#define I2C_IRQ_PRIO 1
36
37
static
const
i2c_conf_t
i2c_config
[] = {
38
{
39
.speed =
I2C_SPEED_FAST
,
40
.scl_pin =
GPIO_PIN
(
PORT_C
, 3),
41
.sda_pin =
GPIO_PIN
(
PORT_C
, 2)
42
},
43
};
44
45
#define I2C_NUMOF ARRAY_SIZE(i2c_config)
48
#ifdef __cplusplus
49
}
/* end extern "C" */
50
#endif
51
52
#endif
/* CFG_I2C_DEFAULT_H */
PORT_C
@ PORT_C
port C
Definition
periph_cpu.h:49
GPIO_PIN
#define GPIO_PIN(x, y)
Define a CPU specific GPIO pin generator macro.
Definition
periph_cpu.h:46
I2C_SPEED_FAST
@ I2C_SPEED_FAST
fast mode: ~400 kbit/s
Definition
periph_cpu.h:279
i2c_config
static const i2c_conf_t i2c_config[]
Default I2C device configuration.
Definition
cfg_i2c_default.h:59
i2c_conf_t
I2C configuration structure.
Definition
periph_cpu.h:299
Generated on Thu Jan 30 2025 14:58:33 by
1.12.0