Overloaded setupConnection.