NeuroTechX / eeg-notebooks_v0.1

Previous version of eeg-notebooks
https://neurotechx.github.io/eeg-notebooks
BSD 3-Clause "New" or "Revised" License
184 stars 56 forks source link

Issues running on Windows #4

Closed jdpigeon closed 4 years ago

jdpigeon commented 6 years ago

This issue will host advanced instructions, common issues, and discussion related to setting up and running EEG notebooks on Windows computers.

Common Issues

  1. pygatt.exceptions.NotConnectedError: No BGAPI compatible device detected
    • If you are using a dongle and getting the error you may need to make a quick fix to your system's version of the pygatt library. First, find the folder where bgapi.py is running with the following:
      python
      import os
      import pygatt
      print(os.path.join(os.path.dirname(pygatt.__file__), 'backends', 'bgapi', 'bgapi.py'))

      Then add the following to line 191 of bgapi.py and save: time.sleep(.25)

  1. Psychopy scripts failing with errors like

Exception AttributeError: "'NoneType' object has no attribute 'close'" in <bound method Window.__del__ of <psychopy.visual.window.Window object at 0x0000000012136898>> ignored

and/or

es\pyglet\libs\win32\__init__.py", line 237, in <module> _user32.GetRawInputData.argtypes = [HRAWINPUT, UINT, LPVOID, PUINT, UINT] NameError: name 'PUINT' is not defined

This occurs if the an unsupported pyglet version is being used.

Currently pyglet versions 1.3.1 + don't seem to work on windows. Discussion of this here

The fix is:

pip install pyglet==1.2

(...which presumably you didn't already do that when installing)

  1. If psychopy is hanging, can't quit

This is a tricky one. You need to kill the terminal, which psychopy can make difficult.

The best trick I currently have when dealing with this problem is to swipe left on my touchscreen, and then kill the terminal by touching the 'x' to kill the anaconda terminal running psychopy.

This is of course not ideal.

  1. Psychopy running slowly

The visual tasks ( N170, P300 ) are rapid visual presentation paradigms. Sometimes psychopy appears to run much slower than it should do (e.g. taking several seconds for each picture) .

This appears to be primarily a RAM issue. This can be helped by:

This issue requires further assessment, quantification, and solutions.

  1. pygatt.exceptions.BLEError: No characteristic found matching 273e0003-4c4d-454d-96be-f03bac821358

This is an error message that comes after python muse-lsl.py has successfully detected a headband.

At a similar time I observed issues with the same headband connecting to BlueMuse and to the phone app.

I have observed that the solution described here appears to fix this (though not 100% sure it was the reason):

To solve the error, I had to connect once the headband with the official phone app, then it worked again.

  1. Conda installations give error 'permission denied'

I have noticed this on several occasions. It appears that simply re-running the installation command a second time will complete with no errors.

  1. Persistent disconnects with BlueMuse
    • Try downgrading BlueMuse to version 1.0.7.0, its the version that we've found is most stable