Hello
First to start that I believe the tool you have created is great.
Am playing around with an application and started adding pictures to a log input.
The intersting thing is on Motorloa running Android 9, the first time I take a pciture and return to the programm, the afterpicture event is not triggered. Then when I enter the camera again the second time I take a picture then it does catch the picture.
This happens every time when I open the application.
To avoid any doubt on any interaction with other objects I created a sample application, with just camera, a button to call camera and an image box to capture the picture.
Again same behaviour, first picture is not received by the app, the second one and any other pictures taken are received. As a side note, looking in my Pictures folder, the first picture is taken and stored on the phone (on both applications), as such the error is not there?
Slowly going crazy, I then installed same App on my BQ Aquarius U2, running Android 7.1.2.
With this one there was no issue, first picture is received properly by the afterpicture event?
Not sure where to look further? Any idea what culd be causing this issue?
Does anybody run into ths same isseu on Android ?
Hi Ken
great and thanks for your quick feedback! As such it is not Android 9 and App Inventor issue, but something to do with the Motorola Camera app being used I assume?
Is there any log file that I can see what is happeing behind the scene what could be going on with this? it is very strange, as it is only at start up of the app and the first time it goes to the camera app that it doesnt come back and doesnt trigger the after picture, then at the second and any following call to camera it works fine…
After your post installed a seperate app, called Open camera. And using that one to take pictures, it worked perfectly. As such the standard camera app from Motorola seems to be the issue. So 100% it is the Motorla package
many thanks… will set it up and see if the log file triggers anything… Yes, very strange on second camera trigger it works… It started bugging me. Also on my main app am using sliders, and at the first camera trigger they reset to OFF, while there is nothing in my code to trigger this.
only error message i find in the log when it fails to get the picture,
the log message I find with first picture is: 05-18 00:45:46.577 1930 2030 E InputDispatcher: channel ‘11eb541 appinventor.ai_sergenugteren.test_camera/appinventor.ai_sergenugteren.test_camera.Screen1 (server)’ ~ Channel is unrecoverably broken and will be disposed!
when running the log the second time I take a picture I get not a single error message in the log for the app inventor app
Did you get any error message (from your device) after taking the first picture?
Post the aia and try Taifun's Camera extension: App Inventor Extensions: Camera | Pura Vida Apps
Did you get the same issue with it?
Hello adding the simplistic application used, just to show nothing fancy and it still fails the first picture. As mentioned previous it does capture the first picture and stores it in the /Pictures folder, just dont get the AfterPicture event.
Have tried another camera (Open Camera) and that works, as well downloaded the test app from Taifun, with that app there is never an issue with the first picture.
On the log files looking at all the motorola camera log entries, seeing numerour of messages, but same log messages received when taking first and second picture.
… and if you take Ken’s aia, did you get this on the first run (picture):
If not, you are correct, that the .AfterPicture event is not driggered (for the first time).
(That would be really strange, since this error would have to occur often and have been discussed in the relevant forums a long time ago.)
Hi Anke
exactly, I do not get the label with the JPG created.
I build the app in apk package
Have installed your updated app with the permissions, at first run it sets the label to the permission, then press button to go to Motorola camera app to take picture, and when returns after picture. Picture is not loaded. Interestingly the label for permission is reset as well
Then retrying running the app, but now using the Open Camera application as the camera, again no problem and it loads the picture at first try.
Hello
no sorry am not explaining myself properly. I mean when I run the app with the other camera package, which is not the motorola camera app, but an app called: Open Camera then there is no issue
Further added the label to capture the get picture name/location but no response from first image, only at second picture. Also tried the same with reopening the screen and closing, as per your suggestion. Again same result, first picture does not get the trigger event.