use phase counter