Pempro Polar Align Wizard and SGP Issue


I don’t fully understand what’s going on here so bear with me…

Mount: Mach1GTO
Camera: Moravian Instruments G3-16200
Note that all my equipment operates as expected in SGP under normal imaging conditions.

I’m trying to use Pempro’s Polar Align Wizard with SGP and there appears to be an issue on the SGP side of things. The camera and mount connect fine through Pempro and SGP. I get to the step in Pempro where Pempro attempts to loop exposures so that the polar misalignment can be measured, but the exposures never download from SGP. As such nothing is displayed in Pempro to measure.

I started troubleshooting this with Ray Gralak and this is what he said:
“I can’t say what the problem is either but PEMpro cannot guess when an image is done. It requires SGPro to indicate that it is done when asked. You can look at the log and see what happened. The SGpro APi mechanism is separate from camera control so that is maybe that is the source of the issue. I’ll keep an eye out on the SGPro forum and join in if needed.”

Here is the PEMPRO log.
Here is the SGP log.

There are several errors in the SGP log that have to do with the API but I don’t know what it means.


I see the error… something to do with an error getting data for the FITS header. That said, what is the observed behavior? It also looks like an image is downloaded off the camera fine too. Just curious what you are actually seeing on the SGPro user interface and the PEMPro interface.


Here are 2 screenshots from Pempro and SGP:


On the pempro screenshot it should be showing a plot for each image downloaded, but over about 10min nothing happened. SGP is supposed to be looping images (subframes) but I didn’t see any change to the displayed star image.


Hi Ken,

The problem is that after PEMPro starts an image capture PEMPro loops querying for an image complete status, but SGPro keeps returning the “Capturing” state for many minutes.



I have to say that I found PemPro and SGP didn’t play nicely at all, and soon gave up - It was as flaky as anything. I kept getting that API call complete stuff and no image.


That’s weird. It works great on my system. I did need to add in a pause between images (shoot 1 second exposures and delay of 2 seconds) otherwise SGP would get saturated.


I think it is probably camera-specific or maybe situation-specific (i.e. the “error getting data for the FITS header” that Ken mentioned).



One more reason to love my SBIG :).

Thanks Ray!


Yeah, Pempro V3 beta and SGP worked just fine with my previous SX694 camera.


I have a AstroPhysics mount I have been trying to map about 5 to 6 worm cycles in PEMProto improve (smooth out) the tracking.
Everything goes fine until at some random time between two and four cycles I get a pop up message: Camera busy (everything stops). Or. The Windows message: SQpro has stopped working and will close the program. Neither message can be overridden and when the program closes all the information that has been gathered is lost.
As you can imagine this is a bit frustrating as there could be 20 to 30 min. of information lost each time I try, and it has never completed all the required cycles.
The problem seems to be similar to the long discussion here, back in January, with crashes during calibration acquisition. However that seemed to be sorted out. I have tried one of the fixes that was used at that time i.e. delaying the time between each exposure by 2 sec. The subframes (1sec.) are quite small 100x100. Bin 1x1. Camera SXVR-H694.
I do not have the logs as this all happened couple of weeks ago and I just gave up trying. But this seems to link in to this ongoing discussion.
Thanks. Adrian



.[quote=“adrian, post:11, topic:4184”]
Neither message can be overridden and when the program closes all the information that has been gathered is lost.
Sorry, but that is incorrect. PEMPro always saves to disk after each write to the log file in case there is ever a crash. I suspect that SGPro does something similar.

In PEMPro’s case, there are two log files: the log file with all of the data points collected up until that point, and another log file with low-level debug information. They will never get deleted by PEMPro so if you can locate them and attach them here or on the CCDWare/PEMPro forum, I will try to determine what happened.



Hi Ray
Thanks for getting back to me.
I found one of the Logs and have sent it through DropBox. I could not find the other, so I included a couple of screen shots, The start and end of the run. Don’t spend too much time on this as it is obvious I am doing something really daft. But I would appreciate it if you could point me in the right direction.
Thanks. Adrian


Hi Adrian,

The log(s) I really need to see are in the “Logs” subdirectory relative to where you found that log. The logs have “Debug” in the filename, like this example: “PEMProV3-Debug-2016-09-18-203445.log”. The log you posted contains the data points that were captured.



Hi Ray.

Hopefully this is the one you need.

Regards. Adrian



Shared with Dropbox


Hi Adrian,

It looks like the server connection to SGPro was lost. I’m not really sure why that would happen but PEMPro recovered about 8 minutes later on its own. Do you recall seeing anything unusual happening on SGPro’s user interface?

0106388 2016-08-26 22:01:27.869: Debug, SgProCam, Sending: http://localhost:59590/json/reply/SgGetImagePath, Params: {“Receipt”:“22eecf39e0a247dd8a3907fbb29954fe”}
0106389 2016-08-26 22:02:35.578: Exception, SgGetImagePath, The underlying connection was closed: A connection that was expected to be kept alive was closed by the server.
0106390 2016-08-26 22:02:37.811: Debug, Start Exposure, Binning = 1, Duration= 1, Light = 1
0106391 2016-08-26 22:02:37.812: Debug, SgProCam, Sending: http://localhost:59590/json/reply/SgCaptureImage, Params: {“BinningMode”:1,“IsoMode”:0,“ExposureLength”:1,“Gain”:"",“Speed”:“Normal”,“FrameType”:“Light”,“Path”:“C:\Users\ADRIAN LIDDELL\Desktop\Documents\CCDWare\PEMProV3\SGProImage”,“UseSubframe”:true,“X”:1950,“Y”:1860,“Width”:100,“Height”:100}
0106392 2016-08-26 22:02:39.860: Exception, SgCaptureImage, Unable to connect to the remote server
0106393 2016-08-26 22:02:39.863: Exception, Start Exposure, Take Image Failed: Object reference not set to an instance of an object.
0106394 2016-08-26 22:10:45.890: Debug, SgProCam, Sending: http://localhost:59590/json/reply/SgCaptureImage, Params: {“BinningMode”:1,“IsoMode”:0,“ExposureLength”:21,“Gain”:"",“Speed”:“Normal”,“FrameType”:“Light”,“Path”:“C:\Users\ADRIAN LIDDELL\Desktop\Documents\CCDWare\PEMProV3\SGProImage”,“UseSubframe”:false,“X”:0,“Y”:0,“Width”:2750,“Height”:2200}
0106395 2016-08-26 22:10:46.448: Debug, SgProCam, Response: {“Success”:true,“Message”:“Image capture started successfully.”,“Receipt”:“ef5854086cc242459accf1e70fe284da”}



That’s what it would look like if SGPro was restarted while PEMPro was running. @adrian Did that happen by chance?


Not in my case. I started SGP and connected the camera. Then started PEMPro and connected the camera.



Can you get this issues to show itself pretty reliably? If so, I’d like to get you a special version of SGPro with better API trace logging so I can see what kind of capture request is causing SGPro to throw up in PEMPro’s face.


Yes, it happens every time. The problem is very “reliable” :wink: