How long KL81 TRNG module needs to generate 1M bytes random data?

cancel
Showing results for 
Search instead for 
Did you mean: 

How long KL81 TRNG module needs to generate 1M bytes random data?

236 Views
daweiy
Contributor I

Hi guys,

Currently, I am using KL81 to generate 1M bytes random data. It took me nearly 2 hours to finish it. The random data is sent out through UART. I did a measurement, 98.4% of the time is used by TRNG module, 1.6% of the time is used in UART communication.

I am using SDK library API, TRNG_DRV_GetRandomData(), to get 128 bytes random data at each call. The configuration of TRNG is got from TRNG_DRV_InitUserConfigDefault() and done by TRNG_DRV_Init(). The board is using external clock which is 12MHz and the system clock has been configured to 72 MHz because CLOCK_INIT_CONFIG has been configured to CLOCK_RUN.

By my understanding, if the random number generation is done by hardware, it should be much faster than by software. But under current situation, I just wondering to know is it normal or I have done something wrong?

Thanks,

Dawei

PS: the default entropy delay is 3200, after I changed it to 1500, 1M bytes data generation takes 50 minutes to finish. This is good but still not good enough to me. Please advise, thanks.

0 Kudos
0 Replies