Back to home page

LXR

 
 

    


File indexing completed on 2025-05-11 08:23:05

0001 /*
0002  * Copyright (c) 2013 Christian Mauderer.  All rights reserved.
0003  *
0004  * The license and distribution terms for this file may be
0005  * found in the file LICENSE in this distribution or at
0006  * http://www.rtems.org/license/LICENSE.
0007  */
0008 
0009 #include <bspopts.h>
0010 #include <bsp/i2c.h>
0011 #include <bsp/irq.h>
0012 
0013 #ifdef STM32F4_ENABLE_I2C1
0014   static stm32f4_i2c_bus_entry stm32f4_i2c1_entry = {
0015     .regs = STM32F4_I2C1,
0016     .index = 0,
0017     .vector = STM32F4_IRQ_I2C1_EV,
0018   };
0019 
0020   stm32f4_i2c_bus_entry *const stm32f4_i2c1 = &stm32f4_i2c1_entry;
0021 #endif
0022 
0023 #ifdef STM32F4_ENABLE_I2C2
0024   static stm32f4_i2c_bus_entry stm32f4_i2c2_entry = {
0025     .regs = STM32F4_I2C2,
0026     .index = 1,
0027     .vector = STM32F4_IRQ_I2C2_EV,
0028   };
0029 
0030   stm32f4_i2c_bus_entry *const stm32f4_i2c2 = &stm32f4_i2c2_entry;
0031 #endif