User Tools

Site Tools


eeros_architecture:hal:input_devices

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
eeros_architecture:hal:input_devices [2017/05/03 07:56] – [Mouse Input] grafeeros_architecture:hal:input_devices [2021/04/16 11:52] (current) – [XBox Input] ursgraf
Line 2: Line 2:
 ===== Mouse Input ===== ===== Mouse Input =====
 You can use a mouse for position information or its button states. In the control system you create an instance of type [[eeros_architecture:control_system:available_blocks:mouseinput|]]. \\ You can use a mouse for position information or its button states. In the control system you create an instance of type [[eeros_architecture:control_system:available_blocks:mouseinput|]]. \\
-It is also possible to check for mouse input in the safety system by means of critival inputs. Defining a [[eeros_architecture:control_system:available_blocks:mouseinput|]] the HAL will contain 3 registered mouse button inputs under the names of: +It is also possible to check for mouse input in the safety system by means of critical inputs. Defining a [[eeros_architecture:control_system:available_blocks:mouseinput|]] the HAL will contain 3 registered mouse button inputs under the names of: 
-  leftMouseButton +  leftMouseButton 
-  middleMouseButton +  middleMouseButton 
-  rightMouseButton+  rightMouseButton
 As an example you could define a critical input in the safety system as follows As an example you could define a critical input in the safety system as follows
 <code cpp> <code cpp>
Line 11: Line 11:
   criticalInputs = { in1 };   criticalInputs = { in1 };
 </code> </code>
-A more complete example is given in [[getting_started:tutorials:hal2|]]+A more complete example is given in [[getting_started:tutorials:inputdev1|]] \\
 WARNING The HAL will contain the three inputs mentioned above only after the control system created its [[eeros_architecture:control_system:available_blocks:mouseinput|]] object. WARNING The HAL will contain the three inputs mentioned above only after the control system created its [[eeros_architecture:control_system:available_blocks:mouseinput|]] object.
  
 ===== XBox Input ===== ===== XBox Input =====
 You can use a XBox controller for position information or its button states. In the control system you create an instance of type [[eeros_architecture:control_system:available_blocks:xboxinput|]]. \\ You can use a XBox controller for position information or its button states. In the control system you create an instance of type [[eeros_architecture:control_system:available_blocks:xboxinput|]]. \\
-It is also possible to check for mouse input in the safety system by means of critival inputs. Defining a [[eeros_architecture:control_system:available_blocks:mouseinput|]] the HAL will contain registered mouse button inputs under the names of: +It is also possible to check for XBox input in the safety system by means of critical inputs. Defining a [[eeros_architecture:control_system:available_blocks:xboxinput|]] the HAL will contain registered XBox button inputs under the names of: 
-  - leftMouseButton +  - XBoxButtonA 
-  - middleMouseButton +  - XBoxButtonB 
-  - rightMouseButton+  - XBoxButtonX 
 +  - XBoxButtonY 
 +  - XBoxButtonLB 
 +  - XBoxButtonRB 
 +  - XBoxButtonBack 
 +  - XBoxButtonStart
 As an example you could define a critical input in the safety system as follows As an example you could define a critical input in the safety system as follows
 <code cpp> <code cpp>
-  Input<bool>* in1 = HAL::instance().getLogicInput("leftMouseButton", false);+  Input<bool>* in1 = HAL::instance().getLogicInput("XBoxButtonX", false);
   criticalInputs = { in1 };   criticalInputs = { in1 };
 </code> </code>
-A more complete example is given in [[getting_started:tutorials:hal2|]]+A more complete example is given in [[getting_started:tutorials:inputdev1|]]. \\ 
 +WARNING The HAL will contain the three inputs mentioned above only after the control system created its [[eeros_architecture:control_system:available_blocks:xboxinput|]] object.
eeros_architecture/hal/input_devices.1493790976.txt.gz · Last modified: 2017/05/03 07:56 by graf