move parameters to global variables