A brief introduction to the SharpCap Sequencer

Discussions, Bug Reports and Issues related to Beta versions of SharpCap
User avatar
Tiago Ferreira
Posts: 143
Joined: Sun Mar 21, 2021 10:50 pm

Re: A brief introduction to the SharpCap Sequencer

#111

Post by Tiago Ferreira »

admin wrote: Sun Apr 17, 2022 9:16 pm Hi,

I take it here you are thinking only of the small progress window, yes? Auto closing the main sequence editor window if it happens to be open would be weird...

cheers,

Robin
Yes, only the progress window. I have to close it and mostly clicking several times until it let me close. It's a simple but very useful sequence to turn things even more fluid.
Youtube channel: https://youtube.com/@DobsonianPower

12" f/5 Dobsonian GSO
8" f/6 Dobsonian GSO
6" f/5 Dobsonian Go-To Virtuoso Gti
Dwarf II Smart Telescope
Geoptik Eartha Eq Platform
ZWO ASI224MC + ZWO ASI294MC
User avatar
Tiago Ferreira
Posts: 143
Joined: Sun Mar 21, 2021 10:50 pm

Re: A brief introduction to the SharpCap Sequencer

#112

Post by Tiago Ferreira »

Robin, you could also just add a checkbox to the window to "close window after...." as it happen in many applications.
I can see that window box has already 1 checkbox but i don't know what is it for.
Youtube channel: https://youtube.com/@DobsonianPower

12" f/5 Dobsonian GSO
8" f/6 Dobsonian GSO
6" f/5 Dobsonian Go-To Virtuoso Gti
Dwarf II Smart Telescope
Geoptik Eartha Eq Platform
ZWO ASI224MC + ZWO ASI294MC
User avatar
admin
Site Admin
Posts: 13317
Joined: Sat Feb 11, 2017 3:52 pm
Location: Vale of the White Horse, UK
Contact:

Re: A brief introduction to the SharpCap Sequencer

#113

Post by admin »

Hi,

actually, I added a new step to close the progress - I just forgot to mention it :)

'Hide progress on successful completion of sequence'

If you put that anywhere in your sequence then you should be fine. If the sequence finishes with an error then it will not hide, since you will probably want to view the log to see what caused the error.

The checkbox that is already there forces the progress to be 'on top' of all other windows, so it would still be visible even if you (for instance) open a web browser in front of SharpCap.

cheers,

Robin
Moorefam
Posts: 47
Joined: Thu Nov 26, 2020 11:46 am

Re: A brief introduction to the SharpCap Sequencer

#114

Post by Moorefam »

Robin,
I am having problems with the sequencer.

I want to auto focus with 1.5s exp and gain 600, then capture 20 lights at 180s gain 250 dithering every 2 frames and this should take 1 hr each time through the loop. I want to repeat 4 times then park the mount after 4 hrs.

SEQUENCE
DELAY 1
STILL MODE
STILL MODE
SET OUTPUT FORMAT TO "FITS files (*.fits)"
GUIDING CONNECT ABORT False
MOUNT UNPARK
PROMPT FOR TARGET
LOOP 4 TIMES
PRESERVE CAMERA SETTINGS
FOCUSER CONNECT
SET EXPOSURE TO 1.5
SET GAIN TO 600
AUTOFOCUS OFFSET -50 TO 50 STEP COUNT 10 BACKLASH 0
PRESERVE CAMERA SETTINGS
SET EXPOSURE TO 180
SET GAIN TO 250
FRAMETYPE Light
CAPTURE 20 FRAMES REQUIREGUIDING True
GUIDING DITHER EVERY 2 FRAMES
END PRESERVE
END PRESERVE
END LOOP
MOUNT PARK
END SEQUENCE

It doesn't dither on the 1st loop but does after that and I don't think it does autofocus each time.I found it hard to keep track of what it was doing and I wanted to save the various events but couldn't see how to. It's hard at 01:00.
I really need help to get this working properly as I need to autofocus and dither automatically so any help would be appreciated. I have been struggling with the sequencer for awhile. I set everything up before I run the sequencer and do autofocus and guiding with PHD. I know everything works without the sequencer. I had found with another sequence that 1st time through the loop the autofocus position was different which caused it to have to extend its focus positioning so maybe my autofocus instruction is the wrong one? I still used AUTOFOCUS OFFSET -50 TO 50 STEP COUNT 10 BACKLASH 0
User avatar
admin
Site Admin
Posts: 13317
Joined: Sat Feb 11, 2017 3:52 pm
Location: Vale of the White Horse, UK
Contact:

