avr/rng/rng.h

19 lines
225 B
C

#include <stdint.h>
#ifndef __RNG_H__
#define __RNG_H__
typedef struct RNG {
uint8_t mod;
int8_t a;
int8_t c;
uint8_t seed;
} rng_t;
rng_t rng_new(uint8_t seed);
uint8_t rng_sample(rng_t *state);
#endif