Analog input zero crossing detector

How can I use the analog input as a zero crossing detector?
With a voltage divider I can get a 5 volt AC signal from the secondary of my Arduino's power supply.
If I clean it up with some capacitors across it, I think I should be able to get a trigger when it goes to/thru Zero.
How??
I know I could buy a zero crossing detector,
I am curios how I could do it with analog input.
Please tell me if or how? ( in detail, I am quite ignorant)
Thanks

It would make more sense to use the Arduino's analog comparator as a zero crossing detector. Google for "arduino analog comparator library".

Thanks for the reply. It would be great if you could expand on your knowledge.I did think of googling the idea :). Just a basic outline, if not for me then for other googlers.
Only take a minute.
I think I recognise ur I'D/avatar from an audio forum?
Maybe my imagination.
Thanks anyway