//note that this only needs to filter the channels on this particular device public SALPA3(int length_sams,int asym_sams,int blank_sams,int ahead_sams, int forcepeg_sams, rawType railLow, rawType railHigh, int numElectrodes, int bufferLength, rawType[] thresh) { //MB defaults: this.length_sams = length_sams; // 75; this.asym_sams = asym_sams;// 10; this.blank_sams = blank_sams;// 75;//HACK try 20 this.ahead_sams = ahead_sams;// 5; //this.period_sams = period_sams;// 0; //this.delay_sams = 0; this.forcepeg_sams = forcepeg_sams;//10; this.thresh = thresh; this.numElectrodes = numElectrodes; this.railHigh = railHigh; this.railLow = railLow; this.numSamples = bufferLength; this.PRE = 2 * length_sams ; this.POST = 2 * length_sams + 1 + ahead_sams; fitters = new LocalFit[numElectrodes]; for (int i = 0; i < numElectrodes; i++) { fitters[i] = new LocalFit(thresh[i], length_sams, blank_sams, ahead_sams, asym_sams, railHigh, railLow, bufferLength, forcepeg_sams); } }
//note that this only needs to filter the channels on this particular device public SALPA3(int length_sams, int asym_sams, int blank_sams, int ahead_sams, int forcepeg_sams, rawType railLow, rawType railHigh, int numElectrodes, int bufferLength, rawType[] thresh) { //MB defaults: this.length_sams = length_sams; // 75; this.asym_sams = asym_sams; // 10; this.blank_sams = blank_sams; // 75;//HACK try 20 this.ahead_sams = ahead_sams; // 5; //this.period_sams = period_sams;// 0; //this.delay_sams = 0; this.forcepeg_sams = forcepeg_sams;//10; this.thresh = thresh; this.numElectrodes = numElectrodes; this.railHigh = railHigh; this.railLow = railLow; this.numSamples = bufferLength; this.PRE = 2 * length_sams; this.POST = 2 * length_sams + 1 + ahead_sams; fitters = new LocalFit[numElectrodes]; for (int i = 0; i < numElectrodes; i++) { fitters[i] = new LocalFit(thresh[i], length_sams, blank_sams, ahead_sams, asym_sams, railHigh, railLow, bufferLength, forcepeg_sams); } }