Indefinite repeats and filenaming

Questions, tips, information and discussions about using the SharpCap Sequencer and Sequence Planner tools
Post Reply
joellama
Posts: 4
Joined: Tue Feb 23, 2021 5:59 pm

Indefinite repeats and filenaming

#1

Post by joellama »

I'm using sharpcap to cycle through 3 ZWO cameras and a webcam to take various images of my telescope enclosure. I've tried doing this with the scripting language but it crashes after about 1 or 2 loops (I think because I'm using a USB extender - I have no control over this). The sequencer does seem a bit more stable but I can't figure out how to customize it to how I need.

Ideally I would need to be able to have the files named CAMERANAME_TIMESTAMP.jpg in a single folder DATE but I can't seem to be able to set that, is that currently possible? I would also need to loop indefinitely (even better would be an IF statement for if the sun is up - I do this during the day).

I know this isn't really what Sharpcap is designed for but if any of this is already possible I would love some guidance! Thanks, Joe.
User avatar
admin
Site Admin
Posts: 17558
Joined: Sat Feb 11, 2017 3:52 pm
Location: Vale of the White Horse, UK
Contact:

Re: Indefinite repeats and filenaming

#2

Post by admin »

Hi Joe,

you should be able to get the filenames that you want by setting the 'Stills' capture template to something like

Code: Select all

{Date}\{Camera}_{FrameTime}
See this part of the documentation for more info on setting up filename templates : https://docs.sharpcap.co.uk/4.0/#Filename%20Templates

While there is no step in the sequencer to repeat indefinitely, you can add a repeat loop for a specified number of times and set the count up as far as 1,000,000,000 - which should be enough. If you want more, nest two loops inside each other.

As for the sun being up, there is no if statement, but there are 'wait until' and 'repeat until' steps which you can use. For instance the sequence below will capture 1 frame every 10 seconds during daytime for the next ~27 million years

Code: Select all

SEQUENCE
    LOOP 999999999 TIMES
        WAIT UNTIL EVENT Sunrise
        LOOP UNTIL Sunset
            CAPTURE 1 LIVE FRAMES
            DELAY 10
        END LOOP
    END LOOP
END SEQUENCE
Hope this helps,

Robin
joellama
Posts: 4
Joined: Tue Feb 23, 2021 5:59 pm

Re: Indefinite repeats and filenaming

#3

Post by joellama »

Thanks for the reply, Robin! I’ll give that part of the documentation a proper read (I missed it originally).
joellama
Posts: 4
Joined: Tue Feb 23, 2021 5:59 pm

Re: Indefinite repeats and filenaming

#4

Post by joellama »

Hi Robin, this looks to *almost do exactly what I need, thanks! Could I request a new feature? Under the Repeat tab of the sequencer, could you add Repeat Until Time? Currently there is Repeat N times, or until AstronomicalEvent; however, that requires an ASCOM mount from what I can tell? There is a Time option available under Wait but not repeat from what I can see. Thanks!
User avatar
admin
Site Admin
Posts: 17558
Joined: Sat Feb 11, 2017 3:52 pm
Location: Vale of the White Horse, UK
Contact:

Re: Indefinite repeats and filenaming

#5

Post by admin »

Hi,

yes, a repeat until time is something I can add.

You should be able to get the repeat until Astro event to work without an ASCOM mount - just set your latitude and longitude in the 'Polar Align' settings and I think that will work.

cheers,

Robin
joellama
Posts: 4
Joined: Tue Feb 23, 2021 5:59 pm

Re: Indefinite repeats and filenaming

#6

Post by joellama »

Yep, I just found that setting - thanks for the quick replies! Currently the script is doing exactly what I need (though the repeat until Time feature could be a useful addition anyway). Thanks again!
Post Reply