Save to eprom at power off diagram.

If you need to detect the removal of power you are better off sensing the power from the input side of the DC / DC converter. This gives you more of a warning and you need smaller reservoir capacitors because you use the ones in the DC / DC converter.