Sicherlich ist die einfachste und schnellste Lösung, eine Belichtungsreihe zu erstellen, schon im CHDK eingebaut. Es gibt aber immer wieder Anwendungen, bei den besondere Einstellungen erwünscht sind. Dieses Skript faßt diese Möglichkeiten zusammen.
Für das Skript ist eine aktuelle CHDK-Version notwendig. Es sollte auf allen Kameras laufen.
Belichtungsreihe als Ev-Reihe oder Tv-Reihe alternierend
Mehrfache Erstellung von Bildern in einer Einstellung - wichtig bei Langzeitbelichtung.
Fixierung Fokus
Log-Datei schreiben
Skript-Parameter
Schrittweite in 1/3 Ev oder 1 Tv: voreingestellt 3
Anzahl verschiedene Werte: voreingestellt 5
Startverzögerung in s: voreingestellt 1s
Anzahl Bilder pro Wert: voreingestellt 1
Fix Fokus 0=aus 1=an: voreingestellt an
Modus 0=Ev 1=Tv: voreingestellt Ev
Log -1=aus ab 0 Dateiname: voreingestellt 0
Die Log-Datei befindet sich im CHDK-Unterverzeichnis LOG und hat den Namen LOG_0100.txt bei Voreinstellung 0. Ändert man den Voreinstellwert 0 auf z.B. 5, heißt die Datei LOG_0105.txt. Sie enthält alle Informationen, die in Skriptkonsole angezeigt wurden. Somit ist eine spätere Zuordnung der Bilder einfacher möglich.
Syntax: [ Download ] [ Verstecken ]
Benutze Lua Syntax Highlighting
--[[
@title Belichtungsreihe universal
@param a Schrittweite [x*1/3Ev][Tv]
@default a 3
@param b Anzahl verschiedene Werte
@default b 5
@param c Startverzögerung in [s]
@default c 1
@param d Anzahl Bilder pro Wert
@default d 1
@param e fix Fokus [0=aus][1=an]
@default e 1
@param f Modus [0=Ev] [1=Tv]
@default f 0
@param g Log [-1=aus][x=Datei-Nr.]
@default g 0
]]
function shooting()
press "shoot_half"
repeat
until get_shooting() == true
if e == 1 then set_aflock(1) end
if f == 1 then
if get_propset() == 2 then
set_prop(262,TV)
else
set_prop(69,TV)
end
else
set_ev(EV)
end
press "shoot_full"
release "shoot_full"
release "shoot_half"
repeat
until get_shooting() ~= true
end
function multi_shooting(count)
if count>1 then print("Aufnahme 1 von",count) end
shooting()
if count>1 then
for n=2,count do
print("Aufnahme",n,"von",count)
shooting()
end
end
end
function print_Tv()
tv_output = {"64s","50s","40s","32s","25s","20s","15s","13s","10s","8s","6s",
"5s","4s","3.2s","2.5s","2s","1.6s","1.3s","1s","0.8s","0.6s","0.5s","0.4s",
"0.3s","1/4s","1/5s","1/6s","1/8s","1/10s","1/13s","1/15s","1/20s","1/25s",
"1/30s","1/40s","1/50s","1/60s","1/80s","1/100s","1/125s","1/160s","1/200s",
"1/250s","1/320s","1/400s","1/500s","1/640s","1/800s","1/1000s","1/1250s",
"1/1600s","1/2000s","1/2500s","1/3200s","1/4000s","1/5000s","1/6400s",
"1/8000s","1/10000s"}
print_tv = "Tv="..tv_output[tv+19]
end
function EV_hdr()
x=0
for s=1,b do
if x>0 then x=-1 else x=1 end
EV = Ev_is + (s/2*x) * a * 32
z=EV/32/3
if z<0 then zz=z*-1 else zz=z end
if x == -1 then
zzz = "-"..zz..","
else
zzz = zz..","
end
cls()
print("Bild",s,"von",b,"mit",zzz..(EV*10/32/3-z*10)*x,"Ev")
multi_shooting(d)
end
end
function TV_hdr()
x=0
for s=1,b do
if x>0 then x=-1 else x=1 end
TV = Tv_is + (s/2*x) * a * 32
tv = TV / 32
cls()
print_Tv()
print("Bild",s,"von",b,print_tv)
multi_shooting(d)
end
end
--start script
if a<1 then a=1 end
if b<3 then b=3 end
if c<0 then c=0 end
if d<1 then d=1 end
if e<0 or e>1 then e=0 end
if f<0 or f>1 then f=0 end
time01 = get_tick_count()
press("shoot_half")
repeat
until get_shooting() == true
release("shoot_half")
Ev_is = get_ev()
Tv_is = get_tv96()
tv = Tv_is / 32
flash = get_flash_mode()
EV = 0
TV = 0
if flash ~= 2 then
print("Blitz abschalten!")
sleep(3000)
exit_alt()
sleep(2000)
end
if c>0 then
print("Warte",c,"Sekunde(n)")
sleep(c*1000)
end
if g>-1 then print_screen(100+g) end
if f==0 then
EV_hdr()
else
TV_hdr()
end
set_ev(Ev_is)
set_tv96(Tv_is)
cls()
time02 = get_tick_count()
time03 = (time02 - time01)/1000
print(b*d,"Aufnahmen in",time03,"Sek.")
print(os.date("am %d.%m.%y um %X"))
print("erstellt.")
if g>-1 then print_screen(-10000) end
if e == 1 then set_aflock(0) end
@title Belichtungsreihe universal
@param a Schrittweite [x*1/3Ev][Tv]
@default a 3
@param b Anzahl verschiedene Werte
@default b 5
@param c Startverzögerung in [s]
@default c 1
@param d Anzahl Bilder pro Wert
@default d 1
@param e fix Fokus [0=aus][1=an]
@default e 1
@param f Modus [0=Ev] [1=Tv]
@default f 0
@param g Log [-1=aus][x=Datei-Nr.]
@default g 0
]]
function shooting()
press "shoot_half"
repeat
until get_shooting() == true
if e == 1 then set_aflock(1) end
if f == 1 then
if get_propset() == 2 then
set_prop(262,TV)
else
set_prop(69,TV)
end
else
set_ev(EV)
end
press "shoot_full"
release "shoot_full"
release "shoot_half"
repeat
until get_shooting() ~= true
end
function multi_shooting(count)
if count>1 then print("Aufnahme 1 von",count) end
shooting()
if count>1 then
for n=2,count do
print("Aufnahme",n,"von",count)
shooting()
end
end
end
function print_Tv()
tv_output = {"64s","50s","40s","32s","25s","20s","15s","13s","10s","8s","6s",
"5s","4s","3.2s","2.5s","2s","1.6s","1.3s","1s","0.8s","0.6s","0.5s","0.4s",
"0.3s","1/4s","1/5s","1/6s","1/8s","1/10s","1/13s","1/15s","1/20s","1/25s",
"1/30s","1/40s","1/50s","1/60s","1/80s","1/100s","1/125s","1/160s","1/200s",
"1/250s","1/320s","1/400s","1/500s","1/640s","1/800s","1/1000s","1/1250s",
"1/1600s","1/2000s","1/2500s","1/3200s","1/4000s","1/5000s","1/6400s",
"1/8000s","1/10000s"}
print_tv = "Tv="..tv_output[tv+19]
end
function EV_hdr()
x=0
for s=1,b do
if x>0 then x=-1 else x=1 end
EV = Ev_is + (s/2*x) * a * 32
z=EV/32/3
if z<0 then zz=z*-1 else zz=z end
if x == -1 then
zzz = "-"..zz..","
else
zzz = zz..","
end
cls()
print("Bild",s,"von",b,"mit",zzz..(EV*10/32/3-z*10)*x,"Ev")
multi_shooting(d)
end
end
function TV_hdr()
x=0
for s=1,b do
if x>0 then x=-1 else x=1 end
TV = Tv_is + (s/2*x) * a * 32
tv = TV / 32
cls()
print_Tv()
print("Bild",s,"von",b,print_tv)
multi_shooting(d)
end
end
--start script
if a<1 then a=1 end
if b<3 then b=3 end
if c<0 then c=0 end
if d<1 then d=1 end
if e<0 or e>1 then e=0 end
if f<0 or f>1 then f=0 end
time01 = get_tick_count()
press("shoot_half")
repeat
until get_shooting() == true
release("shoot_half")
Ev_is = get_ev()
Tv_is = get_tv96()
tv = Tv_is / 32
flash = get_flash_mode()
EV = 0
TV = 0
if flash ~= 2 then
print("Blitz abschalten!")
sleep(3000)
exit_alt()
sleep(2000)
end
if c>0 then
print("Warte",c,"Sekunde(n)")
sleep(c*1000)
end
if g>-1 then print_screen(100+g) end
if f==0 then
EV_hdr()
else
TV_hdr()
end
set_ev(Ev_is)
set_tv96(Tv_is)
cls()
time02 = get_tick_count()
time03 = (time02 - time01)/1000
print(b*d,"Aufnahmen in",time03,"Sek.")
print(os.date("am %d.%m.%y um %X"))
print("erstellt.")
if g>-1 then print_screen(-10000) end
if e == 1 then set_aflock(0) end
Erstellt in 0.023 Sekunden, mit GeSHi 1.0.8.9
Viel Spaß beim Testen
Gruß msl