Friday, August 18, 2017

On the trip to the eclipse

Arriving in Klamath Falls, OR, at 8 pm, we saw some smoky haze in the sky from forest fires north west of the area.  Checking the internet, I saw a picture from Bend where the sun was dim and the sky was brown.  Hoping that this will be controlled quickly and we'll have clear skies for night time viewing and the eclipse itself!

I copied the AHK script for the K10D to use the Pentax Image Transmitter 2 software for tethering the K-1 camera.  After updating the mouse clicks and directions to trigger the menus, I found that the main difference was that the IT2 software is slow.  There is a noticeable delay to display the dropdown menus before they can be used.  Had to build in 100-250 microsecond delays to allow the software to respond, for the camera to update settings, and be ready for new commands.

Yet to be made: audio announcements to work with the filters.  I may just set a timer on my phone.

Here's how this update looks:


#SingleInstance force
CoordMode, mouse, screen



; Get target time in a format we can:
;  - compare (with "<")
; < comparison should be safe as long as both are in the *exact* same format.
; time is 2305 format
; ====================================
; the values listed below are for the eclipse BE SURE TO UNCOMMENT
;filter1timeS = %A_YYYY%%A_MM%%A_DD%090643 ; 9:06:43 am
;filter1timeE = %A_YYYY%%A_MM%%A_DD%101830 ; 10:18:30 am 50 seconds to remove filters
;beads1timeS  = %A_YYYY%%A_MM%%A_DD%101920 ; 10:19:20 am 13 seconds to spam for beads
;beads1timeE  = %A_YYYY%%A_MM%%A_DD%101933 ; 10:19:33 am
;brackettimeS = %A_YYYY%%A_MM%%A_DD%101934 ; 10:19:34 am
;brackettimeE = %A_YYYY%%A_MM%%A_DD%102125 ; 10:21:25 am
;beads2timeS  = %A_YYYY%%A_MM%%A_DD%102135 ; 10:21:35 am 10 seconds to spam for beads
;beads2timeE  = %A_YYYY%%A_MM%%A_DD%102145 ; 10:21:45 am
;filter2timeS = %A_YYYY%%A_MM%%A_DD%102200 ; 10:22:15 am 30 seconds to apply filters
;filter2timeE = %A_YYYY%%A_MM%%A_DD%114102 ; 11:41:02 am

; ====================================
; the values listed below are for testing
filter1timeS = %A_YYYY%%A_MM%%A_DD%224500 ; 
filter1timeE = %A_YYYY%%A_MM%%A_DD%224500 ; 
beads1timeS  = %A_YYYY%%A_MM%%A_DD%224520 ; 
beads1timeE  = %A_YYYY%%A_MM%%A_DD%224535 ; 
brackettimeS = %A_YYYY%%A_MM%%A_DD%224536 ; 
brackettimeE = %A_YYYY%%A_MM%%A_DD%224739; 
beads2timeS  = %A_YYYY%%A_MM%%A_DD%224741 ; 
beads2timeE  = %A_YYYY%%A_MM%%A_DD%224755 ; 
filter2timeS = %A_YYYY%%A_MM%%A_DD%224810 ; 
filter2timeE = %A_YYYY%%A_MM%%A_DD%225000 ; 

; ====================================

; send filtersettings ; set single frame shooting with appropriate fstop and shutter speed

; K1 Aperture is F8 set on the lens
; K1 ISO is 200 
; K1 beads shutter speed is 8000
; K1 central bracket is 1/30
; K1 filter setting is 1/1000
Click 1397, 195 ; set bracket mode off
 sleep 150
 SendInput {PgUp 2}
 SendInput {Enter}
 sleep 150
;click 1397, 195 ; set single shot
; sleep 100
; SendInput {Enter}
; sleep 100
click 1578, 299 ; set shutter speed to 8000 then up to 1000 
 sleep 150
 send {PgDn 8}
 sleep 250
 send {Up 9}
 sleep 150
 send {Enter}
 sleep 150
MouseMove 1552, 504 ; position mouse over shutter button

gosub, filter1

; remove filters audio warning
; SoundPlay K1filter.wma


; send beadsettings ; set continuous shooting speed to Low with appropriate fstop and shutter speedset beads
Click 1397, 195 ; set bracket mode off
 sleep 100
 Send {PgUp 2}
 Send {Enter}
 sleep 100
click 1397, 195 ; set continuous medium
 sleep 100
 Send {Down 2}
 Send {Enter}
 sleep 100
click 1578, 299 ; set shutter speed to 8000
 sleep 100
 send {PgDn 7}
 sleep 100
 send {Enter}
 sleep 50
MouseMove 1552, 504 ; position mouse over shutter button

gosub, beads1

; send bracketsettings
Click 1397, 195 ; set bracket mode off
 sleep 100
 Send {PgUp 2}
 Send {Enter}
 sleep 50
click 1397, 195 ; set single shot
 sleep 100
 Send {Enter}
 sleep 100
click 1578, 299 ; set shutter speed to 1/30 from 8000
 sleep 100
 send {PgDn 8}
 sleep 250
 send 1/30
 sleep 150
 sendInput {Enter}
 sleep 100
click 1397, 195 ; set bracket mode
 sleep 100
 Send {Down 9}
 Send {Enter}
 sleep 150

MouseMove 1552, 504 ; position mouse over shutter button


gosub, totality

