2

I am using Text Recognition API of Google.

Even with proper import of its dependencies and internet connection. It shows that error.

The Results of my debugging:

  1. It works on Android 4.4 Kitkat API 19 + but not lower than it
  2. If I try to run it in Android 4.1 to 4.3 / API 16 to 18, it shows me this Logcat error

    enter image description here

  3. However when I run it on Android 4.4+ it crashes like when running on Android 4.3 and below, but when I connect it to the internet, it downloads the required dependency and thereby runs properly. The same is opposite when trying to run the same app on Android 4.3 and below, it seems to be not downloading the required dependency and thereby crashes. Pls. help. thx

칼인오
  • 143
  • 1
  • 2
  • 11

1 Answers1

0

Before this blows up it tells you that your Google Play Services are out of date on the device. Have you tried updating Google Play Services and then running this?

dazza5000
  • 7,075
  • 9
  • 44
  • 89
  • I already updated it among all of my other android images with the SDK tool. All my Android Images uses Google APIs and Google Play versions anyway.So I can't see why it still is telling me about the outdated Google Play Services thing. However, for Android 4.1-4.3 at least, afaik Google Play version started only on Android 7.0 and above. The rest are called Google APIs which I use for the Android 4.4 where this worked. But not on the 4.3 and below :/ – 칼인오 Jan 03 '18 at 20:39
  • With Google Play Versions of Android Images, there is an update button on the extended control of the emulator. THe same is not true for those below Android 7.0 which had to be downloaded from the SDK tool afaik which I did. I updated not only the Android 4.4 but also Android 4.1 to 4.3 Google APIs today, to no luck, even with the up to date Android Images, it stil gives the save error. :/ . The API only worked on Android 4.4 though. – 칼인오 Jan 03 '18 at 20:43
  • Does the API you are trying to use support earlier versions? – dazza5000 Jan 03 '18 at 21:28
  • I think so yea. Because in the tutorial, it required Android 4.1 at least in here. https://codelabs.developers.google.com/codelabs/mobile-vision-ocr/#0 – 칼인오 Jan 04 '18 at 04:28