Changes to save code space; cor xy; other misc changes