RTEMS  5.1
i2cdrv.h
Go to the documentation of this file.
1 
7 /*
8  * Copyright (c) 2014 embedded brains GmbH. All rights reserved.
9  *
10  * embedded brains GmbH
11  * Dornierstr. 4
12  * 82178 Puchheim
13  * Germany
14  * <info@embedded-brains.de>
15  *
16  * The license and distribution terms for this file may be
17  * found in the file LICENSE in this distribution or at
18  * http://www.rtems.org/license/LICENSE.
19  */
20 
21 #ifndef I2CDRV_H
22 #define I2CDRV_H
23 
24 #include <rtems.h>
25 
26 #ifdef __cplusplus
27 extern "C" {
28 #endif /* __cplusplus */
29 
40 rtems_device_driver i2cdrv_initialize(
41  rtems_device_major_number major,
42  rtems_device_minor_number minor,
43  void *arg
44 );
45 
46 rtems_device_driver i2cdrv_open(
47  rtems_device_major_number major,
48  rtems_device_minor_number minor,
49  void *arg
50 );
51 
52 rtems_device_driver i2cdrv_close(
53  rtems_device_major_number major,
54  rtems_device_minor_number minor,
55  void *arg
56 );
57 
58 rtems_device_driver i2cdrv_read(
59  rtems_device_major_number major,
60  rtems_device_minor_number minor,
61  void *arg
62 );
63 
64 rtems_device_driver i2cdrv_write(
65  rtems_device_major_number major,
66  rtems_device_minor_number minor,
67  void *arg
68 );
69 
70 rtems_device_driver i2cdrv_ioctl(
71  rtems_device_major_number major,
72  rtems_device_minor_number minor,
73  void *arg
74 );
75 
76 #define I2C_DRIVER_TABLE_ENTRY \
77  { \
78  i2cdrv_initialize, \
79  i2cdrv_open, \
80  i2cdrv_close, \
81  i2cdrv_read, \
82  i2cdrv_write, \
83  i2cdrv_ioctl \
84  }
85 
86 #define I2C_IOC_SET_SLAVE_ADDRESS 1
87 
90 #ifdef __cplusplus
91 }
92 #endif /* __cplusplus */
93 
94 #endif /* I2CDRV_H */
rtems_status_code
Classic API Status.
Definition: status.h:43