Just start learning HLS and XSDk. Currently I am working with number series.
My goal is to print number series sequentially as for N
times in Tera Terminal. While compiling the program codes, it's returning only last value.
My code:
void Numberseries1(ap_uint<32> seed, ap_uint<32> &dout) {
static ap_uint<32> reg[15];
int result=1;
int i;
for(i=0; i < 15;i++) if (result<seed) {
result *= 2; reg[i] =result; dout= reg[i];
}
}
FOR EXAMPLE : N=10
, it's returning only value 1024
. Instead of EXPECTED RESULT : 16,32,64,128,256,512,1024,
What do I need to do to get "number series" to print sequentially like 16,32,64,128,256,512,1024
, in Tera Terminal.