; beads2
; send beadsettings ; set continuous shooting speed to Low with appropriate fstop and shutter speedset beads
Click 1397, 195 ; set bracket mode off
 sleep 100
 Send {PgUp 3}
 sleep 50
 Send {Enter}
 sleep 150

click 1578, 299 ; set shutter speed to 8000
 sleep 100
 sendInput {PgDn 8}
 sleep 150
 SendInput {Enter}
 sleep 150
 
click 1397, 195 ; set continuous medium
 sleep 100
 SendInput {Down 2}
 sleep 50
 SendInput {Enter}
 sleep 150

MouseMove 1552, 504 ; position mouse over shutter button

gosub, beads2

; apply filters audio warning
; SoundPlay K1filter.wma


;set final filter settings
Click 1397, 195 ; set bracket mode off
 Send {PgUp 2}
 sleep 200
 Send {Enter}
click 1397, 195 ; set single shot
 Send {Enter}
 sleep 200
click 1578, 299 ; set shutter speed to 8000 then up to 1000 
 sleep 200
 send {PgDn 7}
 sleep 200
 send {Up 9}
 sleep 200
 send {Enter}
MouseMove 1552, 504 ; position mouse over shutter button
gosub, filter2

goto, terminate

; ====================================

; subroutines

; ====================================

filter1:
; this is first to second contact
; send a picture click once a minute


if (A_Now >= filter1timeS)  
 { 
 Loop
  { 
   MouseClick, left, 1550, 495, 1, 10  ; click slowly to ensure shutter register
   sleep 60000 ; wait a minute
   if (A_Now >= filter1timeE)
    break 
   if (A_Now < filter1timeE)
    continue
  }}
 else
  { 
   Sleep 60000 ; wait a minute
   goto filter1 ; go back to the start of the subroutine
  }
 
return

; ====================================

beads1:
; this is the beads1 subroutine

; press and hold shutter button while beads active
if (A_Now > beads1timeS)
 {
 Loop
  {
   MouseClick, left, 1550, 495, 1, 10, D ; Press and hold shutter button
   if (A_Now >= beads1timeE)
    {
    MouseClick, left, 1550, 495, 1, 10, U ; release shutter button
    Break 
    }
   if (A_Now < beads1timeE)
    sleep 1000 ; wait a second
    continue
  }}
 else
  { 
   Sleep 1000 ; wait a second
   goto beads1 ; go back to the start of the subroutine
  }
 
return
 
; ====================================

totality:
; this is the subroutine for totality with bracketing

 
if (A_Now > brackettimeS)
 {
 Loop
  {
   MouseClick, left, 1550, 495, 1, 10
   Sleep 4000  ; click every 4 seconds
   if (A_Now >= brackettimeE)
    Break 
   If (A_Now < brackettimeE)
    continue
  }}
 else
    { 
   Sleep 1000 ; wait a second
   goto totality ; go back to the start of the subroutine
  }
 
return

; ==================================== 
 
beads2:
; this is the second beads routine


if (A_Now > beads2timeS)
 {
 Loop
  {
   MouseClick, left, 1550, 495, 1, 10, D ; Press and hold shutter button
   if (A_Now >= beads2timeE)
    {
    MouseClick, left, 1550, 495, 1, 10, U ; release shutter button
    Break 
    }
   if (A_Now < beads2timeE)
    sleep 1000 ; wait a second
    continue
  }}
 else
  { 
   Sleep 1000 ; wait a second
   goto beads2 ; go back to the start of the subroutine
  }
 
return

; ====================================
   
filter2:
; this is from 3rd to 4th contact


if (A_Now >= filter2timeS)  
 { 
 Loop
  { 
   MouseClick, left, 1550, 495, 1, 10  ; click slowly to ensure shutter register
   sleep 60000 ; wait a minute
   if (A_Now >= filter2timeE)
    break 
   if (A_Now < filter2timeE)
    continue
  }}
 else
  { 
   Sleep 1000 ; wait a second
   goto filter2 ; go back to the start of the subroutine
  }
 
return

; ====================================




terminate:
 exit
 
Esc::ExitApp 

Thursday, August 17, 2017

Properly working AHK Script

Last night, I got the AutoHotKey script to work with the Pentax K10D.

Very slick and I can see how I might be able to script things like Maxim.

Here is the properly working code for reference.


#SingleInstance force
CoordMode, mouse, screen



; Get target time in a format we can:
;  - compare (with "<")
; < comparison should be safe as long as both are in the *exact* same format.
; time is 2305 format
; ====================================
; the values listed below are for the eclipse BE SURE TO UNCOMMENT
;filter1timeS = %A_YYYY%%A_MM%%A_DD%090643 ; 9:06:43 am
;filter1timeE = %A_YYYY%%A_MM%%A_DD%101830 ; 10:18:30 am 50 seconds to remove filters
;beads1timeS  = %A_YYYY%%A_MM%%A_DD%101920 ; 10:19:20 am 13 seconds to spam for beads
;beads1timeE  = %A_YYYY%%A_MM%%A_DD%101933 ; 10:19:33 am
;brackettimeS = %A_YYYY%%A_MM%%A_DD%101934 ; 10:19:34 am
;brackettimeE = %A_YYYY%%A_MM%%A_DD%102125 ; 10:21:25 am
;beads2timeS  = %A_YYYY%%A_MM%%A_DD%102135 ; 10:21:35 am 10 seconds to spam for beads
;beads2timeE  = %A_YYYY%%A_MM%%A_DD%102145 ; 10:21:45 am
;filter2timeS = %A_YYYY%%A_MM%%A_DD%102200 ; 10:22:15 am 30 seconds to apply filters
;filter2timeE = %A_YYYY%%A_MM%%A_DD%114102 ; 11:41:02 am

; ====================================
; the values listed below are for testing
filter1timeS = %A_YYYY%%A_MM%%A_DD%222000 ; 
filter1timeE = %A_YYYY%%A_MM%%A_DD%223000 ; 
beads1timeS  = %A_YYYY%%A_MM%%A_DD%223100 ; 
beads1timeE  = %A_YYYY%%A_MM%%A_DD%223115 ; 
brackettimeS = %A_YYYY%%A_MM%%A_DD%223120 ; 
brackettimeE = %A_YYYY%%A_MM%%A_DD%223420 ; 
beads2timeS  = %A_YYYY%%A_MM%%A_DD%223425 ; 
beads2timeE  = %A_YYYY%%A_MM%%A_DD%223435 ; 
filter2timeS = %A_YYYY%%A_MM%%A_DD%223510 ; 
filter2timeE = %A_YYYY%%A_MM%%A_DD%224000 ; 

; ====================================

; send filtersettings ; set single frame shooting with appropriate fstop and shutter speed 
Click 1452, 491 ; set bracket mode off
	SendInput {PgUp}
	SendInput {Enter}
click 1472, 452 ; set single shot
	SendInput {Down}
	SendInput {Enter}
click 1222, 485 ; set shutter speed to 4000 then down to 500 
	sendInput {PgUp}
	sendInput {Down 9}
	sendInput {Enter}
click 1222, 518 ; set f stop to max then to F5.6
	sendInput {PgUp}
	sendInput {Down 12}
	sendInput {Enter}
Click 1501, 14 ; click on shutter control window bar to make active
MouseMove 1565, 363 ; position mouse over shutter button

gosub, filter1

; remove filters audio warning


; send beadsettings ; set continuous shooting speed to Low with appropriate fstop and shutter speedset beads
Click 1452, 491 ; set bracket mode off
	SendInput {PgUp}
	SendInput {Enter}
click 1472, 452 ; set continuous
	SendInput {Down 2}
	SendInput {Enter}
click 1222, 485 ; set shutter speed to 4000
	sendInput {PgUp}
	sendInput {Enter}
Click 1501, 14 ; click on shutter control window bar to make active
MouseMove 1565, 363 ; position mouse over shutter button

gosub, beads1

; send bracketsettings
click 1472, 452 ; set single shot
	SendInput {Down}
	SendInput {Enter}
click 1222, 485 ; set shutter speed to 1/8 from 4000
	sendInput {Down 27}
	sendInput {Enter}
Click 1452, 491 ; set bracket mode on with 5 shots
	SendInput {Down 2}
	SendInput {Enter}
Click 1501, 14 ; click on shutter control window bar to make active
MouseMove 1565, 363 ; position mouse over shutter button

gosub, totality

; beads2
; set beads ; set continuous shooting speed to Low with appropriate fstop and shutter speed
Click 1452, 491 ; set bracket mode off
	SendInput {Up 2}
	SendInput {Enter}
click 1472, 452 ; set continuous
	SendInput {Down 2}
	SendInput {Enter}
click 1222, 485 ; reset shutter speed to 4000 max
	sendInput {PgUp}
	sendInput {Enter}
click 1222, 518 ; set f stop to max then to F5.6
	sendInput {PgUp}
	sendInput {Down 12}
	sendInput {Enter}
Click 1501, 14 ; click on shutter control window bar to make active
MouseMove 1565, 363 ; position mouse over shutter button

gosub, beads2

; apply filters audio warning

;set final filter settings
Click 1452, 491 ; set bracket mode off
	SendInput {PgUp}
	SendInput {Enter}
click 1472, 452 ; set single shot
	SendInput {Down}
	SendInput {Enter}
click 1222, 485 ; set shutter speed to 500 from earlier 4000
	sendInput {down 9}
	sendInput {Enter}
Click 1501, 14 ; click on shutter control window bar to make active
MouseMove 1565, 363 ; position mouse over shutter button
gosub, filter2

goto, terminate

; ====================================

; subroutines

; ====================================

filter1:
; this is first to second contact
; send a picture click once a minute


if (A_Now >= filter1timeS)  
	{ 
	Loop
		{ 
			MouseClick, left, 1565, 363, 1, 10  ; click slowly to ensure shutter register
			sleep 60000 ; wait a minute
			if (A_Now >= filter1timeE)
				break 
			if (A_Now < filter1timeE)
				continue
		}}
	else
		{ 
			Sleep 60000 ; wait a minute
			goto filter1 ; go back to the start of the subroutine
		}
	
return

; ====================================

beads1:
; this is the beads1 subroutine

; press and hold shutter button while beads active
if (A_Now > beads1timeS)
	{
	Loop
		{
			MouseClick, left, 1565, 363, 1, 10, D ; Press and hold shutter button
			if (A_Now >= beads1timeE)
				{
				MouseClick, left, 1563, 363, 1, 10, U ; release shutter button
				Break 
				}
			if (A_Now < beads1timeE)
				sleep 1000 ; wait a second
				continue
		}}
	else
		{ 
			Sleep 1000 ; wait a second
			goto beads1 ; go back to the start of the subroutine
		}
	
return
	
; ====================================

