logston / olimex-ekg-emg

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

can't get data from olimex ekg/emg shield #7

Closed anastuta closed 7 years ago

anastuta commented 8 years ago

running gui.py gives me: runfile('C:/Anaconda3/Lib/site-packages/olimex/gui.py', wdir='C:/Anaconda3/Lib/site-packages/olimex') usage: gui.py [-h] [-p PORT] [-f FILE] [--list-mock-data] [--print-timing-data]

Run GUI for Olimex-EKG-EMG.

optional arguments: -h, --help show this help message and exit -p PORT, --port PORT Port to which an Arduino is connected (eg. /dev/tty.usbmodem1411) -f FILE, --file FILE File to stream EXG data from. Loads entire file prior to display. --list-mock-data List all mock data files available. --print-timing-data File to stream EXG data from. Loads entire file prior to display. 4446 function calls (4440 primitive calls) in 0.007 seconds

Ordered by: internal time List reduced from 147 to 25 due to restriction <25>

ncalls tottime percall cumtime percall filename:lineno(function) 20 0.001 0.000 0.001 0.000 {built-in method stat} 22 0.001 0.000 0.001 0.000 {method 'split' of '_sre.SRE_Pattern' objects} 22 0.000 0.000 0.001 0.000 C:\Anaconda3\envs\py34\lib\textwrap.py:219(_wrap_chunks) 81 0.000 0.000 0.001 0.000 C:\Anaconda3\envs\py34\lib\ntpath.py:139(splitdrive) 47 0.000 0.000 0.000 0.000 {method 'sub' of '_sre.SRE_Pattern' objects} 20 0.000 0.000 0.000 0.000 C:\Anaconda3\envs\py34\lib\argparse.py:591(_expand_help) 20 0.000 0.000 0.003 0.000 C:\Anaconda3\envs\py34\lib\argparse.py:485(_format_action) 249 0.000 0.000 0.000 0.000 {built-in method hasattr} 5 0.000 0.000 0.002 0.000 C:\Anaconda3\envs\py34\lib\gettext.py:356(find) 438 0.000 0.000 0.000 0.000 {built-in method isinstance} 22 0.000 0.000 0.000 0.000 {method 'translate' of 'str' objects} 6 0.000 0.000 0.000 0.000 C:\Anaconda3\envs\py34\lib\argparse.py:381(_format_actions_usage) 20 0.000 0.000 0.001 0.000 C:\Anaconda3\envs\py34\lib\ntpath.py:104(join) 1 0.000 0.000 0.000 0.000 {method 'send' of '_socket.socket' objects} 10 0.000 0.000 0.000 0.000 C:\Anaconda3\envs\py34\lib\gettext.py:113(_expand_lang) 580 0.000 0.000 0.000 0.000 {method 'append' of 'list' objects} 43 0.000 0.000 0.000 0.000 C:\Anaconda3\envs\py34\lib\re.py:277(_compile) 25 0.000 0.000 0.000 0.000 C:\Anaconda3\envs\py34\lib\argparse.py:604(_iter_indented_subactions) 25 0.000 0.000 0.000 0.000 C:\Anaconda3\envs\py34\lib\argparse.py:532(_format_action_invocation) 2 0.000 0.000 0.002 0.001 C:\Anaconda3\envs\py34\lib\argparse.py:289(_format_usage) 20 0.000 0.000 0.001 0.000 C:\Anaconda3\envs\py34\lib\genericpath.py:16(exists) 5 0.000 0.000 0.000 0.000 C:\Anaconda3\envs\py34\lib\argparse.py:1304(add_argument) 26 0.000 0.000 0.000 0.000 C:\Anaconda3\envs\py34\lib\os.py:630(getitem) 6 0.000 0.000 0.000 0.000 C:\Anaconda3\envs\py34\lib\argparse.py:151(init) 20 0.000 0.000 0.002 0.000 C:\Anaconda3\envs\py34\lib\textwrap.py:354(wrap)

and no plot appears.

running in terminal 'exg -p com1' a plotting windows appears but no data inside. it is just a blank plot.

logston commented 8 years ago

@anastuta I think you might be using a backend that doesn't support animations. Can you run this command for me and post the results:

$ python -c "import matplotlib; print(matplotlib.rcParams)"
anastuta commented 8 years ago

this is the result:

