I may be wrong, but all you are looking for is an autonomous system:
So, divide through by and do a bit of algebra, and you get
where is in hours,
Then pick step size to step in units of 5 seconds.
Edit: I messed up the units here -- so my equations are definitely wrong. Sorry