totality:
; this is the subroutine for totality with bracketing

	
if (A_Now > brackettimeS)
	{
	Loop
		{
			MouseClick, left, 1565, 363, 1, 10
			Sleep 3000  ; click every 3 seconds
			if (A_Now >= brackettimeE)
				Break 
			If (A_Now < brackettimeE)
				continue
		}}
	else
				{ 
			Sleep 1000 ; wait a second
			goto totality ; go back to the start of the subroutine
		}
	
return

; ====================================	
	
beads2:
; this is the second beads routine


if (A_Now > beads2timeS)
	{
	Loop
		{
			MouseClick, left, 1565, 363, 1, 10, D ; Press and hold shutter button
			if (A_Now >= beads2timeE)
				{
				MouseClick, left, 1563, 363, 1, 10, U ; release shutter button
				Break 
				}
			if (A_Now < beads2timeE)
				sleep 1000 ; wait a second
				continue
		}}
	else
		{ 
			Sleep 1000 ; wait a second
			goto beads2 ; go back to the start of the subroutine
		}
	
return

; ====================================
			
filter2:
; this is from 3rd to 4th contact


if (A_Now >= filter2timeS)  
	{ 
	Loop
		{ 
			MouseClick, left, 1565, 363, 1, 10  ; click slowly to ensure shutter register
			sleep 60000 ; wait a minute
			if (A_Now >= filter2timeE)
				break 
			if (A_Now < filter2timeE)
				continue
		}}
	else
		{ 
			Sleep 1000 ; wait a second
			goto filter2 ; go back to the start of the subroutine
		}
	
return

; ====================================




terminate:
	exit
	
Esc::ExitApp	

Wednesday, August 16, 2017

Auto Hot Key and Time Controls

I've been languishing with my AHK script.

The earlier example that was posted assumed that I understood how time controls worked. I tested these ideas last night and found my knowledge lacking.

While I was able to get the coordinates and button clicks working with the Pentax K10D camera, I found that my "while" flow control was poorly managed.

Here's what I wrote:

#SingleInstance force
CoordMode, mouse, screen

; Get target time in a format we can:
;  - compare (with "<")
; < comparison should be safe as long as both are in the *exact* same format.
; target_time is 2305 format
filter1timeS = %A_YYYY%%A_MM%%A_DD%%212500 ; 21:05 pm
filter1timeE = %A_YYYY%%A_MM%%A_DD%%213000 ; 21:10 pm
beads1timeS = %A_YYYY%%A_MM%%A_DD%%213100 ; 21:11 pm
beads1timeE = %A_YYYY%%A_MM%%A_DD%%213130 ; 21:1130 pm
brackettimeS = %A_YYYY%%A_MM%%A_DD%%213020 ; 21:1140 pm
brackettimeE = %A_YYYY%%A_MM%%A_DD%%213320 ; 21:1320 pm
beads2timeS = %A_YYYY%%A_MM%%A_DD%%213325 ; 21:1320 pm
beads2timeE = %A_YYYY%%A_MM%%A_DD%%213400 ; 21:14 pm
filter2timeS = %A_YYYY%%A_MM%%A_DD%%213410 ; 21:1410 pm
filter2timeE = %A_YYYY%%A_MM%%A_DD%%214000 ; 21:20 pm

; send filtersettings ; set single frame shooting with appropriate fstop and shutter speed 
click 1472, 452 ; set single shot
SendInput {Down}
SendInput {Enter}
click 1222, 485 ; set shutter speed to 500 from default 125
sendInput {Up 6}
sendInput {Enter}
click 1222, 518 ; set f stop 5.6 from default 8
sendInput {Up 3}
sendInput {Enter}

MouseMove 1565, 363
Click 1501, 14

while ((A_Now >= filter1timeS) and (A_Now <= filter1timeE)) ; this is first to second contact
{ ; send a picture click once a minute
MouseClick, left, 1565, 363, 1, 10
SendInput {Space}
sleep 60000
}


; remove filters audio warning
; beads1
; send beadsettings ; set continuous shooting speed to Low with appropriate fstop and shutter speedset beads
click 1472, 452 ; set continuous
SendInput {Down 2}
SendInput {Enter}
click 1222, 485 ; set shutter speed to 4000 from 500
sendInput {Up 9}
sendInput {Enter}

MouseMove 1565, 363
Click 1501, 14
while ((A_Now >= beads1timeS) and (A_Now <= beads1timeE)) ; this is when first beads goes
{ ; spam beads
MouseClick, left, 1565, 363, 1, 100, D
SendInput {Space}
; at the start 
 ; hold button until the end of beads time
}
MouseClick, left, 1563, 363, 1, 100, U
; click ; at the end, click again to stop the continuous shooting mode

; send bracketsettings
click 1472, 452 ; set single shot
SendInput {Down}
SendInput {Enter}
click 1222, 485 ; set shutter speed to 1/8 from 4000
sendInput {Down 27}
sendInput {Enter}
Click 1452, 491 ; set bracket mode on
SendInput {Down 2}

Click 1501, 14
MouseMove 1565, 363
while ((A_Now >= brackettimeS) and (A_Now <= brackettimeE)) ; this is totality
{ ; spam brackets
MouseClick, left, 1565, 363, 1, 100
Sleep 3000
; click every 3 seconds
}



