I tried to create an application showing some photos from the Internet.
I used a function that works fine on my phone (Galaxy S3 - Android 4.3), but on the watch I get a java.io.EOFException exception.
Code (works by phone):
private class DownloadImageTask extends AsyncTask<String, Void, Bitmap> { ImageView bmImage; public DownloadImageTask(ImageView bmImage) { this.bmImage = bmImage; } protected Bitmap doInBackground(String... urls) { String urldisplay = urls[0]; Bitmap mIcon11 = null; try { InputStream in = new java.net.URL(urldisplay).openStream(); mIcon11 = BitmapFactory.decodeStream(in); } catch (Exception e) {
Other functions throw a org.apache.http.NoHttpResponseException watch is paired online as well, since I can use voice commands and search the Internet, etc.
So the question is: can I access the website directly from Android Wear or do all these tasks on my phone? Or is there something wrong with my setup?
source share