cont.cpp 528 Bytes
Newer Older
Andrei Tosa's avatar
Andrei Tosa committed
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#include "cont.hpp"


void cont(const unsigned seed, const unsigned count, unsigned *out) {

#pragma HLS INTERFACE m_axi port=out  offset=slave bundle=gmem
#pragma HLS INTERFACE s_axilite port=seed bundle=control
#pragma HLS INTERFACE s_axilite port=out  bundle=control
#pragma HLS INTERFACE s_axilite port=return bundle=control


#pragma HLS DATAFLOW
    stream<unsigned> rndout;
#pragma HLS STREAM variable = rndout depth = 16

    rndgen(seed, count, rndout);

    for (int i = 0; i < count; i++)
        rndout >> out[i];
}