; beads2
; set beads ; set continuous shooting speed to Low with appropriate fstop and shutter speed
Click 1452, 491 ; set bracket mode off
SendInput {Up 2}
click 1472, 452 ; set continuous
SendInput {Down 2}
SendInput {Enter}
click 1222, 485 ; reset shutter speed to 4000 max
sendInput {PgUp}
sendInput {Enter}
click 1222, 518 ; set f stop to max then to F5.6
sendInput {PgUp}
sendInput {Down 12}
sendInput {Enter}

Click 1501, 14
MouseMove 1565, 357
while ((A_Now >= beads2timeS) and (A_Now <= beads2timeE)) ; this is when second beads goes
{ ; spam beads
MouseClick, left, 1565, 363, 1, 100, D ; at the start 
}
MouseClick, left, 1565, 363, 1, 100, U ; at the end, click again to stop the continuous shooting mode

 ; apply filters audio warning

;set final filter settings
click 1472, 452 ; set single shot
SendInput {Down}
SendInput {Enter}
click 1222, 485 ; set shutter speed to 500 from default 125
sendInput {down 9}
sendInput {Enter}

Click 1501, 14
MouseMove 1565, 357

while ((A_Now >= filter2timeS) and (A_Now <= filter2timeE)) ; this is 3rd to 4th contact
{ ; send a picture click once a minute
MouseClick, left, 1565, 363, 1, 100
sleep 60000
}

return





As far as I can tell, none of the time controls worked.  I will need to go back to the original target_time AHK examples and see where I went wrong. 

The way the script runs now is that the mouse darts around, clicking buttons, changing settings, but the shutter is never fired because the "while" values are never true.  What I'd like to see would be that the script waits until the "while" values are true, executes, then moves to the next step.

I see a few possibilities to solve this problem:
  • Build nested "if...then" flow to catch all variations and wrap it all in a loop that waits a minute to try again.
  • Build a collection of separate AHK files and call them from the Windows Task Scheduler at the right times.

I think that the latter solution might be the easiest since I can test each step independently.




On review, I realize that the Task Scheduler won't stop a script at a certain time. 

So I'm back to the flow control within AHK.  I think that working with loops may be a better solution.

I'm going to try replacing the "while" with logic like this:

if (A_Now > filter1timeS)
 { 
 Loop
  { 
   MouseClick, left, 1565, 363, 1, 10
   sleep 60000
   if (A_Now >= filter1timeE)
    break
   if (A_Now < filter1timeE)
    continue
  }
 }



After playing with the loops, I see where the time controls failed - it was because of an extra "%" as this prevented the time values to be seen as a number.  Still, I rewrote the flow control using if and else and put the bits into subroutines.

Here's how it looks now and I'll try it out tonight:

#SingleInstance force
CoordMode, mouse, screen

; Get target time in a format we can:
;  - compare (with "<")
; < comparison should be safe as long as both are in the *exact* same format.
; time is 2305 format
; ====================================
; the values listed below are for the eclipse BE SURE TO UNCOMMENT
;filter1timeS = %A_YYYY%%A_MM%%A_DD%090643 ; 9:06:43 am
;filter1timeE = %A_YYYY%%A_MM%%A_DD%101830 ; 10:18:30 am 50 seconds to remove filters
;beads1timeS  = %A_YYYY%%A_MM%%A_DD%101920 ; 10:19:20 am 13 seconds to spam for beads
;beads1timeE  = %A_YYYY%%A_MM%%A_DD%101933 ; 10:19:33 am
;brackettimeS = %A_YYYY%%A_MM%%A_DD%101934 ; 10:19:34 am
;brackettimeE = %A_YYYY%%A_MM%%A_DD%102125 ; 10:21:25 am
;beads2timeS  = %A_YYYY%%A_MM%%A_DD%102135 ; 10:21:35 am 10 seconds to spam for beads
;beads2timeE  = %A_YYYY%%A_MM%%A_DD%102145 ; 10:21:45 am
;filter2timeS = %A_YYYY%%A_MM%%A_DD%102200 ; 10:22:15 am 30 seconds to apply filters
;filter2timeE = %A_YYYY%%A_MM%%A_DD%114102 ; 11:41:02 am

; ====================================
; the values listed below are for testing
filter1timeS = %A_YYYY%%A_MM%%A_DD%212000 ; 
filter1timeE = %A_YYYY%%A_MM%%A_DD%213000 ; 
beads1timeS  = %A_YYYY%%A_MM%%A_DD%213100 ; 
beads1timeE  = %A_YYYY%%A_MM%%A_DD%213115 ; 
brackettimeS = %A_YYYY%%A_MM%%A_DD%213120 ; 
brackettimeE = %A_YYYY%%A_MM%%A_DD%213420 ; 
beads2timeS  = %A_YYYY%%A_MM%%A_DD%213425 ; 
beads2timeE  = %A_YYYY%%A_MM%%A_DD%213435 ; 
filter2timeS = %A_YYYY%%A_MM%%A_DD%213510 ; 
filter2timeE = %A_YYYY%%A_MM%%A_DD%214000 ; 

; ====================================

; send filtersettings ; set single frame shooting with appropriate fstop and shutter speed 
click 1472, 452 ; set single shot
 SendInput {Down}
 SendInput {Enter}
click 1222, 485 ; set shutter speed to 4000 then down to 500 
 sendInput {PgUp}
 sendInput {Down 9}
 sendInput {Enter}
click 1222, 518 ; set f stop to max then to F5.6
 sendInput {PgUp}
 sendInput {Down 12}
 sendInput {Enter}


