add a parameter to set refresh delay.
resolves #19.