Difference between revisions of "User Reference:Logging Input"

From BCI2000 Wiki
Jump to: navigation, search
 
Line 2: Line 2:
 
This information is recorded into [[BCI2000 Glossary#State_variables|state variables]], and recording is enabled by specifying appropriate [[User Reference:Module Command Line Options|command line options]] when starting a source module.
 
This information is recorded into [[BCI2000 Glossary#State_variables|state variables]], and recording is enabled by specifying appropriate [[User Reference:Module Command Line Options|command line options]] when starting a source module.
  
When BCI2000 is distributed across multiple machines in a network, input devices must be attached to the machine that runs the [[Technical Reference:Modules#Source Module|source module]]. This is because time stamps of data acquisition and input events must refer to a common time base to allow associating input events with sample positions.
+
When BCI2000 is distributed across multiple machines in a network, input devices must be attached to the machine that runs the [[Technical_Reference:Core_Modules#Data_Acquisition_Module|data acquisition module]]. This is because time stamps of data acquisition and input events must refer to a common physical time base to allow associating input events with sample positions.
  
 
==Parameters==
 
==Parameters==

Revision as of 11:01, 10 May 2008

BCI2000 allows you to record input from keyboard, mouse, and joystick at sample resolution. This information is recorded into state variables, and recording is enabled by specifying appropriate command line options when starting a source module.

When BCI2000 is distributed across multiple machines in a network, input devices must be attached to the machine that runs the data acquisition module. This is because time stamps of data acquisition and input events must refer to a common physical time base to allow associating input events with sample positions.

Parameters

LogKeyboard

--LogKeyboard=1

When set to 1 from the command line, this parameter enables recording of keyboard events into the KeyDown and KeyUp state variables.

LogMouse

--LogMouse=1

When set to 1 from the command line, this parameter enables recording of mouse events.

LogJoystick

--LogJoystick=1

When set to 1 from the command line, this parameter enables recording of joystick state.

States

KeyDown, KeyUp

Key events. When a key is pressed, "KeyDown" will assume the key's virtual key code at the corresponding sample position. When a key is released, the key code will be written into the "KeyUp" state variable.

MouseKeys

Mouse key state, with the left mouse button corresponding to bit 0, and the right mouse button corresponding to bit 1.

MousePosX, MousePosY

Mouse position in screen pixel coordinates.

JoystickXpos, JoystickYpos, JoystickZpos

Position is recorded from Joystick #1. Each position state is ranging from 0 to 32767 with a resting position at 16384.

JoystickButtons1, JoystickButtons2, JoystickButtons3, JoystickButtons4

Joystick button information. Each button state is either 1 when pressed or 0 when not pressed.

See also

User Reference:KeystrokeFilter