Eyelink

% This is the main function of the Eyelink toolbox
Usage:

% For general advice, try:
help Eyelink

% For a more detailed explanation of any Eyelink function, just add a question mark “?”.
% E.g. for ‘Initialize’, try either of these equivalent forms:
Eyelink(‘Initialize?’)
Eyelink Initialize?

% If you think you’ve found a bug, please report it
on the forum, see: http://psychtoolbox.org/

% Initialize or shutdown Eyelink connection:
[status =] Eyelink(‘Initialize’ [, displayCallbackFunction])
[status =] Eyelink(‘InitializeDummy’ [, displayCallbackFunction])
[status =] Eyelink(‘IsConnected’)
[status =] Eyelink(‘SetAddress’, ipaddress);
Eyelink(‘Shutdown’)
oldlevel = Eyelink(‘Verbosity’ [,level]);
Eyelink(‘TestSuite’)
[status =] Eyelink(‘OpenFile’, filename [, dontOpenExisting=0])
[status =] Eyelink(‘CloseFile’)
[status =] Eyelink(‘ReceiveFile’,[‘filename’], [‘dest’], [‘dest_is_path’])

% Calibration:
[result =] Eyelink(‘StartSetup’ [, stype=0])
[status = ] Eyelink(‘DriftCorrStart’, x, y [,dtype=0][, dodraw=1][, allow_setup=0])
[result = ] Eyelink(‘ApplyDriftCorr’)
[result, tx, ty] = Eyelink(‘TargetCheck’)
[result = ] Eyelink(‘AcceptTrigger’)
[result, messageString =] Eyelink(‘CalMessage’)

% Start or stop recording and acquiring data:
[startrecording_error =] Eyelink(‘StartRecording’ [,file_samples, file_events, link_samples, link_events] )
Eyelink(‘Stoprecording’)
error = Eyelink(‘CheckRecording’)
eyeused = Eyelink(‘EyeAvailable’)
NewOrOld = Eyelink(‘NewFloatSampleAvailable’)
sample = Eyelink(‘NewestFloatSample’)
[sample, raw] = Eyelink(‘NewestFloatSampleRaw’ [, eye])
type = Eyelink(‘GetNextDataType’)
item = Eyelink(‘GetFloatData’, type)
[item, raw] = Eyelink(‘GetFloatDataRaw’, type [, eye])
[samples, events, drained] = Eyelink(‘GetQueuedData’[, eye])

% Miscellaneous functions to communicate with Eyelink:
result = Eyelink(‘ButtonStates’)
[status =] Eyelink(‘Command’, ‘formatstring’, […])
[status =] Eyelink(‘Message’, ‘formatstring’, […])
[result =] Eyelink(‘SendKeyButton’, code, mods, state)
[time =] Eyelink(‘TrackerTime’)
[offset =] Eyelink(‘TimeOffset’)
[status =] Eyelink(‘RequestTime’)
[time =] Eyelink(‘ReadTime’)
[mode =] Eyelink(‘TrackerMode’)
[result, reply =] Eyelink(‘ReadFromTracker’, VariableName)

% Miscellaneous Eyelink functions:
[result =] Eyelink(‘WaitForModeReady’, maxwait)
[result =] Eyelink(‘ImageModeDisplay’)
mode = Eyelink(‘CurrentMode’)
result = Eyelink(‘CalResult’)
Eyelink(‘SetOfflineMode’)
[version, versionString] = Eyelink(‘GetTrackerVersion’)
[time =] Eyelink(‘TrackerTime’)
[offset =] Eyelink(‘TimeOffset’)
[status] = Eyelink(‘ImageTransfer’, imagePath [, xPosition=0][, yPosition=0][, width=0][, height=0][, trackerXPosition=0][, trackerYPosition=0][, xferoptions=0])

% Eyelink Velocity related functions:
[vel, acc, fsample]= Eyelink(‘CalculateOverallVelocityAndAcceleration’ [, sample_model])
[vel,fsample] = Eyelink(‘CalculateVelocity’ [,sample_model] )
[x_vel,y_vel,fsample] = Eyelink(‘CalculateVelocityXY’ [,sample_model] )

% EyelinkToolbox version for the OpenGL PsychToolbox
% The EyelinkToolbox was developed by:

Frans Cornelissen  
Enno Peters  
John Palmer  
Chris Burns  
Mario Kleiner  
Erik Flister  
Nuha Jabakhanji  
  

  
The EyelinkToolbox can be used to ceate eye-movement experiments and      control the SR-Research Eyelink� gazetrackers      (http://www.eyelinkinfo.com/) from within Matlab.      It is incorporated into the PsychToolbox (http://www.psychtoolbox.org/).      and uses the functions provided by the PsychToolBox for graphics and sound.  

For a complete list of available functions type “Eyelink” in the
Matlab command window. For an explanation of any particular Eyelink
function just add a question mark “?” after a command.
E.g. for ‘Initialize’, try either of these equivalent forms:
Eyelink(‘Initialize?’)
Eyelink initialize?

[optional arguments]:  
Brackets in the function list, e.g. [remport], indicate optional      arguments, not matrices. Optional arguments must be in order, without      omitting earlier ones.  
  
If you need examples to get you started, check out the EyelinkDemos      folder.  

More information on this toolbox can be found in the file:
EyelinkToolbox/contents.m