Creates a new periodic function wrapper.
The interval at which to call the function.
The function to call.