What I have to do to connect my android smartphone (Galaxy Ace S5830) to home wifi wpa2?
There are some incompatibilities between Android devices and wireless routers. I've seen the same behavior on a couple of WLANs and some even go to "Acquiring IP Address..." and then disconnect. I suspect that your phone works well in other WPA2 secured WLANs?

I haven't so far seen a comprehensive list of non-functioning routers, but at least one Netgear and a locally-branded Cisco Cable modem with integrated Wifi have failed for me.