Changed over all device demos to use a clearer algorithm for the configuring of the application's endpoints.