1 | /** |
---|
2 | * @file rtems/framebuffer.h |
---|
3 | * |
---|
4 | * @brief Frame Buffer Device Driver for all Boards |
---|
5 | * |
---|
6 | * This file describes the Frame Buffer Device Driver for all boards. |
---|
7 | */ |
---|
8 | |
---|
9 | /* |
---|
10 | * COPYRIGHT (c) 1989-2011. |
---|
11 | * On-Line Applications Research Corporation (OAR). |
---|
12 | * |
---|
13 | * The license and distribution terms for this file may be |
---|
14 | * found in the file LICENSE in this distribution or at |
---|
15 | * http://www.rtems.org/license/LICENSE. |
---|
16 | */ |
---|
17 | |
---|
18 | #ifndef __RTEMS_FRAMEBUFFER_h__ |
---|
19 | #define __RTEMS_FRAMEBUFFER_h__ |
---|
20 | |
---|
21 | #include <rtems/io.h> |
---|
22 | |
---|
23 | #ifdef __cplusplus |
---|
24 | extern "C" { |
---|
25 | #endif |
---|
26 | |
---|
27 | /** |
---|
28 | * This macro defines the standard name for the frame buffer device |
---|
29 | * that is available to applications. |
---|
30 | */ |
---|
31 | #define FRAMEBUFFER_DEVICE_NAME "/dev/fb" |
---|
32 | |
---|
33 | /** |
---|
34 | * @brief Standard device file path of first frame buffer device. |
---|
35 | * |
---|
36 | * This device is the default frame buffer device for the Microwindows Screen |
---|
37 | * Driver. |
---|
38 | */ |
---|
39 | #define FRAMEBUFFER_DEVICE_0_NAME "/dev/fb0" |
---|
40 | |
---|
41 | /** |
---|
42 | * This macro defines the standard device driver table entry for |
---|
43 | * a frame buffer device driver. |
---|
44 | */ |
---|
45 | #define FRAME_BUFFER_DRIVER_TABLE_ENTRY \ |
---|
46 | { frame_buffer_initialize, frame_buffer_open, frame_buffer_close, \ |
---|
47 | frame_buffer_read, frame_buffer_write, frame_buffer_control } |
---|
48 | |
---|
49 | /** |
---|
50 | * @brief Frame Buffer Initialization Entry Point |
---|
51 | * |
---|
52 | * This method initializes the frame buffer device driver. |
---|
53 | * |
---|
54 | * @param[in] major is the device driver major number |
---|
55 | * @param[in] minor is the device driver minor number |
---|
56 | * @param[in] arg is the parameters to this call |
---|
57 | * |
---|
58 | * @return This method returns RTEMS_SUCCESSFUL when |
---|
59 | * the device driver is successfully initialized. |
---|
60 | */ |
---|
61 | rtems_device_driver frame_buffer_initialize( |
---|
62 | rtems_device_major_number major, |
---|
63 | rtems_device_minor_number minor, |
---|
64 | void *arg |
---|
65 | ); |
---|
66 | |
---|
67 | /** |
---|
68 | * @brief Frame Buffer Open Entry Point |
---|
69 | * |
---|
70 | * This method opens a specific device supported by the |
---|
71 | * frame buffer device driver. |
---|
72 | * |
---|
73 | * @param[in] major is the device driver major number |
---|
74 | * @param[in] minor is the device driver minor number |
---|
75 | * @param[in] arg is the parameters to this call |
---|
76 | * |
---|
77 | * @return This method returns RTEMS_SUCCESSFUL when |
---|
78 | * the device driver is successfully opened. |
---|
79 | */ |
---|
80 | rtems_device_driver frame_buffer_open( |
---|
81 | rtems_device_major_number major, |
---|
82 | rtems_device_minor_number minor, |
---|
83 | void *arg |
---|
84 | ); |
---|
85 | |
---|
86 | /** |
---|
87 | * @brief Frame Buffer Close Entry Point |
---|
88 | * |
---|
89 | * This method closes a specific device supported by the |
---|
90 | * frame buffer device driver. |
---|
91 | * |
---|
92 | * @param[in] major is the device driver major number |
---|
93 | * @param[in] minor is the device driver minor number |
---|
94 | * @param[in] arg is the parameters to this call |
---|
95 | * |
---|
96 | * @return This method returns RTEMS_SUCCESSFUL when |
---|
97 | * the device is successfully closed. |
---|
98 | */ |
---|
99 | rtems_device_driver frame_buffer_close( |
---|
100 | rtems_device_major_number major, |
---|
101 | rtems_device_minor_number minor, |
---|
102 | void *arg |
---|
103 | ); |
---|
104 | |
---|
105 | /** |
---|
106 | * @brief Frame Buffer Read Entry Point |
---|
107 | * |
---|
108 | * This method reads from a specific device supported by the |
---|
109 | * frame buffer device driver. |
---|
110 | * |
---|
111 | * @param[in] major is the device driver major number |
---|
112 | * @param[in] minor is the device driver minor number |
---|
113 | * @param[in] arg is the parameters to this call |
---|
114 | * |
---|
115 | * @return This method returns RTEMS_SUCCESSFUL when |
---|
116 | * the device is successfully read from. |
---|
117 | */ |
---|
118 | rtems_device_driver frame_buffer_read( |
---|
119 | rtems_device_major_number major, |
---|
120 | rtems_device_minor_number minor, |
---|
121 | void *arg |
---|
122 | ); |
---|
123 | |
---|
124 | /** |
---|
125 | * @brief Frame Buffer Write Entry Point |
---|
126 | * |
---|
127 | * This method writes to a specific device supported by the |
---|
128 | * frame buffer device driver. |
---|
129 | * |
---|
130 | * @param[in] major is the device driver major number |
---|
131 | * @param[in] minor is the device driver minor number |
---|
132 | * @param[in] arg is the parameters to this call |
---|
133 | * |
---|
134 | * @return This method returns RTEMS_SUCCESSFUL when |
---|
135 | * the device is successfully written. |
---|
136 | */ |
---|
137 | rtems_device_driver frame_buffer_write( |
---|
138 | rtems_device_major_number major, |
---|
139 | rtems_device_minor_number minor, |
---|
140 | void *arg |
---|
141 | ); |
---|
142 | |
---|
143 | /** |
---|
144 | * @brief Frame Buffer IO Control Entry Point |
---|
145 | * |
---|
146 | * This method performs an IO Control operation on a |
---|
147 | * specific device supported by the frame buffer device driver. |
---|
148 | * |
---|
149 | * @param[in] major is the device driver major number |
---|
150 | * @param[in] minor is the device driver minor number |
---|
151 | * @param[in] arg is the parameters to this call |
---|
152 | * |
---|
153 | * @return This method returns RTEMS_SUCCESSFUL when |
---|
154 | * the device driver IO control operation is |
---|
155 | * successfully performed. |
---|
156 | */ |
---|
157 | rtems_device_driver frame_buffer_control( |
---|
158 | rtems_device_major_number major, |
---|
159 | rtems_device_minor_number minor, |
---|
160 | void *arg |
---|
161 | ); |
---|
162 | |
---|
163 | #ifdef __cplusplus |
---|
164 | } |
---|
165 | #endif |
---|
166 | |
---|
167 | #endif |
---|
168 | /* end of include file */ |
---|