Skip to content

Commit

Permalink
small fix
Browse files Browse the repository at this point in the history
  • Loading branch information
corrados committed Jun 12, 2024
1 parent 0552ad4 commit 7b1da97
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 15 deletions.
21 changes: 15 additions & 6 deletions edrumulus.h
Original file line number Diff line number Diff line change
Expand Up @@ -109,12 +109,6 @@ class Edrumulus
byte read_setting ( const int pad_index, const int address ) { return edrumulus_hardware.read_setting ( pad_index, address ); }

protected:
void cancel_ADC_spikes ( float& signal,
int& overload_detected,
const int pad_index,
const int input_channel_index,
const int level );

// constant definitions
const int Fs = 8000; // this is the most fundamental system parameter: system sampling rate
const float dc_offset_est_len_s = 1.25f; // length of initial DC offset estimation in seconds
Expand Down Expand Up @@ -181,6 +175,21 @@ class Edrumulus
int cancel_MIDI_velocity;
int cancel_pad_index;

// ADC spike cancellation
void cancel_ADC_spikes ( float& signal,
int& overload_detected,
const int pad_index,
const int input_channel_index,
const int level );

enum Espikestate
{
ST_NOISE,
ST_SPIKE_HIGH,
ST_SPIKE_LOW,
ST_OTHER
};

Espikestate prev1_input_state[MAX_NUM_PADS][MAX_NUM_PAD_INPUTS];
Espikestate prev2_input_state[MAX_NUM_PADS][MAX_NUM_PAD_INPUTS];
Espikestate prev3_input_state[MAX_NUM_PADS][MAX_NUM_PAD_INPUTS];
Expand Down
9 changes: 0 additions & 9 deletions edrumulus_hardware.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,15 +22,6 @@
#include "edrumulus_util.h"


// Global hardware enums and definitions ---------------------------------------
enum Espikestate
{
ST_NOISE,
ST_SPIKE_HIGH,
ST_SPIKE_LOW,
ST_OTHER
};

#define MAX_EEPROM_SIZE 512 // bytes (Teensy 4.0: max 1024 bytes)
#define MAX_NUM_SET_PER_PAD 30 // maximum number of settings which can be stored per pad

Expand Down

0 comments on commit 7b1da97

Please sign in to comment.