#include <AgcShiftForFftInt32.h>
#include "ucps2.h"
#include "ucpm2.h"

void AgcShiftForFftInt32(int ConfigAddr,int InAddr_1,int InAddr_2,int ReNum,int nSyms,
		int AgcAddr_1,int AgcAddr_2,int OutAddr_1,int OutAddr_2)
{
	 int *Para = (int *)ConfigAddr;
	 int temp0 = (ReNum+15)>>4;
	 int i;

	 Para[0] = nSyms;
	 Para[1] = temp0;


	 Para[1*16] = AgcAddr_1;

	 Para[2*16] = AgcAddr_2;

	 Para[3*16] = InAddr_1;
	 Para[3*16+1] = InAddr_1;
	 Para[3*16+5] = ReNum*4;
	 Para[3*16+8] = (temp0<<16)+temp0;

	 Para[4*16] = InAddr_2;
	 Para[4*16+1] = InAddr_2;
	 Para[4*16+5] = ReNum*4;
	 Para[4*16+8] = (temp0<<16)+temp0;

	 Para[5*16] = OutAddr_1;
	 Para[5*16+1] = OutAddr_1;
	 Para[5*16+5] = ReNum*4;
	 Para[5*16+8] = (temp0<<16)+temp0;
	 Para[5*16+12] = (temp0*(nSyms-1)*16+ReNum)*4;

	 Para[6*16] = OutAddr_2;
	 Para[6*16+1] = OutAddr_2;
	 Para[6*16+5] = ReNum*4;
	 Para[6*16+8] = (temp0<<16)+temp0;
	 Para[6*16+12] = (temp0*(nSyms-1)*16+ReNum)*4;

}
