Showing posts with label software. Show all posts
Showing posts with label software. Show all posts

Photography - Photo stacking


I've been reading a bit about photography, and discovered this thing called "photo stacking".

It helps you create super close ups that have everything in focus.


Normally in a photo, you get some bits in focus, and some out of focus.

This can be a good thing, because you don't always want, for example, the background to be sharp.

Sometimes things look better when you cant see them.

But sometimes you want to see it all.


I'll drop a series of seven photos here with each one seeing a different section in focus.

This first pic of a 300mm ruler is taken at a focal length of 10mm.


This next pic is at 20mm

You can see that the section that's in focus has moved a little further back.














This one at 50mm

















 Here are three more in the series with each one seeing the focal length change through 100mm, 150mm, 200mm, and 300mm.

I would have preferred to use increments of 5mm all the way through, and take 60 photos, but this camera I have only deals with those photo lengths when used in manual focus mode. 

There is software that is free and open source, that can take the best bits of each photo, and knit them all together to make one photo. 

Apparently it's possible to do this in a graphics program, but I dont have the skill set, and the software seems to work. 

There are a few different software packages, some that cost and some that are free. The one I'm playing with is called, CombineZP. All you have to do is select the photos (New), then chose something that I dont understand called, "align and balance used fra..." (the title of this function is cut off because whoever made it doesn't respect my inalienable right to resize whatever window I want, and my screen size isn't the same as theirs), then click something that makes perfect sence that says GO.

After a few seconds wait, the end result is pretty good for a first attempt, and might just prove to be a very useful tool in trying to capture extreme close up shots. 

I'm guessing it would be perfect if I just had a camera that could deal with letting me chose where to focus all on my own. 

Even without respecting my free will, the result is quite good. You can see in the photo below, some bands of blur where I couldn't divide the focal length and add another frame. There's an obvious blur between the "k" and "i", and another at the "3" in 300. Another at 250, but they are all errors caused by my camera not letting me take pictures in between the ones I took. 

'Tis an interesting bit of kit, and I thoroughly recommend trying it if you are taking macro shots. 
 
The result...






































120 Things in 20 years - I love discovering new things like photo stacking for macro shots, and I love discovering that there are only 6 photos in my series of 7. I deleted one, and have no idea which one it was, so I moved on. 

I'm also without confidence that I'm using the words "focal length" properly. 

Electronics - Aquaponics - Demand fish feeder software


As far as I know, the software is all working on my demand fish feeder.

It's a bit of a mess, with a few goto statements and a few unused variables. I'll fix it in time, but for now I'm going to move onto getting a finished product up and running. As far as I can tell with the software simulator everything works, but the real world might be a completely different story. (the breadboard version also works)








A switch lever extends down into the water. If a light near the lever is lit, the fish can press the lever and feed is delivered. Feed can also be offered with an override button that sets the light on and the feed on if the fish hit the lever (so you can show people how it works)

Dawn detection seems to work. In the end I went with two startup options.

1. A human who holds down the FeedNow override button during startup, then taps out the approximate number of hours since dawn. This skips the code that searches for a new dawn.

2. An abnormal restart with no human. This stops all feeding (there might have been a blackout, and subsequent ammonia buildup) (note to self - add code that flashes some lights to indicate the device is in abnormal start mode so a human can reboot it if they desire). Feeding resumes after night time is detected, and a dawn is detected.

The user can select (via a screwdriver to resist little finger making their own adjustments) ...

 - the feed amount per day in tenths of a second of motor on - from 0 to 65 (I'm guessing I'll use 1/2 a second per feed event) The motor turns an auger under a hopper full of feed. So there is another adjustment available

- The number of feeds in a day that are offered (0 - 255 per day)

- The level of light at which dawn is detected. This allows for a system built in the glow of a streetlight or whatever. At dawn each day, all the numbers reset. This is a bit of a problem as far as reading how many feeds were delivered in a day, but for now I'll leave it as it is. My fish feed like crazy at dawn, so I want to give them the greatest opportunity to feed. Eventually I'll add a data logger, so it wont matter when it resets.


The system reports...

- the number of hours since dawn

- the number of feeds since dawn

- The number of false hits to the feed lever when the FeedIsAvailableLED is NOT lit (these will go down to near zero once the fish learn they can only get food when the light is on)


I ran out of feed a while back, and have been feeding my two big silvers on duckweed, lettuce, and worms, so I will need some pellet food before I can test it in the real world. (I still have the PVC device from the first version).

I'll also need a motor as my original one is no longer with us.

The feeding regimen isn't very intelligent at the moment, but I'll do a bit of research, and add some code that tries to deliver the maximum amount of feed in a day that the system can handle. This will probably involve allowing 3/4 of the feed to be dumped at will, with the rest being spaced out over the day ... or something. I haven't given it enough thought because I don't really know what the fish need. My experience in fishing for wild fish indicates that the feeding pattern is far from a constant grazing all day long. I'll work it out.

But...

It's going to work. In fact, it already does.


120 Things in 20 years That's all. Just 120 Things in 20 years.


Popular Posts