Hi, I need to take photos programatically without user interaction and save them, I lack knowledge so can you instruct me on how can I do this? AIA project explaining it would be appreciated. Also these photos need to have best quality possible. Thanks in advance.
For some reason it wont save the picture, it opens camera view but never proceeds from there, as my microcontroller waits for info back that photo is taken and saved.
Here is how my setup of this extension looks. What could be a problem here?
On the BT connection I am pretty sure everything is fine (tested with bt serial monitor app and previous version of this), I am most definitely missing something about the extension.
used ProCamBase64 take picture to base64 string, data too large, designed the VerticalArrangement size: 120x160, not improved, seems that window not relative to image pixel? anyway to set the resolution of the image before take image?
purpose is to reduce the string size.
Note, this version is built with FAST instead of RUSH, so it will not update the previous extension, you will need to delete the previous extension, and then install the latest version (2).
The containing arrangement was set to 320x180
The number of characters returned for an image taken with maxImgLength set to 0 (no resize) = 430,000
Setting the maxImgLength to 160 returned an image with 19,900 characters
the block shown that when call ProCamBase64.TakeCameraImageToBase64 by BLE, phone works take picture and convert to base64 and sending but broken on half way;
if call ProCamBase64.TakeCameraImageToBase64 set maxImgLength = 120, got APP crashed,
the maxImgLength reduce OK by button for testing; in my code's Button3 got runtime error: Not coonected to a Bluetooth...; don't know why?
can be the ProCamBase64.AfterToBase64 got difference result for:
ProCamBase64.TakeCameraImageToBase64
and:
ProCamBase64.TakeCameraImageToBase64 set maxImgLength = 120 ?
BTW. I'm using Android 14, the permission request got difference from Android 5? thanks.
Your issue is not with procam, it is what you are doing after you capture an image. Do some work on that . Break your approach down into steps, test each step, until you find where the problem is. This is much easier than trying to resolve an issue by running the whole thing at once.
I've done all steps till got: APP be trigged to take screenshot and resized and encoded and sent to ESP32 works well.
this step now is let APP to take picture by camera and then to do the same thing, tested only: ProCamBase64.TakeCameraImageToBase64 doesn't crash the APP, but crashed on the halfway sending, thats why I think the reason is the string too big (actually it is too big), its why I am looking a solution to reduce the string, the ProCamBase64.TakeCameraImageToBase64 maxImgLength setting is a good solution tested by manually, but got APP crashed as long as it take picture.
its the all story.
I guess the core of:
ProCamBase64.TakeCameraImageToBase64 and
ProCamBase64.TakeCameraImageToBase64 maxImgLength set
may be some difference?
All I did was add the resize function for the Preview Picture. No other changes made. If maxImglength is set to 0 then the behaviour is as the previous version.
are you trying to do too many things at once here ?