The PhotoPills app
https://www.photopills.com/ may be one of the most useful apps ever invented, and it runs on just about any smartphone. It was developed more for people who shell out big bucks for high-end photographic equipment and carry smartphones in their pockets for the convenience of having PhotoPills on hand to resolve many of their immediate high-end equipment issues. But what if your smartphone with PhotoPills app installed is also your high-end photographic equipment? Then your PhotoPills app may not be very useful.
Check out the PhotoPills online calculators here:
https://www.photopills.com/calculators to see some possibilities for learning more about your camera and its lenses. Many of these online calculators are also in the PhotoPills app. These online and app calculators are not useful for smartphone cameras and lenses, nor are they useful when an external lens is attached over the smartphone lens. I have an iPhone XR with attachable Moment Macro, Wide, and Telephoto lenses, and the PhotoPills calculators cannot give me the information I need to use any of these systems as they do for hundreds of professional camera/lens combinations. What to do?
First of all I was disappointed that I could not find my iPhone XR camera and lens listed in the table of supported camera/lens combinations. Was that because my iPhone XR camera and lens combination was not considered a bonafide piece of photographic equipment? I contacted the PhotoPills developer by E-mail to find out why my system was not included in the app, and he showed me how to enter information about my system into the app so it would be available. And he showed me how to enter information about the iPhone XR camera/Moment Wide lens and iPhone XR camera/Moment Telephoto lens combinations into the app, so the app could then compute information for those systems, similar to what it does for the expensive big-boy systems. The app cannot handle macro lenses, so I could not enter information for my XR camera/Moment Macro lens combination.
People who use their smartphone cameras mainly to point-n-click probably will never need PhotoPills, but if you want to get great close-up images, especially sharp close-up images, sharp focus-bracketed images, then you may need to know a lot more about your smartphone camera system, and PhotoPills can be an excellent aid if you know how to set it up and use it. If there is any interest in using focus bracketing on smartphones I will show how I obtained the information about my iPhone XR camera with and without attached Moment lens combinations, information needed to educate the PhotoPills app about these systems, so that it can do some computing to help in the focus bracketing process. A small amount of math using your smartphone calculator may be required to get the necessary information, but I will show the steps.
Unfortunately the PhotoPills app can't handle macro lens combinations, so a different mathematical approach must be taken to obtain the information that the PhotoPills app would normally produce for non-macro systems. Handling Macro lenses would be in a different set of tutorials.
The most important piece of information a user needs when setting up to focus-bracket a subject is Depth of Field (DoF) as a function of focus distance. Imagine standing at the focal point and looking toward the camera. Let X represent the distance from this point to an imaginary plane representing transition from in-focus to out-of-focus. Then face away from the camera and let Y represent again the distance from the same point to a second imaginary plane representing transition from in-focus to out-of-focus. Then X+Y is the DoF at the focus point. Focus stacking requires focusing the lens at various points in the subject such that the in-focus slices overlap each other by about 20% or more to insure quality stacking and merging of images into a sharp final result. The PhotoPills app can compute DoF at any focus distance, except for macro lenses, so this information can be used to estimate how many photos to take in focus bracketing to get a final sharp image.
Don't despair if all this sounds too complicated, because it isn't necessary to know DoF to do focus bracketing. Just guess at a number of slices to use, such as 30 and look at the final focus stacked and merged subject. If it looks good and sharp you likely have used enough slices, but maybe too many. There seems to be no penalty for using too many slices except additional processing time. If parts of the subject don't look sharp enough, then you may need to increase the number of slices or reduce the amount of subject you want in sharp focus.