Quantal master equation valid for any time scale