guerchi

New Member
Joined
Sep 17, 2016
Messages
3
Reaction score
0
Country
Argentina
Hi all, I have been weeks trying to achieve this goal. I need that these great little camera, take pictures every 5 minutes over a period of 12 hours and then automatically shut down. This process would be repeated for several days to record the evolution of building a machine.


For this, I have 20.000Mah external battery and Micro SD San Disk Ultra 32GB Class 10 cards. I am using a modified script originally created with the wonderful application XYC. To make periods of 5 minutes work I had to downgrade the firmware to version 1.2.6. But, So far achieved only sometimes take the 130 photos of the script. Usually take between 50 and 65 pictures and stops working. Thinking about an overheating problem i tried different cooling systems, but that doesn't seem to solve the problem.

Here is the current code:
Code:
# Generated by XYC 1.0.1 Alex, Thu Jan  1 00:10:37 UTC 1970
# https://github.com/alex-agency/XYC

#vibrance/saturation adjustments
t ia2 -adj ev 10 0 70 0 0 150 0

#set JPEG quality to 100%
t cal -jqlt 100

#shadow/highlight clipping adjustments
#this makes blacks not crushed
#set long exposure level [0~255]
t ia2 -adj l_expo 163
#this gets back the highlights
#set Auto Knee level [0~255]
t ia2 -adj autoknee 255

#set ISO and Exposure
# exp: [iso_idx][exp_idx][gain_idx], 0 auto
t ia2 -ae exp 0 400 0

#disable Auto White Balance
t ia2 -awb off

#create RAW files
t app test debug_dump 14

#set AAA function
# -3a [ae][awb][af][adj]: turn on/off ae/awb/af/adj
#  ae = [0|1], 0:on 1:off AE
#  awb = [0|1], 0:on 1:off AWB
#  af  = [0|1], 0:on 1:off AF
#  adj = [0|1], 0:on 1:off ADJ
t ia2 -3a 1 1 0 1

#set buzzer volume [1~150]
t pwm 1 set_level 30

#Greeting script
#front led blink
t gpio 6 sw out1
sleep 1
t gpio 6 sw out0
t gpio 54 sw out1
sleep 1
t gpio 54 sw out0
#short beep & front leds
t gpio 6 sw out1
t gpio 54 sw out1
t pwm 1 enable
sleep 1
t gpio 6 sw out0
t gpio 54 sw out0
t pwm 1 disable

#Time-lapse: 0 240 150 n y
sleep 10
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 300
t app key shutter
t app key shutter_rel
sleep 30
poweroff yes

The truth is that I'm going crazy, I made very many test, and I can not realize because only some odd time it runs the entire script. If anyone has any idea,I sincerely appreciate it. Sorry for my English rough.
 

StfLA

Member
Joined
Aug 6, 2015
Messages
73
Reaction score
5
Country
France
Start with a more simple script:
Remove all the custom settings, iso, raw, etc.. test

You can keep the loop in an external script:

call the loop from autoexec.ash with
Code:
# CALL LOOP
d:/loop.ash
then create a loop.ash script on the Sd card with
Code:
i = 0
while i < 150
do
t app key shutter
sleep 300
i = i+1
done

I didn't test it
 

mkgosselin

New Member
Joined
Jan 23, 2017
Messages
1
Reaction score
0
Country
Germany
hi! I'm new here but I'm looking for a similar solution for my XiaoMi to take one picture every hour non stop.
I have no idea how to write such a script though... nor how to apply it. Just discovered Max Lyons website an hour ago. Is there anyone who could help me on this? I would be so thankful!!!
Greetings,
martin
 

StfLA

Member
Joined
Aug 6, 2015
Messages
73
Reaction score
5
Country
France
You could just take my example and change the loop.ash with these commands :
Code:
while true
do
t app key shutter
sleep 3600
done
 

ross350

New Member
Joined
Sep 17, 2017
Messages
5
Reaction score
0
Country
Australia
ok, after scouring this page for ages, I found a way.
AND HOLY CRAP WHAT AN ANNOYING PROBLEM TO GET AROUND!

anyway, firstly, you need a battery in, and I guess you will also be plugged in. I don't know why but the reboot function locks up without a battery in.
so, with a battery in , you can put a line of

Code:
reboot yes

after huge sleep times. so put a single shutter bit of script before that,
here is a 15 min timelapse (well 15min and 14 second plus reboot time but it works)

Code:
sleep 10
while true; do
  sleep 4
  t app key shutter
  t app key shutter_rel
  sleep 900
  reboot yes
done


I guess it doesn't really need to even be in a while loop now, but ah well

They discuss it here.
 

ross350

New Member
Joined
Sep 17, 2017
Messages
5
Reaction score
0
Country
Australia
ok, after scouring this page for ages, I found a way.
AND HOLY CRAP WHAT AN ANNOYING PROBLEM TO GET AROUND!

anyway, firstly, you need a battery in, and I guess you will also be plugged in. I don't know why but the reboot function locks up without a battery in.
so, with a battery in , you can put a line of

Code:
reboot yes

after huge sleep times. so put a single shutter bit of script before that,
here is a 15 min timelapse (well 15min and 14 second plus reboot time but it works)

Code:
sleep 10
while true; do
  sleep 4
  t app key shutter
  t app key shutter_rel
  sleep 900
  reboot yes
done


I guess it doesn't really need to even be in a while loop now, but ah well

They discuss it here.
up, turns out that does freeze up on reboot, ****s ****ed, anyone got a working script to do 15 min interval continuous time-lapse.
like an actual script that does that.
 

inkocus

New Member
Joined
Dec 12, 2015
Messages
2
Reaction score
0
Country
Canada
so If I understand this, long sleep durations do not work because the camera falls asleep after 1 minute?
is there a way to wake up the camera with the script?

cheers
 
Top