@AMJ: you expect an answer to this incomplete question?
The supply:
- For which microcontroller? Each family of microcontrollers has their own assembly language.
- How is the rtc connected to the microcontroller? At least which pins are used, better a schematic.
- Have you searched the relevant internet sources?