trng 1.0
trng driver library
Loading...
Searching...
No Matches
trng.h
Go to the documentation of this file.
1
20
21#ifndef TRNG_H_
22#define TRNG_H_
23
24 #ifndef TRNG_BUFFER_SIZE
37 #define TRNG_BUFFER_SIZE 10UL
38 #endif
39
53
59
60 void trng_init(void);
61 void trng_next_bit(unsigned char bit);
63 volatile unsigned char* trng_buffer(void);
64 void trng_reset(void);
65
66#endif /* TRNG_H_ */
void trng_next_bit(unsigned char bit)
Processes a single entropy bit and adds it to the TRNG buffer.
Definition trng.c:62
TRNG_Buffer trng_buffer_status(void)
Returns the current fill status of the TRNG buffer.
Definition trng.c:124
TRNG_Buffer_t
Represents the current fill status of the TRNG data buffer.
Definition trng.h:48
@ TRNG_Buffer_Empty
Definition trng.h:49
@ TRNG_Buffer_Full
Definition trng.h:51
@ TRNG_Buffer_Filling
Definition trng.h:50
void trng_reset(void)
Returns a pointer to the internal TRNG buffer.
Definition trng.c:173
enum TRNG_Buffer_t TRNG_Buffer
Alias for enum TRNG_Buffer_t representing the TRNG buffer status type.
Definition trng.h:58
volatile unsigned char * trng_buffer(void)
Returns a pointer to the internal TRNG buffer.
Definition trng.c:154
void trng_init(void)
Initializes the True Random Number Generator (TRNG) module.
Definition trng.c:38