Page 1 of 1

Simple script for taking LRGB

Posted: 11 Dec 2018, 16:49
by Forum_2017
Hello, I have been asked the simplest script to take L,R,G,B images, where the L is in binning 1x1 and the others in 2x2.
Here is a solution which takes 3 red, 3 green, 3 blu in binning 2x2, then 6 lum in binning 1x1. It can be tested indoor with the camera and filter wheel simulators. Remember to change the "C:\Temp\" folder if needed.

Code: Select all

dir = "C:\Temp\"

Sub Sequence(filter,object,images,exposure,binning)
  Wheel.Goto(filter)
  For i = 1 to images
     Camera.Binning(binning)
     Camera.Start(exposure)
     Camera.Wait
     fileName = object + filter + Format(i,"000")+ ".fit"
     Image.Save(dir + fileName)
     Image.Close
  Next i
End Sub

Sequence("R", "M42", 3, 5.0, 2)
Sequence("G", "M42", 3, 5.0, 2)
Sequence("B", "M42", 3, 5.0, 2)
Sequence("L", "M42", 6, 5.0, 1)

Re: Simple script for taking LRGB

Posted: 11 Dec 2018, 16:49
by Forum_2017
Tried this last night.
How do I add binning and exposure in file name + "-" or "_" as well ?

Re: Simple script for taking LRGB

Posted: 11 Dec 2018, 16:50
by Forum_2017
For example:

fileName = object + filter + Format(i,"000") + "_" + str(exposure) + "_B" + str(binning) + ".fit"