2

I want to connect arduino and android via cc3000, it works perfectly in both side. well, in arduino we access http://ip/location1 and http://ip/location2.

and in android i am using

Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse("http://ip/location1"));
startActivity(intent); 

and you know why i am not using

HttpClient httpClient = new DefaultHttpClient();
HttpContext localContext =  new BasicHttpContext();
HttpGet httpGet = new HttpGet("http://ip/location1");
HttpResponse response = httpClient.execute(httpGet, localContext);

it's not working, it's not even connecting

so, how to make it access the url, without opening browser? with Intent.ACTION_VIEW

Albert hdx
  • 21
  • 2

1 Answers1

0

You can load your url in a WebView. A Webview is an Android widget that allows you to display an webpage on your app. Check this answer for the implementation:

how to display progress while loading a url to webview in android?

Community
  • 1
  • 1