gosub, filter1

; remove filters audio warning


; send beadsettings ; set continuous shooting speed to Low with appropriate fstop and shutter speedset beads
click 1472, 452 ; set continuous
 SendInput {Down 2}
 SendInput {Enter}
click 1222, 485 ; set shutter speed to 4000
 sendInput {PgUp}
 sendInput {Enter}

gosub, beads1

; send bracketsettings
click 1472, 452 ; set single shot
 SendInput {Down}
 SendInput {Enter}
click 1222, 485 ; set shutter speed to 1/8 from 4000
 sendInput {Down 27}
 sendInput {Enter}
Click 1452, 491 ; set bracket mode on with 5 shots
 SendInput {Down 2}

gosub, totality

; beads2
; set beads ; set continuous shooting speed to Low with appropriate fstop and shutter speed
Click 1452, 491 ; set bracket mode off
 SendInput {Up 2}
click 1472, 452 ; set continuous
 SendInput {Down 2}
 SendInput {Enter}
click 1222, 485 ; reset shutter speed to 4000 max
 sendInput {PgUp}
 sendInput {Enter}
click 1222, 518 ; set f stop to max then to F5.6
 sendInput {PgUp}
 sendInput {Down 12}
 sendInput {Enter}

gosub, beads2

; apply filters audio warning

;set final filter settings
click 1472, 452 ; set single shot
 SendInput {Down}
 SendInput {Enter}
click 1222, 485 ; set shutter speed to 500 from earlier 4000
 sendInput {down 9}
 sendInput {Enter}

gosub, filter2


; ====================================

; subroutines

; ====================================

filter1:
; this is first to second contact
; send a picture click once a minute
Click 1501, 14 ; click on shutter control window bar to make active
MouseMove 1565, 363 ; position mouse over shutter button

if (A_Now >= filter1timeS)  
 { 
 Loop
  { 
   MouseClick, left, 1565, 363, 1, 10  ; click slowly to ensure shutter register
   sleep 60000 ; wait a minute
   if (A_Now >= filter1timeE)
    break
   if (A_Now < filter1timeE)
    continue
  }
 else
  { 
   Sleep 60000 ; wait a minute
   gosub, filter1 ; go back to the start of the subroutine
  }
 }
return

; ====================================

beads1:
; this is the beads1 subroutine
Click 1501, 14 ; click on shutter control window bar to make active
MouseMove 1565, 363 ; position mouse over shutter button
; press and hold shutter button while beads active
if (A_Now > beads1timeS)
 {
 Loop
  {
   MouseClick, left, 1565, 363, 1, 10, D ; Press and hold shutter button
   if (A_Now >= beads1timeE)
    {
    MouseClick, left, 1563, 363, 1, 10, U ; release shutter button
    Break
    }
   if (A_Now < beads1timeE)
    continue
  }
  else
  { 
   Sleep 1000 ; wait a second
   gosub, beads1 ; go back to the start of the subroutine
  }
 }
return
 
; ====================================

totality:
; this is the subroutine for totality with bracketing
Click 1501, 14
MouseMove 1565, 363
 
if (A_Now > brackettimeS)
 {
 Loop
  {
   MouseClick, left, 1565, 363, 1, 10
   Sleep 3000  ; click every 3 seconds
   if (A_Now >= brackettimeE)
    Break
   If (A_Now < brackettimeE)
    continue
  }
  else
    { 
   Sleep 1000 ; wait a second
   gosub, totality ; go back to the start of the subroutine
  }
 }
return

; ==================================== 
 
beads2:
; this is the second beads routine

Click 1501, 14
MouseMove 1565, 357

if (A_Now > beads2timeS)
 {
 Loop
  {
   MouseClick, left, 1565, 363, 1, 10, D ; Press and hold shutter button
   if (A_Now >= beads2timeE)
    {
    MouseClick, left, 1563, 363, 1, 10, U ; release shutter button
    Break
    }
   if (A_Now < beads2timeE)
    continue
  }
  else
  { 
   Sleep 1000 ; wait a second
   gosub, beads2 ; go back to the start of the subroutine
  }
 }
return

; ====================================
   
filter2:
; this is from 3rd to 4th contact
Click 1501, 14
MouseMove 1565, 357

if (A_Now >= filter2timeS)  
 { 
 Loop
  { 
   MouseClick, left, 1565, 363, 1, 10  ; click slowly to ensure shutter register
   sleep 60000 ; wait a minute
   if (A_Now >= filter2timeE)
    break
   if (A_Now < filter2timeE)
    continue
  }
 else
  { 
   Sleep 1000 ; wait a second
   gosub, filter2 ; go back to the start of the subroutine
  }
 }
return

; ====================================


exit

Tuesday, August 15, 2017

Eclipse Hardware and Software Changes

Last night I needed to test some behavior of the tethering solutions for the cameras to check responsiveness and the duration required for bracketing.  I'm glad that I did this effort because it was quickly apparent that the open-source software for the Pentax cameras is not stable enough to rely on it for the project.

I tried:
  • PK Tether:
    Freezing and unstable when several pictures were in the queue and changing settings on the fly
  • PK Triggercord:
    Was never able to get it running properly because of GTK theme issues
  • Gphoto2:
    Was able to install on Windows, but unable to control the camera via CLI

My fallback method was to install the original tethering software that was developed for the Pentax K10D.  Glad that I have a few of these bodies still functioning!

