Fix cd and cast time set functions