arduino ST4

229 views
Skip to first unread message

Iaroslav-Andrei Hapenciuc

unread,
Mar 3, 2017, 7:59:18 AM3/3/17
to Open PHD Guiding
Hi

I am trying to port FW from arduino to PIC for the "Adruino ST4 ASCOM guider".
For some reason I do not receive the "DISCONNECT" string on serial line when disconnecting (or no matter what I am doing)??? Leaving my HW in a false connected state.

There is a special setting I need to so somewhere?

In Carte Du Ciel, "connect" and "disconnect" buttons are working well, but I use PHD2 for guiding.

Thank you

Andrei

Andy Galasso

unread,
Mar 3, 2017, 3:32:21 PM3/3/17
to Open PHD Guiding
Hello Andrei,

I do not think we have enough information or context to help you with your problem.  For example: what is the mount selection in PHD2 for your device?  Is it an ASCOM device?  If so, then it's up to the ASCOM driver to manage what happens on the serial line, although PHD2 will set the ASCOM Connected property to false when phd2 disconnects from the mount.

Andy

Iaroslav-Andrei Hapenciuc

unread,
Mar 4, 2017, 8:39:11 AM3/4/17
to Open PHD Guiding

Hi Andy,

For the mount I use "ArduinoST4 telescope driver (ASCOM)".
I am doing a different hardware and FW using PIC micro.

When I click "connect all" my hardware detect the "CONNECTED#" string.
But when I click "disconnect all" I (think?) I  should receive "DISCONNECTED#" string on serial line (virtual serial port). neider the PIC of my logic analizer are detecting it. This makes my HW to think is connected, at a second "connect all" I get an error and fail.



I tried the "ArduinoST4 telescope driver (ASCOM)" in Carte du Ciel and the "connect" - "disconnect" buttons both work well,,

Best Regards,

Andrei

Andy Galasso

unread,
Mar 4, 2017, 2:15:07 PM3/4/17
to Open PHD Guiding
Hi Andrei,

Thanks for the additional information. I believe the answer to your question is in this discussion thread.

The bottom line is that your driver needs to cleanup (send DISCONNECT on the serial line) when the last COM reference is released in order to handle the case of a client exiting unexpectedly (consider the case of a client being terminated by Task Manager). PHD2 releases its COM reference when you click Disconnect.

Andy

Reply all
Reply to author
Forward
0 new messages