Interface: tos.interfaces.Random
interface Random
This is the interface to a simple pseudorandom number generator. Currently
this interface is implemented by the RandomLFSR, which uses a linear
feedback shift register to generate the sequence and mote address to
initialize the register.
- Author:
-
Jason Hill
-
David Gay
-
Philip Levis
-
Alec Woo
- Modified:
-
6/25/02
Commands
command result_t init()
command uint16_t rand()
Commands - Details
init
command result_t init()
- Returns:
-
Returns SUCCESS if the initialization is successful, or FAIL if
the initialization failed. For the currently existing implementations
there is no known faliure modes.
rand
command uint16_t rand()
- Returns:
-
Returns a 16-bit pseudorandom number.