agg.path.chunksize: 0 animation.avconv_args: [] animation.avconv_path: avconv animation.bitrate: -1 animation.codec: mpeg4 animation.convert_args: [] animation.convert_path: convert animation.ffmpeg_args: [] animation.ffmpeg_path: ffmpeg animation.frame_format: png animation.html: none animation.mencoder_args: [] animation.mencoder_path: mencoder animation.writer: ffmpeg axes.axisbelow: False axes.edgecolor: k axes.facecolor: w axes.formatter.limits: [-7, 7] axes.formatter.use_locale: False axes.formatter.use_mathtext: False axes.formatter.useoffset: True axes.grid: False axes.grid.axis: both axes.grid.which: major axes.hold: True axes.labelcolor: k axes.labelpad: 5.0 axes.labelsize: medium axes.labelweight: normal axes.linewidth: 1.0 axes.prop_cycle: cycler('color', ['b', 'g', 'r', 'c', 'm', 'y', 'k']) axes.spines.bottom: True axes.spines.left: True axes.spines.right: True axes.spines.top: True axes.titlesize: large axes.titleweight: normal axes.unicode_minus: True axes.xmargin: 0.0 axes.ymargin: 0.0 axes3d.grid: True backend: Qt4Agg backend.qt4: PyQt4 backend.qt5: PyQt5 backend_fallback: True boxplot.bootstrap: None boxplot.boxprops.color: b boxplot.boxprops.linestyle: - boxplot.boxprops.linewidth: 1.0 boxplot.capprops.color: k boxplot.capprops.linestyle: - boxplot.capprops.linewidth: 1.0 boxplot.flierprops.color: b boxplot.flierprops.linestyle: none boxplot.flierprops.linewidth: 1.0 boxplot.flierprops.marker: + boxplot.flierprops.markeredgecolor: k boxplot.flierprops.markerfacecolor: b boxplot.flierprops.markersize: 6.0 boxplot.meanline: False boxplot.meanprops.color: r boxplot.meanprops.linestyle: - boxplot.meanprops.linewidth: 1.0 boxplot.medianprops.color: r boxplot.medianprops.linestyle: - boxplot.medianprops.linewidth: 1.0 boxplot.notch: False boxplot.patchartist: False boxplot.showbox: True boxplot.showcaps: True boxplot.showfliers: True boxplot.showmeans: False boxplot.vertical: True boxplot.whiskerprops.color: b boxplot.whiskerprops.linestyle: -- boxplot.whiskerprops.linewidth: 1.0 boxplot.whiskers: 1.5 contour.corner_mask: True contour.negative_linestyle: dashed datapath: C:\Anaconda3\lib\site-packages\matplotlib\mpl-data docstring.hardcopy: False errorbar.capsize: 3.0 examples.directory: figure.autolayout: False figure.dpi: 80.0 figure.edgecolor: w figure.facecolor: 0.75 figure.figsize: [8.0, 6.0] figure.frameon: True figure.max_open_warning: 20 figure.subplot.bottom: 0.1 figure.subplot.hspace: 0.2 figure.subplot.left: 0.125 figure.subplot.right: 0.9 figure.subplot.top: 0.9 figure.subplot.wspace: 0.2 figure.titlesize: medium figure.titleweight: normal font.cursive: ['Apple Chancery', 'Textile', 'Zapf Chancery', 'Sand', 'Script MT', 'Felipa', 'cursive'] font.family: ['sans-serif'] font.fantasy: ['Comic Sans MS', 'Chicago', 'Charcoal', 'ImpactWestern', 'Humor Sans', 'fantasy'] font.monospace: ['Bitstream Vera Sans Mono', 'DejaVu Sans Mono', 'Andale Mono', 'Nimbus Mono L', 'Courier New', 'Courier', 'Fixed', 'Terminal', 'monospace'] font.sans-serif: ['Bitstream Vera Sans', 'DejaVu Sans', 'Lucida Grande', 'Verdana', 'Geneva', 'Lucid', 'Arial', 'Helvetica', 'Avant Garde', 'sans-serif'] font.serif: ['Bitstream Vera Serif', 'DejaVu Serif', 'New Century Schoolbook', 'Century Schoolbook L', 'Utopia', 'ITC Bookman', 'Bookman', 'Nimbus Roman No9 L', 'Times New Roman', 'Times', 'Palatino', 'Charter', 'serif'] font.size: 12.0 font.stretch: normal font.style: normal font.variant: normal font.weight: normal grid.alpha: 1.0 grid.color: k grid.linestyle: : grid.linewidth: 0.5 image.aspect: equal image.cmap: jet image.composite_image: True image.interpolation: bilinear image.lut: 256 image.origin: upper image.resample: False interactive: False keymap.all_axes: ['a'] keymap.back: ['left', 'c', 'backspace'] keymap.forward: ['right', 'v'] keymap.fullscreen: ['f', 'ctrl+f'] keymap.grid: ['g'] keymap.home: ['h', 'r', 'home'] keymap.pan: ['p'] keymap.quit: ['ctrl+w', 'cmd+w'] keymap.save: ['s', 'ctrl+s'] keymap.xscale: ['k', 'L'] keymap.yscale: ['l'] keymap.zoom: ['o'] legend.borderaxespad: 0.5 legend.borderpad: 0.4 legend.columnspacing: 2.0 legend.edgecolor: inherit legend.facecolor: inherit legend.fancybox: False legend.fontsize: large legend.framealpha: None legend.frameon: True legend.handleheight: 0.7 legend.handlelength: 2.0 legend.handletextpad: 0.8 legend.isaxes: True legend.labelspacing: 0.5 legend.loc: upper right legend.markerscale: 1.0 legend.numpoints: 2 legend.scatterpoints: 3 legend.shadow: False lines.antialiased: True lines.color: b lines.dash_capstyle: butt lines.dash_joinstyle: round lines.linestyle: - lines.linewidth: 1.0 lines.marker: None lines.markeredgewidth: 0.5 lines.markersize: 6.0 lines.solid_capstyle: projecting lines.solid_joinstyle: round markers.fillstyle: full mathtext.bf: serif:bold mathtext.cal: cursive mathtext.default: it mathtext.fallback_to_cm: True mathtext.fontset: cm mathtext.it: serif:italic mathtext.rm: serif mathtext.sf: sans-serif mathtext.tt: monospace nbagg.transparent: True patch.antialiased: True patch.edgecolor: k patch.facecolor: b patch.linewidth: 1.0 path.effects: [] path.simplify: True path.simplify_threshold: 0.1111111111111111 path.sketch: None path.snap: True pdf.compression: 6 pdf.fonttype: 3 pdf.inheritcolor: False pdf.use14corefonts: False pgf.debug: False pgf.preamble: [] pgf.rcfonts: True pgf.texsystem: xelatex plugins.directory: .matplotlib_plugins polaraxes.grid: True ps.distiller.res: 6000 ps.fonttype: 3 ps.papersize: letter ps.useafm: False ps.usedistiller: False savefig.bbox: None savefig.directory: ~ savefig.dpi: 100.0 savefig.edgecolor: w savefig.facecolor: w savefig.format: png savefig.frameon: True savefig.jpeg_quality: 95 savefig.orientation: portrait savefig.pad_inches: 0.1 savefig.transparent: False svg.fonttype: path svg.image_inline: True svg.image_noscale: False text.antialiased: True text.color: k text.dvipnghack: None text.hinting: auto text.hinting_factor: 8 text.latex.preamble: [] text.latex.preview: False text.latex.unicode: False text.usetex: False timezone: UTC tk.window_focus: False toolbar: toolbar2 verbose.fileo: sys.stdout verbose.level: silent webagg.open_in_browser: True webagg.port: 8988 webagg.port_retries: 50 xtick.color: k xtick.direction: in xtick.labelsize: medium xtick.major.pad: 4.0 xtick.major.size: 4.0 xtick.major.width: 0.5 xtick.minor.pad: 4.0 xtick.minor.size: 2.0 xtick.minor.visible: False xtick.minor.width: 0.5 ytick.color: k ytick.direction: in ytick.labelsize: medium ytick.major.pad: 4.0 ytick.major.size: 4.0 ytick.major.width: 0.5 ytick.minor.pad: 4.0 ytick.minor.size: 2.0 ytick.minor.visible: False ytick.minor.width: 0.5

