How long did you let it sit like that? After around ten minutes, the pressure in the system is released and the top and lid will relax - likely such that the top module loses track of where things are, hence, "loss of sync".
In such cases, you must start the car and have it running, while you put the top up and down manually two or three times. THEN, try the button, it should work fine.
Procedure is here: