electronic scheme for a charger of nicd or nimh batteries with auto cut off

Hello,

I did a standalone device (xbee, pir, battery). My issue is the duration of the batteries.
That the reason why i am trying to create a solar power system with a 12v solar panel, dc regulator, batteries.
how to stop charging when the batteries are completly loaded in order to avoid overload ?
I saw that zener diode could do that (stop charging).

Has someone an electronic scheme available to,do so?

Thanks
Regards