Description of the problem: I want to collect participant’s text response to word stimuli.
I used ‘TextBox’ in my experiment.
It works well in a local computer, Psychopy.
But, when I run the experiment on pavlovia,
‘space’, ‘backspace’, punctuation and English are not typed.
Only, Korean character can be typed.
and I set up ‘lctrl’, and ‘rctrl’ as keyboard components to change the screen.
but it does not work.
Could you help me solve a problem?
Is there any wrong in my code?
// key_response updates
if (t >= 0.0 && key_response.status === PsychoJS.Status.NOT_STARTED) {
// keep track of start time/frame for later
key_response.tStart = t; // (not accounting for frame time here)
key_response.frameNStart = frameN; // exact frame index
// keyboard checking is just starting
psychoJS.window.callOnFlip(function() { key_response.clock.reset(); }); // t=0 on next screen flip
psychoJS.window.callOnFlip(function() { key_response.start(); }); // start on screen flip
psychoJS.window.callOnFlip(function() { key_response.clearEvents(); });
}
frameRemains = 0.0 + 60.0 - psychoJS.window.monitorFramePeriod * 0.75; // most of one frame period left
if (key_response.status === PsychoJS.Status.STARTED && t >= frameRemains) {
key_response.status = PsychoJS.Status.FINISHED;
}
if (key_response.status === PsychoJS.Status.STARTED) {
let theseKeys = key_response.getKeys({keyList: ['lctrl', 'rctrl'], waitRelease: false});
_key_response_allKeys = _key_response_allKeys.concat(theseKeys);
if (_key_response_allKeys.length > 0) {
key_response.keys = _key_response_allKeys[_key_response_allKeys.length - 1].name; // just the last key pressed
key_response.rt = _key_response_allKeys[_key_response_allKeys.length - 1].rt;
// a response ends the routine
continueRoutine = false;
}
}
Hi @hanbyeol, thanks for giving me access, I was expecting the project might have been hosted on Pavlovia, but OK. Would upgrading to PsychoPy/JS version 2021.1.3 be an option for you? I believe you may have hit a bug that has since been fixed. Could you try that and let me know if the problem remains? Thanks, x
Hi @sotiri,
I changed all the ‘key component’ to ‘mouse component’. and the issue that i had is solved now!! So I can use the ‘space’, ‘backspace’ ect…
I appreciate your help
But… I had an another issue
The response that i wrote in first textbox is remained next textbox…
So I had to delete the first response to write the next response.