No feedback in first trial, wrong feedback in some trials:

Hi All, I am using builder view to create an online experiment. and I need to add feedback after each trial.
This should help participants to learn which keys to press (‘d’, ‘l’)
image
I used examples to come up with the next solution:
image
image


image
image
image
I guess there is no feedback on the first trial because related_resp.keys has nothing saved from the previous run, right? Is there a simple way to overcome this?
2. The most important problem is that I get feedback inconsistently. (when I on purpose press wrong key, feedback says “Correct!”).
First, I thought I made a mistake in my condition file: However, I couldn’t find error…
image
And I Even comparing corrAns and related_resp.keys in output files.
I can found it error but I don’t know what should I do…
image
Taking together, it makes me to think that my mistake is having feedback as routine style,

What should I do?

Thank your help

-kate-

code_2 is in feedback rather than instruct and you’ve put the code in End Routine. Move it to Begin Routine and move code_2 above feed1

Alternatively, move code_2 to instruct

ohhh Thank you so muuuch :relaxed:
I solved the problem of no feedback on the first trial.

but I haven’t solved the feedback problem yet.
image
What should i do with this?

That’s because you are storing all keys. Change the keyboard component to first key.

Oohh thank you wakecarter
i solved all!
thank you :blush: