 const int gg = lFilt*128;
 int16_t *pAddr; //pointer to 128 block of getBuffer
 int16_t lblock = numBlocks*128; //length of arrays
-int16_t ablock[128*numBlocks];  // set an array block
-int16_t error[128]; 
+int16_t ablock[128*numBlocks] __attribute__ ((aligned (4)));  // set an array block
+int16_t error[128] __attribute__ ((aligned (4)));
 int16_t *Perror;
 int16_t *pablock; // pointer to an array block
 int16_t *pp; // pointer to getBuffer

void getBuffer1();
void playData();
void displayData();
void NLMS_AEC();

// GUItool: begin automatically generated code
AudioInputI2S            Mic;           //microphone

// NMLS algorithm
// inputs are Mic Signal, far end signal and index of n-1 block wher n is the current block itteration
// previous block data is used to modify current block data samples
void NLMS_AEC(int16_t *x)
{
  int16_t yhat = 0;
  int64_t xtdl = 0;
