As you've said, when the Y homes, both the Y AND the A move BUT only the Y is "homed". To "square" the axis the A then homes and should have a switch of it's own. Alternatively, if you don't want that feature, just take out the line that homes A (doButton(25)) from the RefAllButton.