EasyManua.ls Logo

Crestron SIMPL+ - SIMPL+ String Parsing & Manipulation; String Parsing and Manipulation Overview; ClearBuffer Function

Crestron SIMPL+
374 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
Crestron SIMPL+
®
Software
Language Reference Guide - DOC. 5797G SIMPL+
®
z 213
Seed
Name:
Seed
Syntax:
Seed(INTEGER SeedValue);
Description:
Provides a seed or origin for the random number generator so that the numbers
returned by RND and RANDOM are pseudo-random numbers. SEED is not required
for generating random numbers as the random number generator will be seed with a
default value.
This default value is issued at control system restart, not program restart. That is, if
you don't used the SEED call, you will not get the same value if you restart the
program. For any particular value of SEED, the random number generator will
generate a predictable series of numbers. Note that specifying the seed value is global
to all SIMPL+ programs running inside a control system. The sequence begins again
whenever SEED is called.
Parameters:
None.
Return Value:
None.
Example:
INTEGER NUM;
FUNCTION MAIN()
{
SEED(25);
NUM = RANDOM(25, 80);
PRINT(“The random number between 25 and 80 is: %d\n”, NUM);
}
Version:
SIMPL+ Version 1.00

Table of Contents