automatically select port