Cleaned some functions and re-organized thruster debug code