This changes the selected cameras to the K1 with the 400mm EDIF lens and the K10D with the 300mm lens.  I will continue to use the K5IIs bodies to shoot video and people scenes leading up to and during the eclipse.

The current lens configuration weighs 28 lbs -- right at the limit for the GM8.  I'm going to use this mount because I'm limited for space in the vehicle rather than switch to the G11.

I checked the images from the glass solar filters and was disappointed by the softness.  I've become spoiled by viewing the sun with the Herschel Wedge.  On advice by Anthony DLC, I'm going to cut the Baader film for the cameras and will retire the glass filters eventually.

Tuesday, August 8, 2017

How I plan to shoot the eclipse

I spent some time on the weekend to assemble the cameras into position to check balance and ability to all align to the same point.

Wednesday, July 19, 2017

Eclipse Timing

This is a screenshot from Eclipse Orchestrator software, showing the timing for the eclipse event near Madras, OR, where I will be camping during the event.

Final timing may be off by a second due to location, I expect that the final tweaks will be something I can do after arriving on site.

Monday, July 17, 2017

Eclipse Scripting

Auto Hot Key to the rescue


Because the automated scripting tools for the eclipse are only able to control Canon and Nikon cameras, I have to depend on tethering software for the Pentax camera to control it.

Alas, these software have their own limitations and are not scriptable.

Thus, I'm turning to Auto Hot Key to control the mouse and clicks.

Over the weekend, I was able to get my desktop computer to control the Pentax K1 via the Image Transmitter 2 software and AHK.  I found that a full 5 shot bracket exposure needs 6 seconds to complete.  What's also nice is that I can force the IT2 software to not download the picture, thus saving bandwidth.

Next step is to test the timing controls via this temporary script.



; Get target time in a format we can:
;  - compare (with "<")
; < comparison should be safe as long as both are in the *exact* same format.
; target_time is 2305 format

filter1timeS = %A_YYYY%%A_MM%%A_DD%%target_time ; 11:05 pm
filter1timeE = %A_YYYY%%A_MM%%A_DD%%target_time ; 11:05 pm
beads1timeS = %A_YYYY%%A_MM%%A_DD%%target_time ; 11:05 pm
beads1timeE = %A_YYYY%%A_MM%%A_DD%%target_time ; 11:05 pm
brackettimeS = %A_YYYY%%A_MM%%A_DD%%target_time ; 11:05 pm
brackettimeE = %A_YYYY%%A_MM%%A_DD%%target_time ; 11:05 pm
beads2timeS = %A_YYYY%%A_MM%%A_DD%%target_time ; 11:05 pm
beads2timeE = %A_YYYY%%A_MM%%A_DD%%target_time ; 11:05 pm
filter2timeS = %A_YYYY%%A_MM%%A_DD%%target_time ; 11:05 pm
filter2timeE = %A_YYYY%%A_MM%%A_DD%%target_time ; 11:05 pm


send filtersettings ; set single frame shooting with appropriate fstop and shutter speed
while (A_Now >= filter1timeS and A_Now <= filter1timeE) ; this is first to second contact
{ ; send a picture click once a minute
stuff
}

 ; remove filters audio warning
; beads1
send beadsettings ; set continuous shooting speed to Low with appropriate fstop and shutter speedset beads
while (A_Now >= beads1timeS and A_Now <= beads1timeE) ; this is when first beads goes
{ ; spam beads
click ; at the start
}
click ; at the end, click again to stop the continuous shooting mode


send bracketsettings
while {A_Now >= brackettimeS and A_Now <= brackettimeE) ; this is totality
{ ; spam brackets
click every 6 seconds
}


; beads2
set beads ; set continuous shooting speed to Low with appropriate fstop and shutter speed
while (A_Now >= beads2timeS and A_Now <= beads2timeE) ; this is when second beads goes
{ ; spam beads
click ; at the start
}
click ; at the end, click again to stop the continuous shooting mode


 ; apply filters audio warning

while (A_Now >= filter2timeS and A_Now <= filter2timeE) ; this is 3rd to 4th contact
{ ; send a picture click once a minute
stuff
}



I'll still need to figure out the best time to build in slack to adjust the filters and to run an audio announcement.  I already have the time markers for the contact points, so that's easy to put into the script.   I'll also need to test this on the laptop to ensure that the timing is still correct.

Thursday, July 13, 2017

Calstar 2017 Registration is Open

http://calstar.observers.org/

Go to the Camping and Accommodations page to find the link to register.



Wednesday, July 12, 2017

More pictures of people from GSSP 2017

These are the better black and white pictures.

All shot with the Pentax 67 camera with the 105mm lens.

Monday, July 10, 2017

April MBOSP Gravel Crunching

Back in April, the group got together for pizza and stars.

It was my first time setting the gear up since Calstar.

There were comets, supernovae, and pictures!

Sunday, July 9, 2017

PixInsight Benchmark

So I found out that there is a benchmark for PI.

Here are the numbers from my desktop.

*******************************************************************************
The Official PixInsight Benchmark version 1.0
Copyright (C) 2014-2015 Pleiades Astrophoto. All Rights Reserved.
*******************************************************************************

Benchmark version ...... 1.00.08
Input checksum ......... 2cd72b67e12fff2812ef5b5da054ab2a70a25e23
Serial number .......... 

CPU Identification
CPU vendor ............. AuthenticAMD
CPU model .............. AMD FX(tm)-8350 Eight-Core Processor

