Skip to content

Trouble_Shooting

Jin Jeon edited this page Jan 10, 2019 · 3 revisions

This section will be constantly updated for addressing any encountered trouble issues.

PsychoPy

PsychoPy Sound Library

Sound seems to be a developing area in PsychoPy. PsychoPy provides three build in audio-libraries:

  • sounddevice
  • pyo
  • pygame

You can see your PsychoPy sound library setting in Preferences. In the sound library section, each is listed in '' with the order of preference. The lab computer currently uses 'pygame' to play sounds in PsychoPy. 'pyo' and 'sounddevice' do not seem to work. The differences in these sound libraries are that 'pyo' and 'sounddevice' have better timing accuracy but seem to be unstable, while 'pygame', which is the oldest system performs most stably.

In general, it's nice to figure out what the problem is with the sound by running a sound demo file to check whether sound works at all. To do so, go to coder view > demo > stimuliSound.py. This file should play few sounds, and if there is an error, see below:

Currently known problems are:

  • PsychoPy abruptly quits out when playing sound
  • Code runs but sound is not played

For any of these issues, it could mean the current sound library that is set is not working properly. If using 'pyo' or 'sounddevice', try deleting them and apply 'pygame' instead.

Reference:
You can manually code the preference of PsychoPy to order which sound library to look for:

from psychopy import prefs
prefs.general['audioLib'] = ['pygame','pyo']

Reference:
http://www.psychopy.org/api/sound.html

NetStation

Could not detect a Net Amps Amplifer

Often times, when turning on/opening a session, such error message could show up.

Solution:

  • Make sure the physical wires are fully connected properly
  • Often times, it's likely that NetStation did not quit properly. Simply quit and restart NetStation (not just ending session, but exiting the software completely)

Error Message with 'Socket'

Error message showing 'socket' issue is likely due to not having proper connection.

Solution:

  • Make sure configured workbench is turned on and waveforms are displayed in NetStation
  • Make sure PsychoPy code has proper IP address and port number Refer: Hardware Setup