rourabpaul
Member level 3
i am sending some bytes by rs232 in sparta3e board in xilinx edk tool
i have array A[1,2,3,4,5]
and a another array initialized as B[0,0,0,0,0],
say i write
a1=A[2]; //(a1 is 8 bit integer )
B[a1]=B[a1]+1;
so the B should be
B[0,0,0,1,0]
but i get B[0,0,0,0,0],
but if i send only 'a1',then i got 3,
why its happening ?
is there any solutions?
i have array A[1,2,3,4,5]
and a another array initialized as B[0,0,0,0,0],
say i write
a1=A[2]; //(a1 is 8 bit integer )
B[a1]=B[a1]+1;
so the B should be
B[0,0,0,1,0]
but i get B[0,0,0,0,0],
but if i send only 'a1',then i got 3,
why its happening ?
is there any solutions?