Menu

Show posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Show posts Menu

Topics - csg2

#1
Hi Folks,

I am working on a LUA script. Have been stumbling along OK, but recently hit a wall. I want to be able to pause in the scrip0t for certain lengths of time. So I have been trying to use the sleep global function.

When i do this I get a console message "variable 'sleep' is not declared. If ti matters, this is on a Canon 550d.

My script is supposed to start with an auto-focus, and take 99 more pictures, then auto focus and so on until complete. I have a delay to start so any motion caused by pressing the button to start the script can die down. There is also supposed to be a delay between shots so as not to fill up the buffer.

Code follows:

require("logger")

-- global logger
test_log = nil
LAF = nil
Number_of_Shots=nil
AF_every_Shot=nil

function main()
    test_log = logger("ML/LOGS/LUATEST.LOG")
    Number_of_Shots=100
    AF_every_Shot=10
    menu.close()
    console.show()
    print "Lunatic!"
    sleep(2)
    for i=Number_of_Shots,1,-1
    do
if ((Number_of_Shots % AF_every_Shot) == 0) then
            lunatic_AF()
        else
            camera.shoot(false)
end
        sleep(1.6)
    end
    print "Press any key to exit."
    key.wait()
    console.hide()
end

function lunatic_AF()
    if lens.name == "" then
       printf("No Lens Detected.\n")
       return false
    end

    if not lens.af then
        printf("Please enable autofocus.\n")
        return false
    end

    if not lv.running then
       lv.start()
       assert(lv.running)
    end

    if lens.af then
LAF=camera.shoot(true)
        lv.stop()
        return LAF
    end

    lv.stop()
    return false

end -- lunatic_AF

function printf(s,...)
    test_log:writef(s,...)

    if not console.visible then
        display.notify_box(s:format(...), 5000)
    end
end

keymenu = menu.new
{
    name   = "Lunatic - Moon Stack Automation",
    help   = "Automates Lunar Stack Capture",
    select = function(this) task.create(main) end,
}
#2
Hi folks,

So what does the camera do when you press the shutter or trigger an exposure with an intervalometer?

I have been trying to stack images of the moon and been plagued by blurry shots. Out of curiosity, I got an accelerometer to measure the vibrations the camera was making. With a mirror lens, and therefore no shutter, there appear to be 4 motions. I guess this is
1. Mirror up
2. Light curtain?

Exposure

3. Light curtain?
4. Mirror down

Is this right?

What about the electronic part of the process?

If there is an post somewhere about this I would be glad of a pointer.

For ref I have a 550D.