iPXE
AbsolutePointer.h
Go to the documentation of this file.
1 /** @file
2  The file provides services that allow information about an
3  absolute pointer device to be retrieved.
4 
5  Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
6  SPDX-License-Identifier: BSD-2-Clause-Patent
7 
8  @par Revision Reference:
9  This Protocol was introduced in UEFI Specification 2.3.
10 
11 **/
12 
13 #ifndef __ABSOLUTE_POINTER_H__
14 #define __ABSOLUTE_POINTER_H__
15 
16 FILE_LICENCE ( BSD2_PATENT );
17 
18 #define EFI_ABSOLUTE_POINTER_PROTOCOL_GUID \
19  { 0x8D59D32B, 0xC655, 0x4AE9, { 0x9B, 0x15, 0xF2, 0x59, 0x04, 0x99, 0x2A, 0x43 } }
20 
22 
23 // *******************************************************
24 // EFI_ABSOLUTE_POINTER_MODE
25 // *******************************************************
26 
27 /**
28  The following data values in the EFI_ABSOLUTE_POINTER_MODE
29  interface are read-only and are changed by using the appropriate
30  interface functions.
31 **/
32 typedef struct {
33  UINT64 AbsoluteMinX; ///< The Absolute Minimum of the device on the x-axis
34  UINT64 AbsoluteMinY; ///< The Absolute Minimum of the device on the y axis.
35  UINT64 AbsoluteMinZ; ///< The Absolute Minimum of the device on the z-axis
36  UINT64 AbsoluteMaxX; ///< The Absolute Maximum of the device on the x-axis. If 0, and the
37  ///< AbsoluteMinX is 0, then the pointer device does not support a xaxis
38  UINT64 AbsoluteMaxY; ///< The Absolute Maximum of the device on the y -axis. If 0, and the
39  ///< AbsoluteMinX is 0, then the pointer device does not support a yaxis.
40  UINT64 AbsoluteMaxZ; ///< The Absolute Maximum of the device on the z-axis. If 0 , and the
41  ///< AbsoluteMinX is 0, then the pointer device does not support a zaxis
42  UINT32 Attributes; ///< The following bits are set as needed (or'd together) to indicate the
43  ///< capabilities of the device supported. The remaining bits are undefined
44  ///< and should be 0
46 
47 ///
48 /// If set, indicates this device supports an alternate button input.
49 ///
50 #define EFI_ABSP_SupportsAltActive 0x00000001
51 
52 ///
53 /// If set, indicates this device returns pressure data in parameter CurrentZ.
54 ///
55 #define EFI_ABSP_SupportsPressureAsZ 0x00000002
56 
57 /**
58  This function resets the pointer device hardware. As part of
59  initialization process, the firmware/device will make a quick
60  but reasonable attempt to verify that the device is
61  functioning. If the ExtendedVerification flag is TRUE the
62  firmware may take an extended amount of time to verify the
63  device is operating on reset. Otherwise the reset operation is
64  to occur as quickly as possible. The hardware verification
65  process is not defined by this specification and is left up to
66  the platform firmware or driver to implement.
67 
68  @param This A pointer to the EFI_ABSOLUTE_POINTER_PROTOCOL
69  instance.
70 
71  @param ExtendedVerification Indicates that the driver may
72  perform a more exhaustive
73  verification operation of the
74  device during reset.
75 
76  @retval EFI_SUCCESS The device was reset.
77 
78  @retval EFI_DEVICE_ERROR The device is not functioning
79  correctly and could not be reset.
80 
81 **/
82 typedef
86  IN BOOLEAN ExtendedVerification
87  );
88 
89 ///
90 /// This bit is set if the touch sensor is active.
91 ///
92 #define EFI_ABSP_TouchActive 0x00000001
93 
94 ///
95 /// This bit is set if the alt sensor, such as pen-side button, is active
96 ///
97 #define EFI_ABS_AltActive 0x00000002
98 
99 /**
100  Definition of EFI_ABSOLUTE_POINTER_STATE.
101 **/
102 typedef struct {
103  ///
104  /// The unsigned position of the activation on the x axis. If the AboluteMinX
105  /// and the AboluteMaxX fields of the EFI_ABSOLUTE_POINTER_MODE structure are
106  /// both 0, then this pointer device does not support an x-axis, and this field
107  /// must be ignored.
108  ///
110 
111  ///
112  /// The unsigned position of the activation on the y axis. If the AboluteMinY
113  /// and the AboluteMaxY fields of the EFI_ABSOLUTE_POINTER_MODE structure are
114  /// both 0, then this pointer device does not support an y-axis, and this field
115  /// must be ignored.
116  ///
118 
119  ///
120  /// The unsigned position of the activation on the z axis, or the pressure
121  /// measurement. If the AboluteMinZ and the AboluteMaxZ fields of the
122  /// EFI_ABSOLUTE_POINTER_MODE structure are both 0, then this pointer device
123  /// does not support an z-axis, and this field must be ignored.
124  ///
126 
127  ///
128  /// Bits are set to 1 in this structure item to indicate that device buttons are
129  /// active.
130  ///
133 
134 /**
135  The GetState() function retrieves the current state of a pointer
136  device. This includes information on the active state associated
137  with the pointer device and the current position of the axes
138  associated with the pointer device. If the state of the pointer
139  device has not changed since the last call to GetState(), then
140  EFI_NOT_READY is returned. If the state of the pointer device
141  has changed since the last call to GetState(), then the state
142  information is placed in State, and EFI_SUCCESS is returned. If
143  a device error occurs while attempting to retrieve the state
144  information, then EFI_DEVICE_ERROR is returned.
145 
146 
147  @param This A pointer to the EFI_ABSOLUTE_POINTER_PROTOCOL
148  instance.
149 
150  @param State A pointer to the state information on the
151  pointer device.
152 
153  @retval EFI_SUCCESS The state of the pointer device was
154  returned in State.
155 
156  @retval EFI_NOT_READY The state of the pointer device has not
157  changed since the last call to GetState().
158 
159  @retval EFI_DEVICE_ERROR A device error occurred while
160  attempting to retrieve the pointer
161  device's current state.
162 
163 **/
164 typedef
169  );
170 
171 ///
172 /// The EFI_ABSOLUTE_POINTER_PROTOCOL provides a set of services
173 /// for a pointer device that can be used as an input device from an
174 /// application written to this specification. The services include
175 /// the ability to: reset the pointer device, retrieve the state of
176 /// the pointer device, and retrieve the capabilities of the pointer
177 /// device. The service also provides certain data items describing the device.
178 ///
182  ///
183  /// Event to use with WaitForEvent() to wait for input from the pointer device.
184  ///
186  ///
187  /// Pointer to EFI_ABSOLUTE_POINTER_MODE data.
188  ///
190 };
191 
193 
194 #endif
UINT64 AbsoluteMaxZ
The Absolute Maximum of the device on the z-axis.
Definition of EFI_ABSOLUTE_POINTER_STATE.
128 bit buffer containing a unique identifier value.
Definition: Base.h:215
UINT64 AbsoluteMinZ
The Absolute Minimum of the device on the z-axis.
VOID * EFI_EVENT
Handle to an event structure.
Definition: UefiBaseType.h:39
unsigned char BOOLEAN
EFI_EVENT WaitForInput
Event to use with WaitForEvent() to wait for input from the pointer device.
The EFI_ABSOLUTE_POINTER_PROTOCOL provides a set of services for a pointer device that can be used as...
unsigned int UINT32
Definition: ProcessorBind.h:98
EFI_STATUS(EFIAPI * EFI_ABSOLUTE_POINTER_GET_STATE)(IN EFI_ABSOLUTE_POINTER_PROTOCOL *This, OUT EFI_ABSOLUTE_POINTER_STATE *State)
The GetState() function retrieves the current state of a pointer device.
UINT64 AbsoluteMaxY
The Absolute Maximum of the device on the y -axis.
UINT64 AbsoluteMinX
The Absolute Minimum of the device on the x-axis.
UINT64 CurrentX
The unsigned position of the activation on the x axis.
#define OUT
Definition: mlx_utils.h:29
UINT64 AbsoluteMaxX
The Absolute Maximum of the device on the x-axis.
The following data values in the EFI_ABSOLUTE_POINTER_MODE interface are read-only and are changed by...
UINT64 AbsoluteMinY
The Absolute Minimum of the device on the y axis.
UINT32 Attributes
The following bits are set as needed (or'd together) to indicate the capabilities of the device suppo...
#define EFIAPI
UINT64 CurrentZ
The unsigned position of the activation on the z axis, or the pressure measurement.
EFI_GUID gEfiAbsolutePointerProtocolGuid
UINT32 ActiveButtons
Bits are set to 1 in this structure item to indicate that device buttons are active.
EFI_ABSOLUTE_POINTER_GET_STATE GetState
unsigned long long UINT64
Definition: ProcessorBind.h:96
UINT64 CurrentY
The unsigned position of the activation on the y axis.
#define IN
Definition: mlx_utils.h:28
EFI_ABSOLUTE_POINTER_MODE * Mode
Pointer to EFI_ABSOLUTE_POINTER_MODE data.
RETURN_STATUS EFI_STATUS
Function return status for EFI API.
Definition: UefiBaseType.h:31
FILE_LICENCE(BSD2_PATENT)
EFI_ABSOLUTE_POINTER_RESET Reset
EFI_STATUS(EFIAPI * EFI_ABSOLUTE_POINTER_RESET)(IN EFI_ABSOLUTE_POINTER_PROTOCOL *This, IN BOOLEAN ExtendedVerification)
This function resets the pointer device hardware.