logston / olimex-ekg-emg

A Python package for gathering data from the Olimex EKG/EMG Shield.
Other
17 stars 7 forks source link

Exception in Tkinter callback #10

Closed AugustoCiuffoletti closed 7 years ago

AugustoCiuffoletti commented 7 years ago

I've just installed the sketch and your package, using pip, in a virtualenv with python3 on ubuntu 16.04. I run the arduino IDE terminal on the port and data are flowing.

When I issue the exg -p /dev/ttyUSB0 command I have the following output:

(py3env) augusto@laplenovo:~/Documenti/Elettronica/Arduino/Olimex-ECG$ exg -p /dev/ttyUSB0
Exception in Tkinter callback
Traceback (most recent call last):
  File "/usr/lib/python3.5/tkinter/__init__.py", line 1553, in __call__
    return self.func(*args)
  File "/usr/lib/python3.5/tkinter/__init__.py", line 599, in callit
    func(*args)
  File "/home/augusto/Documenti/Elettronica/Arduino/Olimex-ECG/py3env/lib/python3.5/site-packages/matplotlib/backends/backend_tkagg.py", line 144, in _on_timer
    TimerBase._on_timer(self)
  File "/home/augusto/Documenti/Elettronica/Arduino/Olimex-ECG/py3env/lib/python3.5/site-packages/matplotlib/backend_bases.py", line 1311, in _on_timer
    ret = func(*args, **kwargs)
  File "/home/augusto/Documenti/Elettronica/Arduino/Olimex-ECG/py3env/lib/python3.5/site-packages/matplotlib/animation.py", line 1243, in _step
    self._init_draw()
  File "/home/augusto/Documenti/Elettronica/Arduino/Olimex-ECG/py3env/lib/python3.5/site-packages/matplotlib/animation.py", line 1490, in _init_draw
    self._draw_frame(next(self.new_frame_seq()))
  File "/home/augusto/Documenti/Elettronica/Arduino/Olimex-ECG/py3env/lib/python3.5/site-packages/matplotlib/animation.py", line 1512, in _draw_frame
    self._drawn_artists = self._func(framedata, *self._args)
  File "/home/augusto/Documenti/Elettronica/Arduino/Olimex-ECG/py3env/lib/python3.5/site-packages/olimex/gui.py", line 157, in <lambda>
    ani = animation.FuncAnimation(fig, lambda _: next(axes_updater_gen),
StopIteration

The graphic interface shows up but it's blank, and remains such. Here is the trace of a re-installation (uninstall/install), so that you see the packages I use:

(py3env) augusto@laplenovo:~/Documenti/Elettronica/Arduino/Olimex-ECG$ pip install olimex-ekg-emg
Collecting olimex-ekg-emg
Requirement already satisfied: numpy>=1.9.1 in ./py3env/lib/python3.5/site-packages (from olimex-ekg-emg)
Requirement already satisfied: scipy>=0.15.1 in ./py3env/lib/python3.5/site-packages (from olimex-ekg-emg)
Requirement already satisfied: pyserial>=2.7 in ./py3env/lib/python3.5/site-packages (from olimex-ekg-emg)
Requirement already satisfied: matplotlib>=1.4.2 in ./py3env/lib/python3.5/site-packages (from olimex-ekg-emg)
Requirement already satisfied: pyparsing!=2.0.0,!=2.0.4,!=2.1.2,!=2.1.6,>=1.5.6 in ./py3env/lib/python3.5/site-packages (from matplotlib>=1.4.2->olimex-ekg-emg)
Requirement already satisfied: pytz in ./py3env/lib/python3.5/site-packages (from matplotlib>=1.4.2->olimex-ekg-emg)
Requirement already satisfied: python-dateutil in ./py3env/lib/python3.5/site-packages (from matplotlib>=1.4.2->olimex-ekg-emg)
Requirement already satisfied: cycler>=0.10 in ./py3env/lib/python3.5/site-packages (from matplotlib>=1.4.2->olimex-ekg-emg)
Requirement already satisfied: six>=1.10 in ./py3env/lib/python3.5/site-packages (from matplotlib>=1.4.2->olimex-ekg-emg)
Installing collected packages: olimex-ekg-emg
Successfully installed olimex-ekg-emg-0.1.10

Any help is welcome...

Thank you!

logston commented 7 years ago

Hi @AugustoCiuffoletti! Thanks for reaching out. These bug reports are very helpful. I'm not immediately sure what the issue is here. However, I'm not sure if it would be fruitful to debug now. I am working on an updated version of this library for use within the jupyter notebook. I will be displaying my work at PyCon 2017. Can you hold out another month while I finish that version?

Thanks.

AugustoCiuffoletti commented 7 years ago

Sure. Meanwhile,. if I find the time I'll study your code and see if I solve the problem by myself. In case I'll tell you.

Congrats (and best wishes) for the PyCon participation.

Augusto

2017-02-25 21:20 GMT+01:00 Paul notifications@github.com:

Hi @AugustoCiuffoletti https://github.com/AugustoCiuffoletti! Thanks for reaching out. These bug reports are very helpful. I'm not immediately sure what the issue is here. However, I'm not sure if it would be fruitful to debug now. I am working on an updated version of this library for use within the jupyter notebook. I will be displaying my work at PyCon 2017. Can you hold out another month while I finish that version?

Thanks.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/logston/olimex-ekg-emg/issues/10#issuecomment-282509645, or mute the thread https://github.com/notifications/unsubscribe-auth/AYj_6zDlrq_A0mMWY_dJGOBtmqqa48Igks5rgI0QgaJpZM4MLEDD .

-- Augusto Ciuffoletti Dipartimento di Informatica Università di Pisa 56100 - Pisa (Italy)

logston commented 7 years ago

Just released 0.2.0. Let me know if it works for you.

AugustoCiuffoletti commented 7 years ago

Meanwhile I developed my own, sorry: you can find it at

https://github.com/AugustoCiuffoletti/Olimex-EKG_plotter

2017-04-26 4:07 GMT+02:00 Paul notifications@github.com:

Just released 0.2.0. Let me know if it works for you.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/logston/olimex-ekg-emg/issues/10#issuecomment-297216767, or mute the thread https://github.com/notifications/unsubscribe-auth/AYj_6ySkKFFHPuQDO-tVvWEapFzO-Efoks5rzqbGgaJpZM4MLEDD .

-- Augusto Ciuffoletti Dipartimento di Informatica Università di Pisa 56100 - Pisa (Italy)

logston commented 7 years ago

Nice!