Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Supported by

[solved] Live feed back to participant

edited August 2014 in OpenSesame

Hey,

i need to make a screen with Live Feedback to the participants

the experiment goes like so:

  1. participants get two options (1. easy= 1 point per completion OR 2. Hard = 3 points per completion --Chosen by arrow keys left or right

  2. the task requires space bar clicks with your pinky finger. depending the level of difficulty the task requires more or less keypresses. ( 1. easy = 30 clicks in 20 sec ... 2. hard = 30 clicks in 10 second)
    ---> LIVE FEEDBACK of how many clicks they have done so far
    ---> a dynamic display which shows a bar filling up as they get closer to the end.
    --> and maybe a timer.

  3. the next screan will congratulate them and show them how many points they won

---how do i get live feed back on the screen?
--- how do i make a dynamic display?

please help

thank you ...

and is there a way i can share my work with others if they need them?

image

Comments

  • edited August 2014

    so i got live feed back to add integerus on +1

    # this is what i did ....
    from openexp.canvas import canvas
    from openexp.keyboard import keyboard
    my_canvas = canvas(self.experiment)
    my_keyboard = keyboard(self.experiment)
    resp = "" # Here we store the response
    counter = 0
    
    my_canvas.copy(self.experiment.items["Easy_sketchpad"].canvas)
    my_canvas.text(counter)
    my_canvas.show()    
    
    correct = self.get('correct')
    if correct:
        times = self.get('Easytimes')
    else:
        times = self.get('Hardtimes')
    while counter < times:  
    
        # Get a keyboard response
        key, time = my_keyboard.get_key()
    
        if my_keyboard.to_chr(key) == "space":
            counter = counter + 1
        resp += my_keyboard.to_chr(key)
        # Copy the canvas from a sketchpad called 'my_sketchpad' and
        # overlay the response
        my_canvas.copy(self.experiment.items["Easy_sketchpad"].canvas)
        my_canvas.text(counter)
        my_canvas.show()    
    # Save the response
    self.experiment.set("response", resp)
    

    image

  • edited 10:30PM

    never mind .. i figured it out

    thanks

Sign In or Register to comment.