Implementing rng

Unfortunately, it doesn't. My problems are:

a) In the case of my board, the hardware RNG is not part of the CPU but instead of the radio chip, which is accessed by the code in driver/at86rf2xx.

b) If I implement the hwrng interface in the at86rf2xx code, how does the samr21-xpro board learn of this? I couldn't find the code/configuration, where the at86rf2xx driver is attached to that board.

c) Can I simply put the periph_hwrng feature in the board's Makefile.features if I know that that interface is implemented in some of its parts?

Thanks a lot for your assistance, I just want to create a good patch for this, which can easily be integrated with the upstream code.

cheers Mathias

Hi,

The Makefile.features defines the features of a board, that's why it lives in the boards directory. So yes, it is intended to declare the RNG in there even if it is not part of the CPU/SoC.

It would be architecturally nicer to have such files in various places (eg CPU, radio, board) and let them be included, but that has not been done for any board as far as I know. Also, I can't remember if there was a discussion about this possibility.

Cheers, Ludwig