X-Git-Url: https://oss.titaniummirror.com/gitweb/?a=blobdiff_plain;ds=sidebyside;f=lfsr.h;fp=lfsr.h;h=64af84e7654c771cea9141e0cf54cd20bda55d71;hb=87f1670834e09523f4fba2499aeadee253853709;hp=0000000000000000000000000000000000000000;hpb=c6c87d218f92253412bf8342ed4379d634679953;p=rgblamp.git diff --git a/lfsr.h b/lfsr.h new file mode 100644 index 0000000..64af84e --- /dev/null +++ b/lfsr.h @@ -0,0 +1,17 @@ +/* + * File: lfsr.h + * + * Linear Feedback Shift Register (random number generator) + */ + + +#ifndef _LFSR_H +#define _LFSR_H + +/* Initialize the LFSR generator */ +void lfsr_init(unsigned seed); + +/* Read the next LFSR value */ +unsigned lfsr_get(); + +#endif