User guide
E-39
PLI Access Routines
vcs_dist_poisson
You use this routine to return a random number with a specified mean.
Access Routines for Returning a String Pointer to a
Parameter Value
The 1364 Verilog standard states that for access routine
acc_fetch_paramval you can cast the return value to a character
pointer using the C language cast operators(char*)(int). For
example:
str_ptr=(char*)(int)acc_fetch_paramval(...);
In 64-bit simulation you should use long instead of int:
str_ptr=(char*)(long)acc_fetch_paramval(...);
vcs_dist_poisson
Synopsis: Returns random numbers with a specified mean.
Syntax: vcs_dist_poisson(seed, mean)
Type Description
Returns: int Random number
Type Name Description
Arguments: int * seed Pointer to a seed integer value.
int mean An integer that is the average value of the
possible returned random numbers.
Related
routines:
vcs_random vcs_random_const_seed vcs_random_seed vcs_dist_uniform
vcs_dist_normal vcs_dist_exponential