Implemented sys_get_random_number
Added more initializations and terminations
Merge pull request #803 from tambry/InitilizationsAndTerminations

Added more initializations and terminations
Fixed assigning of the generated number
Merge pull request #802 from tambry/sys_get_random_number

Implemented sys_get_random_number
Merge pull request #805 from Nekotekina/master

CallbackManager rewritten