I am using the c6000_7.3.4 compiler from the TI toolset. I was wondering where rand () and srnad() are documented. I want to make sure I am using the correct call for a 32 bit number.
This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
I am using the c6000_7.3.4 compiler from the TI toolset. I was wondering where rand () and srnad() are documented. I want to make sure I am using the correct call for a 32 bit number.
Standard RTS functions such as rand and srand are not covered in TI documentation. Many books, web articles, etc cover that information.
In the spirit of being helpful ... These functions return and accept "int" type variables. And int is a 32-bit type on C6000 devices. So I think you will be fine.
Thanks and regards,
-George
While TI's rand() implementation uses 32 bits of state, the return value of rand() is only a 16-bit value, as indicated by the value of RAND_MAX.