make osimctrl into a class rather than a bunch of functions