FastLED 3.9.15
Loading...
Searching...
No Matches

◆ random8() [2/3]

LIB8STATIC uint8_t random8 ( uint8_t lim)

Generate an 8-bit random number between 0 and lim.

Parameters
limthe upper bound for the result, exclusive

Definition at line 61 of file random8.h.

61 {
62 uint8_t r = random8();
63 r = (r * lim) >> 8;
64 return r;
65}
LIB8STATIC uint8_t random8()
Generate an 8-bit random number.
Definition random8.h:44

References LIB8STATIC, and random8().

+ Here is the call graph for this function: