[solved] error message "mixer system not initialized" when running from source on Windows
Hi again,
I'm trying to get a new computer attached to the eyelink machine (I have it working with one computer already). Everything seems to be going fine, but when I attach the eyelink machine and hit run, I get the following error message:
An unexpected error occurred, which was not caught by OpenSesame. This should not happen! Message:
mixer system not initialized
My first (uneducated) thought is that this might be related to the video system, since that's the only part of OpenSesame that I can't get to work on this new computer (when I try to add a video component, it tells me that it can't find the dll (but doesn't say which dll)).
Thanks!
Mark
I'm trying to get a new computer attached to the eyelink machine (I have it working with one computer already). Everything seems to be going fine, but when I attach the eyelink machine and hit run, I get the following error message:
An unexpected error occurred, which was not caught by OpenSesame. This should not happen! Message:
mixer system not initialized
My first (uneducated) thought is that this might be related to the video system, since that's the only part of OpenSesame that I can't get to work on this new computer (when I try to add a video component, it tells me that it can't find the dll (but doesn't say which dll)).
Thanks!
Mark
Comments
Sorry, I should have specified - there is no video element in the OpenSesame script I'm testing. There's only one element in the script, an eyelink "calibrate" event (just to test the connection to the eyelink machine). It's when I run this script that I get the error message mentioned above.
Hi Mark,
The mixer deals with sound, so something has gone wrong in that department. But I'm not sure what...
If you start OpenSesame in debug mode (with the --debug suffix), what kind of error message do you see in the debug window (Ctrl+D)? There's probably a more elaborate error message in there, which might be helpful.
Which back-end are you using?
Regards,
Sebastiaan
Check out SigmundAI.eu for our OpenSesame AI assistant!
Hi Sebastiaan,
Thanks! I'm using the default backend (I did not install Psychopy). The reason I thought it might be the video is that was the only element I had problems installing. Here are 2 error logs, the first is a run of the default script that is there when I open OpenSesame (no elements other than the welcome page). That worked fine, the welcome screen popped up and the script ended without any problems. I then added a call to the eyelink_calibrate function and the 2nd error log is what I got when I tried to run that.
For some reason it seems to try to call a "synth" element when I run this script (though I didn't add any sound function to the script, just the one eyelink function).
Thanks for all your help,
Mark
A RUN OF AN EXPERIMENT WITH NO ELEMENTS EXCEPT THE DEFAULT WELCOME SCREEN:
experiment.init_sound(): sampling freq = 48000, buffer size = 512
video.legacy.init_display(): video mode ok
experiment.init_log(): using 'D:/Documents and Settings/cod.INTELSERVERWIN/Desktop\debug.csv' as logfile
experiment.run(): experiment started at Tue Aug 23 13:23:45 2011
keyboard.init(): morphing into openexp._keyboard.legacy
canvas.init(): morphing into openexp._canvas.legacy
keyboard.init(): morphing into openexp._keyboard.legacy
experiment.run(): experiment finished at Tue Aug 23 13:23:46 2011
NOW THE SAME SCRIPT WITH "EYELINK_CALIBRATE" ADDED AS THE FIRST ELEMENT.
experiment.init_sound(): sampling freq = 48000, buffer size = 512
video.legacy.init_display(): video mode ok
experiment.init_log(): using 'D:/Documents and Settings/cod.INTELSERVERWIN/Desktop\debug.csv' as logfile
experiment.run(): experiment started at Tue Aug 23 13:24:46 2011
keyboard.init(): morphing into openexp._keyboard.legacy
eyelink_calibrate(): logging tracker data as debug.edf
eyelink_calibrate(): loading libeyelink
canvas.init(): morphing into openexp._canvas.legacy
keyboard.init(): morphing into openexp._keyboard.legacy
mouse.init(): morphing into openexp._mouse.legacy
synth.init(): morphing into openexp._synth.legacy
Traceback (most recent call last):
File "D:\Documents and Settings\cod.INTELSERVERWIN\Desktop\opensesame-0.24\libqtopensesame\qtopensesame.py", line 1770, in run_experiment
exp.run()
File "D:\Documents and Settings\cod.INTELSERVERWIN\Desktop\opensesame-0.24\libopensesame\experiment.py", line 261, in run
self.items[self.start].prepare()
File "D:\Documents and Settings\cod.INTELSERVERWIN\Desktop\opensesame-0.24\libopensesame\sequence.py", line 91, in prepare
if not self.experiment.items[_item].prepare():
File "plugins\eyelink_calibrate\eyelink_calibrate.py", line 88, in prepare
self.experiment.eyelink = libeyelink.libeyelink(self.experiment, (self.get("width"), self.get("height")), data_file = data_file, saccade_velocity_threshold = self.get("sacc_vel_thresh"), saccade_acceleration_threshold = self.get("sacc_acc_thresh"))
File "plugins\eyelink_calibrate\libeyelink.py", line 93, in init
graphics_env = eyelink_graphics(self.experiment, _eyelink)
File "plugins\eyelink_calibrate\libeyelink.py", line 704, in init
self.target_beep = synth(self.experiment, length = 50)
File "D:\Documents and Settings\cod.INTELSERVERWIN\Desktop\opensesame-0.24\openexp\synth.py", line 38, in init
exec("openexp._synth.%s.%s.init(self, experiment, osc, freq, length, attack, decay)" % (experiment.synth_backend, experiment.synth_backend))
File "", line 1, in
File "D:\Documents and Settings\cod.INTELSERVERWIN\Desktop\opensesame-0.24\openexp_synth\legacy.py", line 88, in init
self.sound = pygame.mixer.Sound(b)
error: mixer system not initialized
The problem is definitely sound playback then. The synth is used during the calibration to give the auditory feedback, so the synth call is not, in itself, strange. I'm not sure why the sound doesn't work though...
I'd like to get to the bottom of this, but if you're in a hurry a quick fix for now would be to comment out all the references to self.__target_beep (and the other synth objects) in eyelink_calibrate/libeyelink.py. The calibration will then be silent but should otherwise be fine. (Maybe it would be a good idea to make sound optional during calibration anyway.)
Let me know how it goes!
Check out SigmundAI.eu for our OpenSesame AI assistant!
Hi,
Thanks - you hit the nail right on the head. There is something funky with the soundcard on this computer. Our lab manager is a big technofile, so every computer in the lab is hacked with different video and sound cards, different hard-drives, multiple operating systems etc.... I think some issues creep in when this is done and that's why I'm having so much trouble (I had no trouble at all when I used OpenSesame with Pylink on an 'off the rack' laptop). I'll talk to the people in the lab and see if we can straighten out the soundcard issue. Thanks again!
Mark
Good, I'll mark it as solved then. But the lesson learned is that OpenSesame error messages could be a little more informative in some cases!
Check out SigmundAI.eu for our OpenSesame AI assistant!
Thanks very much - my lab manager got the soundcard working and everything seems to be running fine now.
Thanks!
Mark