As part 2 of my earlier project to log temperature in my quail egg incubator, I still wanted to be able to get photos from inside the incubator, so I could keep an eye on the hatching progress remotely.
In case you missed it, I tried incubating quail eggs, but the incubator temperature was off and the eggs didn't hatch, which led to paranoia and these monitoring projects.
I have an old Moto G lying around that I wanted to use for the job.
Assuming that I could find the right app, the other equipment I would need would be a charger for the phone and a lamp to illuminate the eggs for taking photos.
I found a few apps on the Play Store that might work.
I downloaded the demo version of Cloud Cam and did a proof of concept.
I configured the app to take a single image, every 30 seconds and upload it to Dropbox for me.
If you are following along and would like to do the same, this is how the settings work.
1 - Go to snapshot settings
2 - Once set up, click the checkbox to make it do the snapshots when the server is on
In the snapshot config, I just picked the highest settings for Capture Size and Image Quality.
I then selected 1 image under "Number of images to capture".
I then selected 30 000 milliseconds as the sleep interval, which makes it take a picture every 30 seconds for the proof of concept.
I then told it to send the images to Dropbox.
Here you just need to authenticate it, tell it if you want to put the photos in a different folder.
I told it to put it in the "eggs" folder.
Lastly, tap Activate Dropbox.
For me, this puts it in the folder:
The last thing to do is click the Start Server button.
I looked in the Dropbox folder and the images were being uploaded as expected.
Getting the images public
I could have left it at that and just looked in my Dropbox folder for the images every so often, but it would be far more convenient if I could get them Tweeted out from the same Twitter account as the temperature and humidity readings were going to from my last project.
This was another job for IFTTT.
I hooked up dropbox to my IFTTT account and as a proof of concept had it simply notify me when it found new dropbox images.
I wanted to wait until the phone was in the incubator before actually Tweeting the photos
Putting it all together
Once I was certain that it all worked, I bought the full version of the Cloud Cam app and configured it to upload a single image to Dropbox every 30 minutes.
So all the settings in the app were the same, except I changed the sleep interval to 1 800 000, which is 30 minutes.
I then created a different IFTTT applet that pushed the photos to Twitter.
I taped the phone in place inside the incubator and made sure it was framed properly.
I had a micro-USB cable running into the incubator to power the phone.
With that, there was nothing left to do but sit back and wait for the images to start coming in from the Twitter account.
Update: The images stopped coming through the next day. I checked and the phone was off, charging and at 40%. So I think the USB hub I was using didn't provide enough current to keep the phone charged. I have switched to a better charger to see if that helps.
The incubator could have relatively high humidity, which doesn't usually mix well with electronics, so if you were doing this with a waterproof phone, it would probably be a better idea in the long run.