 __device__ unsigned int spikeCountD1;
 
 // I believe the following are all just test variables
-__device__ int	testVarCnt;
-__device__ int	testVarCnt2;
-__device__ int	testVarCnt1;
 __device__ unsigned int	secD2fireCntTest;
 __device__ unsigned int	secD1fireCntTest;
-__device__ int  generatedSpikesE;
-__device__ int  generatedSpikesI;
-__device__ int  receivedSpikesE;
-__device__ int  receivedSpikesI;
-__device__ int  senderIdE[1000];
-__device__ int  senderIdI[1000];
-__device__ int  receiverId[1000];
 
 __device__ __constant__ network_ptr_t		gpuPtrs;
 __device__ __constant__ network_info_t		gpuNetInfo;

	 	for(int k=0; k < gpuNetInfo.numN; k++) {
		if ( gpuPtrs.neuronFiring[k]) {
			int i=1;
//				int pos = atomicAdd(&testVarCnt2, 7);
//				gpuPtrs.testVar2[pos]   = nid;
//				gpuPtrs.testVar2[pos+1] = ind_1;
//				gpuPtrs.testVar2[pos+2] = gpuPtrs.stpu[ind_1];
//				gpuPtrs.testVar2[pos+3] = gpuPtrs.stpx[ind_1];
//				gpuPtrs.testVar2[pos+4] = gpuPtrs.stpu[ind];
//				gpuPtrs.testVar2[pos+5] = gpuPtrs.stpx[ind];
//				gpuPtrs.testVar2[pos+6] = gpuPtrs.stpu[ind]*gpuPtrs.stpx[ind];
			retErrVal[nid][i++]= k;
			for(int t=0; t < 5; t++) {
				float stp = gpuPtrs.stpu[k]*gpuPtrs.stpx[k];

				int stdp_tDiff = (simTime - gpuPtrs.synSpikeTime[p]);
				if ((stdp_tDiff > 0) && ((stdp_tDiff*gpuGrpInfo[grpId].TAU_LTP_INV)<25)) {
					gpuPtrs.wtChange[p] += STDP(stdp_tDiff, gpuGrpInfo[grpId].ALPHA_LTP, gpuGrpInfo[grpId].TAU_LTP_INV);
				}
			}
		}