and attached

On Sat, May 7, 2016 at 8:00 AM, Paul notifications@github.com wrote:

@anastuta https://github.com/anastuta I think you might be using a backend that doesn't support animations. Can you run this command for me and post the results:

$ python -c "import matplotlib; print(matplotlib.rcParams)"

— You are receiving this because you were mentioned. Reply to this email directly or view it on GitHub https://github.com/logston/olimex-ekg-emg/issues/7#issuecomment-217607964

Dr. Andrei Vasile NASTUTA Plasma Physics Laboratory Iasi Plasma Advanced Research Center (IPARC) Faculty of Physics "Alexandru Ioan Cuza" University of Iasi Blvd. Carol I, no. 11, Iasi, 700506, Romania Tel: 0040 232 20 11 88 Fax: 0040 232 20 11 50 http://sites.google.com/site/nastutaandreivasile/ http://www.plasma.uaic.ro/staff/andrei-vasile-nastuta/

agg.path.chunksize: 0 animation.avconv_args: [] animation.avconv_path: avconv animation.bitrate: -1 animation.codec: mpeg4 animation.convert_args: [] animation.convert_path: convert animation.ffmpeg_args: [] animation.ffmpeg_path: ffmpeg animation.frame_format: png animation.html: none animation.mencoder_args: [] animation.mencoder_path: mencoder animation.writer: ffmpeg axes.axisbelow: False axes.edgecolor: k axes.facecolor: w axes.formatter.limits: [-7, 7] axes.formatter.use_locale: False axes.formatter.use_mathtext: False axes.formatter.useoffset: True axes.grid: False axes.grid.axis: both axes.grid.which: major axes.hold: True axes.labelcolor: k axes.labelpad: 5.0 axes.labelsize: medium axes.labelweight: normal axes.linewidth: 1.0 axes.prop_cycle: cycler('color', ['b', 'g', 'r', 'c', 'm', 'y', 'k']) axes.spines.bottom: True axes.spines.left: True axes.spines.right: True axes.spines.top: True axes.titlesize: large axes.titleweight: normal axes.unicode_minus: True axes.xmargin: 0.0 axes.ymargin: 0.0 axes3d.grid: True backend: Qt4Agg backend.qt4: PyQt4 backend.qt5: PyQt5 backend_fallback: True boxplot.bootstrap: None boxplot.boxprops.color: b boxplot.boxprops.linestyle: - boxplot.boxprops.linewidth: 1.0 boxplot.capprops.color: k boxplot.capprops.linestyle: - boxplot.capprops.linewidth: 1.0 boxplot.flierprops.color: b boxplot.flierprops.linestyle: none boxplot.flierprops.linewidth: 1.0 boxplot.flierprops.marker: + boxplot.flierprops.markeredgecolor: k boxplot.flierprops.markerfacecolor: b boxplot.flierprops.markersize: 6.0 boxplot.meanline: False boxplot.meanprops.color: r boxplot.meanprops.linestyle: - boxplot.meanprops.linewidth: 1.0 boxplot.medianprops.color: r boxplot.medianprops.linestyle: - boxplot.medianprops.linewidth: 1.0 boxplot.notch: False boxplot.patchartist: False boxplot.showbox: True boxplot.showcaps: True boxplot.showfliers: True boxplot.showmeans: False boxplot.vertical: True boxplot.whiskerprops.color: b boxplot.whiskerprops.linestyle: -- boxplot.whiskerprops.linewidth: 1.0 boxplot.whiskers: 1.5 contour.corner_mask: True contour.negative_linestyle: dashed datapath: C:\Anaconda3\lib\site-packages\matplotlib\mpl-data docstring.hardcopy: False errorbar.capsize: 3.0 examples.directory: figure.autolayout: False figure.dpi: 80.0 figure.edgecolor: w figure.facecolor: 0.75 figure.figsize: [8.0, 6.0] figure.frameon: True figure.max_open_warning: 20 figure.subplot.bottom: 0.1 figure.subplot.hspace: 0.2 figure.subplot.left: 0.125 figure.subplot.right: 0.9 figure.subplot.top: 0.9 figure.subplot.wspace: 0.2 figure.titlesize: medium figure.titleweight: normal font.cursive: ['Apple Chancery', 'Textile', 'Zapf Chancery', 'Sand', 'Script MT', 'Felipa', 'cursive'] font.family: ['sans-serif'] font.fantasy: ['Comic Sans MS', 'Chicago', 'Charcoal', 'ImpactWestern', 'Humor Sans', 'fantasy'] font.monospace: ['Bitstream Vera Sans Mono', 'DejaVu Sans Mono', 'Andale Mono', 'Nimbus Mono L', 'Courier New', 'Courier', 'Fixed', 'Terminal', 'monospace'] font.sans-serif: ['Bitstream Vera Sans', 'DejaVu Sans', 'Lucida Grande', 'Verdana', 'Geneva', 'Lucid', 'Arial', 'Helvetica', 'Avant Garde', 'sans-serif'] font.serif: ['Bitstream Vera Serif', 'DejaVu Serif', 'New Century Schoolbook', 'Century Schoolbook L', 'Utopia', 'ITC Bookman', 'Bookman', 'Nimbus Roman No9 L', 'Times New Roman', 'Times', 'Palatino', 'Charter', 'serif'] font.size: 12.0 font.stretch: normal font.style: normal font.variant: normal font.weight: normal grid.alpha: 1.0 grid.color: k grid.linestyle: : grid.linewidth: 0.5 image.aspect: equal image.cmap: jet image.composite_image: True image.interpolation: bilinear image.lut: 256 image.origin: upper image.resample: False interactive: False keymap.all_axes: ['a'] keymap.back: ['left', 'c', 'backspace'] keymap.forward: ['right', 'v'] keymap.fullscreen: ['f', 'ctrl+f'] keymap.grid: ['g'] keymap.home: ['h', 'r', 'home'] keymap.pan: ['p'] keymap.quit: ['ctrl+w', 'cmd+w'] keymap.save: ['s', 'ctrl+s'] keymap.xscale: ['k', 'L'] keymap.yscale: ['l'] keymap.zoom: ['o'] legend.borderaxespad: 0.5 legend.borderpad: 0.4 legend.columnspacing: 2.0 legend.edgecolor: inherit legend.facecolor: inherit legend.fancybox: False legend.fontsize: large legend.framealpha: None legend.frameon: True legend.handleheight: 0.7 legend.handlelength: 2.0 legend.handletextpad: 0.8 legend.isaxes: True legend.labelspacing: 0.5 legend.loc: upper right legend.markerscale: 1.0 legend.numpoints: 2 legend.scatterpoints: 3 legend.shadow: False lines.antialiased: True lines.color: b lines.dash_capstyle: butt lines.dash_joinstyle: round lines.linestyle: - lines.linewidth: 1.0 lines.marker: None lines.markeredgewidth: 0.5 lines.markersize: 6.0 lines.solid_capstyle: projecting lines.solid_joinstyle: round markers.fillstyle: full mathtext.bf: serif:bold mathtext.cal: cursive mathtext.default: it mathtext.fallback_to_cm: True mathtext.fontset: cm mathtext.it: serif:italic mathtext.rm: serif mathtext.sf: sans-serif mathtext.tt: monospace nbagg.transparent: True patch.antialiased: True patch.edgecolor: k patch.facecolor: b patch.linewidth: 1.0 path.effects: [] path.simplify: True path.simplify_threshold: 0.1111111111111111 path.sketch: None path.snap: True pdf.compression: 6 pdf.fonttype: 3 pdf.inheritcolor: False pdf.use14corefonts: False pgf.debug: False pgf.preamble: [] pgf.rcfonts: True pgf.texsystem: xelatex plugins.directory: .matplotlib_plugins polaraxes.grid: True ps.distiller.res: 6000 ps.fonttype: 3 ps.papersize: letter ps.useafm: False ps.usedistiller: False savefig.bbox: None savefig.directory: ~ savefig.dpi: 100.0 savefig.edgecolor: w savefig.facecolor: w savefig.format: png savefig.frameon: True savefig.jpeg_quality: 95 savefig.orientation: portrait savefig.pad_inches: 0.1 savefig.transparent: False svg.fonttype: path svg.image_inline: True svg.image_noscale: False text.antialiased: True text.color: k text.dvipnghack: None text.hinting: auto text.hinting_factor: 8 text.latex.preamble: [] text.latex.preview: False text.latex.unicode: False text.usetex: False timezone: UTC tk.window_focus: False toolbar: toolbar2 verbose.fileo: sys.stdout verbose.level: silent webagg.open_in_browser: True webagg.port: 8988 webagg.port_retries: 50 xtick.color: k xtick.direction: in xtick.labelsize: medium xtick.major.pad: 4.0 xtick.major.size: 4.0 xtick.major.width: 0.5 xtick.minor.pad: 4.0 xtick.minor.size: 2.0 xtick.minor.visible: False xtick.minor.width: 0.5 ytick.color: k ytick.direction: in ytick.labelsize: medium ytick.major.pad: 4.0 ytick.major.size: 4.0 ytick.major.width: 0.5 ytick.minor.pad: 4.0 ytick.minor.size: 2.0 ytick.minor.visible: False ytick.minor.width: 0.5

logston commented 8 years ago

Sure enough. Looks like there is a bug here. Not sure what the bug is or where its at though. Just to prepare you, I'm not sure I'll be able to getting to fix this for the next few month or so. Sorry for the delay.

logston commented 8 years ago

@anastuta Can you download the latest version and close this ticket if your issue has been fixed. I will close this bug in a week if I don't hear from you. Thanks.

logston commented 7 years ago

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