add counter threshold