Register Calendar Latest Topics

  Author   Comment  

Junior Member
Posts: 1
Reply with quote  #1 
Hello, I have a question about joystick cursor show. In my task, joystick is employed. I use 'showcursor' function to show joystick cursor in the subject screen so that I can track  the movement of joystick controlled by the subject. But I found that the cursor would stop in the screen  and not move with the joystick when the eyejoytrack function was active. For example, the screen displays two circles on the left and right respectively. And then the subject uses joystick choose the left circle. The cursor stops in the left circle after it entered into it  and doesn't move along with joystick until the next trail begin. I want that the cursor could move with the joystick anytime, how to do that?

Attached Files
m Fix_choice_GB_joy.m (1.67 KB, 1 views)


Posts: 646
Reply with quote  #2 
Your joystick cursor stopped because eyejoytrack ended when the cursor entered the window. You should run another eyejoytrack or idle to keep it moving.

Tracking will stop during reward and ITI as well. If you want to minimize the downtime, you can deliver reward in the background and reduce ITI, like the following.

goodmonkey(500,'nonblocking',1);  % deliver reward in the background process
idle(500);   % Now goodmonkey returns immediately, so wait for the reward duration before turning off stimuli
toggleobject([target distractor],'Status','off');
idle(1500);  % This replaces ITI, so make ITI 0

By the way, the code you attached doesn't have showcursor and has undefined taskobject names.

Previous Topic | Next Topic

Quick Navigation:

Easily create a Forum Website with Website Toolbox.