GUI v2 freezing, wrong sample rate?
Hello:
I have installed the new V2 of the GUI on my Mac running Sierra. If I run the compiled version, it will stream data for 1-2 seconds and then the GUI freezes. I have to shut it down and power down the dongle and board, then start over, and the same thing happens. When I run the GUI v2 in Processing by downloading the code, it streams better, but if I try to alter my channel setup (change the channels included in the Bias, etc.), the stream locks up and no more data gets collected. I get the following error message on the Processsing console:
Error, disabling serialEvent() for /dev/tty.usbserial-DJ00ISMD
null
v1 of the GUI still works, but I really like the new features of v2 and would love to use it. I bought my Cyton plus Daisy (16 channel system) in December, so I believe it should have the most recent firmware. Please let me know if you have any ideas. I'm excited about using the system for my research, but am concerned about its stability.
Thanks!
Dan Fletcher
Comments
Dan
Dan
Dan
Dan
p.p1 {margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Helvetica; -webkit-text-stroke: #000000}
p.p2 {margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Helvetica; -webkit-text-stroke: #000000; min-height: 14.0px}
span.s1 {font-kerning: none}
// Daisy board 16 channels, sampling rate 125 Hz
case 2:
//loop over all of the pre-defined filter types
n_filt = filtCoeff_notch.length;
for (int Ifilt=0; Ifilt < n_filt; Ifilt++) {
switch (Ifilt) {
case 0:
//60 Hz notch filter, assumed fs = 200 Hz. 2nd Order Butterworth: b, a = signal.butter(2,[59.0 61.0]/(fs_Hz / 2.0), 'bandstop')
b2 = new double[] { 0.931378858122982, 3.70081291785747, 5.5390319127052, 3.70081291785747, 0.931378858122982 };
a2 = new double[] { 1, 3.83246204081167, 5.53431749515949, 3.56916379490328, 0.867472133791669 };
filtCoeff_notch[Ifilt] = new FilterConstants(b2, a2, "Notch 60Hz", "60Hz");
break;
case 1:
//50 Hz notch filter, assumed fs = 200 Hz. 2nd Order Butterworth: b, a = signal.butter(2,[49.0 51.0]/(fs_Hz / 2.0), 'bandstop')
b2 = new double[] { 0.931378858122983, 3.0178169314316, 4.30731047590091, 3.0178169314316, 0.931378858122983};
a2 = new double[] { 1, 3.12516981877757, 4.3025960583552, 2.91046404408562, 0.86747213379167};
filtCoeff_notch[Ifilt] = new FilterConstants(b2, a2, "Notch 50Hz", "50Hz");
break;
case 2:
//no notch filter
b2 = new double[] { 1.0 };
a2 = new double[] { 1.0 };
filtCoeff_notch[Ifilt] = new FilterConstants(b2, a2, "No Notch", "None");
break;
}
} // end loop over notch filters
n_filt = filtCoeff_bp.length;
for (int Ifilt=0; Ifilt<n_filt; Ifilt++) {
//define bandpass filter
switch (Ifilt) {
case 0:
//butter(2,[1 50]/(200/2)); %bandpass filter
b = new double[] {
0.615877232553134, 0, -1.23175446510627, 0, 0.615877232553134
};
a = new double[] {
1, -0.789307541613509, -0.853263915766876, 0.263710995896442, 0.385190413112446
};
filt_txt = "Bandpass 1-50Hz";
short_txt = "1-50 Hz";
break;
case 1:
//butter(2,[7 13]/(200/2));
b = new double[] {
0.0186503962278356, 0, -0.0373007924556712, 0, 0.0186503962278356
};
a = new double[] {
1, -3.17162467236842, 4.11670870329067, -2.55619949640702, 0.652837763407545
};
filt_txt = "Bandpass 7-13Hz";
short_txt = "7-13 Hz";
break;
case 2:
//[b,a]=butter(2,[15 50]/(200/2)); %matlab command
b = new double[] {
0.350346377855414, 0, -0.700692755710827, 0, 0.350346377855414
};
a = new double[] {
1, 0.175228265043619, -0.211846955102387, 0.0137230352398753, 0.180232073898346
};
filt_txt = "Bandpass 15-50Hz";
short_txt = "15-50 Hz";
break;
case 3:
//[b,a]=butter(2,[5 50]/(200/2)); %matlab command
b = new double[] {
0.529967227069348, 0, -1.0599344541387, 0, 0.529967227069348
};
a = new double[] {
1, -0.517003774490769, -0.734318454224822, 0.103843398397761, 0.294636527587914
};
filt_txt = "Bandpass 5-50Hz";
short_txt = "5-50 Hz";
break;
default:
//no filtering
b = new double[] {
1.0
};
a = new double[] {
1.0
};
filt_txt = "No BP Filter";
short_txt = "No Filter";
} //end switch block
//create the bandpass filter
filtCoeff_bp[Ifilt] = new FilterConstants(b, a, filt_txt, short_txt);
} //end loop over band pass filters
break;
Dan
Dan