t0 = GetSecs;
firsttouch = 0;
for i = 1:number_of_frames
    % draw the movie
    % flip the movie
    [keyIsDown, t_press, keyCode] = KbCheck;
    if keyCode(responsekey) == 1 && firsttouch == 0
        t_press = t_press-t0;
        firsttouch = 1;
    end
end