Meridian Flip failure : PHD Did not settle, Additional Text in JSON

SGP v2.4.3.25
PHD v2.5.0dev7
Gemini.NET v 1.0.62.0

Last night’s sequence failed, reporting that the meridian flip failed. Meridian flips have previously been working with this configuration without issue.

  • Plate solve image and Gemini.net screen showed that the mount had completed the flip
  • Logs show that the plate solve and centering process were completed successfully.
  • Following log information shows that the PHD2 Listener Thread reported an error, stating " Additional text encountered after finished reading JSON content: {. Path ‘’, line 1, position 291."
  • After this, SGP timed out waiting for PHD to report it was done settling, and aborted the sequence.

This seems similar, but not identical, to the issue discussed in Problems with running a sequence and Phd2 last night - #10 by Martyk22 - Sequence Generator - Main Sequence Software

Log file may be found at : http://files.stuffupthere.com/sg_logfile_20160325194816.txt

What I believe to be the pertinent lines begin at line 14703, at 1:00:49 AM 3/26/2016. The error line itself is quoted below for quick reference.

[3/26/2016 1:01:12 AM] [DEBUG] [PHD2 Listener Thread] Could not process PHD2 input: “{“Event”:“GuideStep”,“Timestamp”:1458972072.122,“Host”:“ASTROLAP”,“Inst”:1,“Frame”:2,“Time”:9.010,“Mount”:“Gemini Telescope .NET”,“dx”:-0.006,“dy”:-0.069,“RADistanceRaw”:0.066,“DECDistanceRaw”:0.021,“RADistanceGuide”:0.000,“DECDistanceGuide”:0.000,“StarMass”:1469,“SNR”:11.93,“AvgDist”:0.21}{“Event”:“SettleDone”,“Timestamp”:1458972072.122,“Host”:“ASTROLAP”,“Inst”:1,“Status”:0}” : Additional text encountered after finished reading JSON content: {. Path ‘’, line 1, position 291.

IMO, it is worth noting that at position 291 we do indeed see }{ as one JSON string is closed, and another opened, the second being

{“Event”:“SettleDone”,“Timestamp”:1458972072.122,“Host”:“ASTROLAP”,“Inst”:1,“Status”:0}

It LOOKS like SGP tried to send (or PHD interpreted a string as an attempt to send) 2 JSON event strings, but admittedly my JSON-fu is pretty damn weak, so I’m just spitballing.

Any thoughts?

Admittedly my memory is not super great when it comes to this stuff, so I’ll say a couple things and maybe @Andy has other insight:

  • PHD2 is allowed to send us multiple messages at one time (or at least we are allowed to read them that way as they stream to us)
  • The problem here is that SGPro expects each object to be separated by a delimiter and not run together one after the other
  • Your version of PHD2 is behind, and if this was ever a PHD2 issue it might have been addressed

I pulled this straight for you logs. There is no delimiter between objects here:

That’s right, there was an issue in older versions of PHD2 that could cause that.

Andy

Ken,

Yep, that’s pretty much what I saw as I mentioned above. I wasn’t aware that SGP/PHD could handle multiple messages at a time, but either way the }{ lacks a delimter, so the “Additional text” error makes sense.

Andy,

So that confirms then that updating PHD should resolve this. I had, to be brutally honest, been reluctant to touch it since, of late, I’ve been getting some great results and had trouble-free operation…well…you know…until now. lol

Thanks much, gentlemen, for the info. I’ll update PHD, and monitor for a repeat of the issue.