System Information
Platform ............... Windows
Operating system ....... Microsoft Windows 7 Ultimate
Core version ........... PixInsight Core 01.08.04.1195 (x64)
Logical processors ..... 8
Total memory size ...... 31.903 GiB

Execution Times
Total time ............. 03:12.77
CPU time ............... 01:19.72
Swap time .............. 01:53.01
Swap transfer rate ..... 146.667 MiB/s

Performance Indices
Total performance ...... 2440
CPU performance ........ 4748
Swap performance ....... 812

Additional Information
Swap disks ............. OCZ Agility 90 GB SSD
Motherboard ............ Asus M5A99FX Pro R2.0
Machine description .... AMD FX 8350 home built

*******************************************************************************


Benchmark has been recorded on 2017/07/08 10:04:13 UTC



Wednesday, June 28, 2017

GSSP 2017 Early Report

The 2017 Golden State Star Party was held from June 21 through June 25 in Adin, CA at the Frosty Acres Ranch.  The T-shirt is themed for the great eclipse, sans cow jokes.

https://www.facebook.com/Golden-State-Star-Party-227209732566/
GSSP on Facebook



Tuesday, June 27, 2017

How to Collimate the ES Mak Newt

A quick video taken at the Golden State Star Party 2017 for the benefit of my niece, Rebecca.





Thanks go to the Explore Scientific rep who was on-site to describe the process for the maksutov newtonian scope.


Thursday, June 1, 2017

Planning targets for GSSP 2017

I finally loaded CCDNavigator and see these targets for GSSP as ordered by transit times.  This is a rough estimate based on Menlo Park coordinates.


I will also shoot Acros, E200, and some panoramic slides.



Friday, May 12, 2017

Watch Comet Johnson Sprint Through Boötes

Watch Comet Johnson Sprint Through Boötes: As other comets fade, Comet Johnson (C/2015 V2) moves into the spotlight. Catch it in binoculars the next moonless night.

Something to look for at GSSP 2017!

MAK-ing a galaxy imager

Creation of a galaxy mini-imaging system.

I purchased this scope to correspond with the Mars opposition of 2004.  It served well as I got started viewing from the driveway and then began to chase after the moon, bright clusters, and other planets.

Later, I put this scope on the shelf in favor of the SV4 refractor.

I have used it for imaging a few times.  Given the focal length, it's still faster than the SV4 with a barlow.

My best picture of M1 came from this scope

M1 Crab Nebula

As well as the best picture of the Siamese Twins 

Siamese Twins Galaxies

And the best picture of the Ring Nebula

M57 13 lights at 10 minutes 400 ISO

And this picture of the Helix

Helix Nebula

And planets, of course.



Since I'm borrowing Carl's 583 camera, I'd been wanting to try this as a galaxy setup.  


A few configuration changes, a resurrected SSAG, cobbled together autofocus system, and some filters gives this current lightweight mini-frankenscope:




Nearly a year ago, I'd gotten an extra HSM motor from Starlight Systems so that I could make the autofocus system.  I've mounted the bracket with high-temperature hot melt glue.  If it works well, then I may swap it for epoxy.  In the meantime, the glue should hold.  Also, I'm not sure if there is enough reduction for the focus knob.  If it turns out to need a bigger pulley on the knob, I'll have to make one.  Bench testing, there's a range of 1k steps for a full turn of the knob.  When I update the firmware on the controller, there should be close to 5k steps for this same range.

I know the drill about a moving mirror and flop and all that jazz.  From what I've seen with this mak, the spring and grease do a good job of holding the mirror cell tightly.  The aluminum body and 3x folded light path is more of a factor with temperature drop.

I've not had the chance to see if the off-axis guider can see starlight.  Unlike the refractor, I can't look down the objective and see the camera.  If this turns out to be a problem, I can put the ST80 and SSAG on the top of the rings, how I used to run this setup with the DSLR.


Next steps:
Solder together some 7.5 ohm .5 watt resistors to make an anti-dew heater.
Wiring harness and cabling.
Flats to check for vignette.
Profile the setup in CCDAutopilot.

... take some images!

Friday, April 28, 2017

Productive at Home


Working on some M106 data.

Gathering Lum and LPS data to compare.

Air seems steady tonight.

Thursday, March 30, 2017

Stargazing at MBOSP with Mr Farrar


Taken on November 2 2016 on a night that started out clear but ended up getting murky and dewy before midnight.

Just a visual night using Rebecca's Comet Catcher on the GM8 for some go-to fun.

Stargazing with Mr Farrar

Spring MBOSP

The first new moon after the vernal equinox was organized by Casey.


It was good to shake the dust off and get the practice of setting up gear, fiddling with small screws in the darkness, and staring at computer screens seeking not-so-squiggly lines.

Cool to see through Andrew's new Obsession.  I think it's safe to say that the scope name fits!

The comet 41p was crazy dim.  Glad to see it, though!

I rolled up two canisters of ancient TriX to muck about.  Will develop them later this week and cross my fingers to see how they turn out!

Main goal for me was to try to get some test frames on a target with the automated SV4 and G11 setup.  I also wanted to replace the ring gear on the GM8, adjust the gear mesh, focus the mini-guider with the replacement SSAG, confirm that guiding works, and try to see if I can find an infinity focus with the 400 mm 67 lens with a yellow filter inside it.  

I did get a few good frames on a familiar target.  Here's a 10 minute Red exposure.