Also here is the top of my code:
#!/usr/bin/env python2
# -*- coding: utf-8 -*-
from __future__ import absolute_import, division
import psychopy
psychopy.useVersion('1.84.0')
from psychopy import locale_setup, visual, core, data, event, logging, sound, gui
from psychopy.constants import (NOT_STARTED, STARTED, PLAYING, PAUSED,
STOPPED, FINISHED, PRESSED, RELEASED, FOREVER)
import numpy as np # whole numpy lib is available, prepend 'np.'
from numpy import (sin, cos, tan, log, log10, pi, average,
sqrt, std, deg2rad, rad2deg, linspace, asarray)
from numpy.random import random, randint, normal, shuffle
import os # handy system and path functions
import sys # to get file system encoding
And the code that I want to be able to read the ‘§’ character:
# *syncResp* updates
if t >= 0.0 and syncResp.status == NOT_STARTED:
# keep track of start time/frame for later
syncResp.tStart = t
syncResp.frameNStart = frameN # exact frame index
syncResp.status = STARTED
# keyboard checking is just starting
win.callOnFlip(syncResp.clock.reset) # t=0 on next screen flip
event.clearEvents(eventType='keyboard')
if syncResp.status == STARTED:
theseKeys = event.getKeys(keyList=['x'])
Where ‘x’ in keyList should be ‘§’…