Re: A brief introduction to the SharpCap Sequencer

#115

Post by admin »

Hi,

it looks like you have these steps the wrong way round

Code: Select all

CAPTURE 20 FRAMES REQUIREGUIDING True
GUIDING DITHER EVERY 2 FRAMES
The way they are means that the dithering is turned on after the capture has been done, whch explains why the dithering fails to happen on the first repeat but works on the others.

The autofocus step looks fine, but do be sure that you have corrected out the backlash on the focuser if you are using 'Backlash 0' - either in the ASCOM settings, or the SharpCap settings (correction or overshoot focusing). If you do have backlash that is unaccounted for then weird things may happen - for instance the scan may not reach best focus in the -50 to 50 range due to backlash, in which case SharpCap will continue the scan further if it thinks the focus is improving and best focus may be just a bit further on.

cheers,

Robin
User avatar
Hibou
Posts: 81
Joined: Thu Jul 05, 2018 3:25 pm
Location: French Alps
Contact:

Re: A brief introduction to the SharpCap Sequencer

#116

Post by Hibou »

Sequencer is ideal for launching an external Visual Basic (or other) motor script between individual frames, and although there are lots of commands, it is easy to understand. Now I'm looking how to do it the other way around - launching SharpCap with parmeters from a script. I saw some references to using Python to call SharpCap, but I'm still searching. Some people might also like to call SharpCap from LabView.

Anyway, to call the following VB test script "Orient.VBS" (The "Motor" voice will be replaced by a moto control)
Set Sapi=Wscript.CreateObject("SAPI.spVoice")
Sapi.speak "motor"


I use the following SharpCap script with an ASI174MM but later with a cooled camera.
(It works, but please feel free to comment. Probably I need a "wait for temperature"):
SEQUENCE
CAMERA OPEN "ZWO ASI174MM Mini"
STILL MODE
SET COLOUR SPACE TO MONO16
SET RESOLUTION TO 1936x1216
SET BINNING TO 2
SET OUTPUT FORMAT TO "FITS files (*.fits)"
SET EXPOSURE TO 5
SET GAIN TO 125
SET CONTROL "Frame Rate Limit" TO Maximum
SET CONTROL Flip TO Horiz
SET CONTROL "Turbo USB" TO 0
SET CONTROL "Discard Split Frames" TO Off
SET CONTROL Temperature TO -10
SET CONTROL Brightness TO 0
SET CONTROL "Timestamp Frames" TO Off
LOOP 360 TIMES
CAPTURE 1 FRAMES REQUIREGUIDING False
RUN C:\ImageJ\VBScripts\Orient.vbs WITH PARAMS "" WAIT False
COUNTDOWN FOR 3 SHOWING Positioning...
END LOOP
END SEQUENCE

Note that post-processing with dark and flat frames is done with the Tomographic reconstruction software http://neutronoptics.com/muhrec.html
User avatar
admin
Site Admin
Posts: 13317
Joined: Sat Feb 11, 2017 3:52 pm
Location: Vale of the White Horse, UK
Contact:

Re: A brief introduction to the SharpCap Sequencer

#117

Post by admin »

Hi,

if you want to run SharpCap and get it to do something on startup then your best bet is to use the '/runscript' command line option, which should cause SharpCap to run the specified python script after startup is complete. For instance

Code: Select all

"c:\Program Files (x86)\SharpCap 4.0\SharpCap.exe" /runscript "c:\my scripts\test.py"
If you want to use the sequencer from startup, then make the content of your python script something like

Code: Select all

SharpCap.Sequencer.RunSequenceFile('c:\\my files\\test.scs')
Hope that this helps,

Robin
User avatar
Hibou
Posts: 81
Joined: Thu Jul 05, 2018 3:25 pm
Location: French Alps
Contact:

Re: A brief introduction to the SharpCap Sequencer

#118

Post by Hibou »

Thanks Robin. That looks easy. Cheers, Alan.
Post Reply