Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Infer from AUX command 0x05 the mount model #742

Merged
merged 1 commit into from Feb 26, 2023

Conversation

tstibor
Copy link
Contributor

@tstibor tstibor commented Feb 24, 2023

Send to AUX device 0x10 (AZM motor controller) the command 0x05 (MC_GET_MODEL) to get reply which contains the mount model version string.

The command is derived from Celestron AUXBUS Scanner https://github.com/platini2/celestronauxbus
currently the following mount versions can be inferred:

0x0001 : 'Nexstar GPS',
0x0783 : 'Nexstar SLT',
0x0b83 : '4/5SE',
0x0c82 : '6/8SE',
0x1189 : 'CPC Deluxe',
0x1283 : 'GT Series',
0x1485 : 'AVX',
0x1687 : 'Nexstar Evolution',
0x1788 : 'CGX'

In a later commit the inferred mount model can be used to properly determined whether it a a GEM, AZ_ALT or FORK mount.

Send to AUX device 0x10 (AZM motor controller) the command
0x05 (MC_GET_MODEL) to get reply which contains the mount model
version string.

The command is derived from Celestron AUXBUS Scanner
https://github.com/platini2/celestronauxbus
currently the following mount versions can be inferred:

0x0001 : 'Nexstar GPS',
0x0783 : 'Nexstar SLT',
0x0b83 : '4/5SE',
0x0c82 : '6/8SE',
0x1189 : 'CPC Deluxe',
0x1283 : 'GT Series',
0x1485 : 'AVX',
0x1687 : 'Nexstar Evolution',
0x1788 : 'CGX'

In a later commit the inferred mount model can be used to properly
determined whether it a a GEM, AZ_ALT or FORK mount.
@knro
Copy link
Collaborator

knro commented Feb 25, 2023

Thank you. This is indeed a step in the right direction. Btw, are you using this driver with your Celestron mount? If yes, which model do you have?

@tstibor
Copy link
Contributor Author

tstibor commented Feb 25, 2023

Yes, I am using the driver with my Celestron AVX mount. The mount replies for AUX command 0x05 to the AZ motor
with reply (uint16_t): 0x1485

I wrote a post on the INDI Forum:
On Celestron AVX and INDI Celestron AUX Driver about the usage.

@tstibor
Copy link
Contributor Author

tstibor commented Feb 25, 2023

In the Celestron AUXBUS Scanner Python Code are a great deal of additional AUX commands documented, e.g.
setting/getting user limit: https://github.com/platini2/celestronauxbus/blob/5c395e66e80b76d6d0a6274b06e9e9e1831a7c1c/celestron.py#L133
any many more commands.

@knro
Copy link
Collaborator

knro commented Feb 25, 2023

Have you tried guiding on your mount? It appears that MC_GUIDE commands have no effect and the encoders remain the same?

@tstibor
Copy link
Contributor Author

tstibor commented Feb 25, 2023

I haven't tried it, but will try today and report back.

@tstibor
Copy link
Contributor Author

tstibor commented Feb 25, 2023

Do you mean the AUX command: MC_GET/SET_AUTOGUIDE_RATE?
I dumped the communication from indi celestron AUX driver to my USBAUX Relay MCU (connected via AUX port to Celestron AUX mount).

[00037389ms,usb] INDI Celestron AUX -> AZM MC, cmd MTR_GET_VERSION: AUX packet <0x3b, 0x03, 0x20, 0x10, 0xfe, 0xcf> (checksum 0xcf)
[00037561ms,aux] AZM MC -> INDI Celestron AUX, cmd NXS_GET_FW_VER: AUX packet <0x3b, 0x07, 0x10, 0x20, 0xfe, (0x07 0x0f 0x20 0x4e), 0x47> (checksum 0x47)
[00037665ms,usb] INDI Celestron AUX -> ALT MC, cmd MTR_GET_VERSION: AUX packet <0x3b, 0x03, 0x20, 0x11, 0xfe, 0xce> (checksum 0xce)
[00037836ms,aux] ALT MC -> INDI Celestron AUX, cmd NXS_GET_FW_VER: AUX packet <0x3b, 0x07, 0x11, 0x20, 0xfe, (0x07 0x0f 0x20 0x4e), 0x46> (checksum 0x46)
[00037940ms,usb] INDI Celestron AUX -> AZM MC, cmd MTR_GET_AUTOGUIDE_RATE: AUX packet <0x3b, 0x03, 0x20, 0x10, 0x47, 0x86> (checksum 0x86)
[00038085ms,aux] AZM MC -> INDI Celestron AUX, cmd MTR_GET_AUTOGUIDE_RATE: AUX packet <0x3b, 0x04, 0x10, 0x20, 0x47, (0x80), 0x05> (checksum 0x05)
[00038185ms,usb] INDI Celestron AUX -> ALT MC, cmd MTR_GET_AUTOGUIDE_RATE: AUX packet <0x3b, 0x03, 0x20, 0x11, 0x47, 0x85> (checksum 0x85)
[00038331ms,aux] ALT MC -> INDI Celestron AUX, cmd MTR_GET_AUTOGUIDE_RATE: AUX packet <0x3b, 0x04, 0x11, 0x20, 0x47, (0x80), 0x04> (checksum 0x04)
[00038432ms,usb] INDI Celestron AUX -> AZM MC, cmd MTR_IS_CORDWRAP_ON: AUX packet <0x3b, 0x03, 0x20, 0x10, 0x3b, 0x92> (checksum 0x92)
[00038575ms,aux] AZM MC -> INDI Celestron AUX, cmd MTR_IS_CORDWRAP_ON: AUX packet <0x3b, 0x04, 0x10, 0x20, 0x3b, (0x00), 0x91> (checksum 0x91)
[00038673ms,usb] INDI Celestron AUX -> AZM MC, cmd MTR_GET_CORDWRAP_POSITION: AUX packet <0x3b, 0x03, 0x20, 0x10, 0x3c, 0x91> (checksum 0x91)
[00038840ms,aux] AZM MC -> INDI Celestron AUX, cmd MTR_GET_CORDWRAP_POSITION: AUX packet <0x3b, 0x06, 0x10, 0x20, 0x3c, (0x00 0x00 0x00), 0x8e> (checksum 0x8e)
[00038947ms,usb] INDI Celestron AUX -> AZM MC, cmd MTR_GET_MODEL: AUX packet <0x3b, 0x03, 0x20, 0x10, 0x05, 0xc8> (checksum 0xc8)
[00039097ms,aux] AZM MC -> INDI Celestron AUX, cmd MTR_GET_MODEL: AUX packet <0x3b, 0x05, 0x10, 0x20, 0x05, (0x14 0x85), 0x2d> (checksum 0x2d)
[00039195ms,usb] INDI Celestron AUX -> Main Board, cmd MB_GET_FW_VER: AUX packet <0x3b, 0x03, 0x20, 0x01, 0xfe, 0xde> (checksum 0xde)
[00040290ms,usb] INDI Celestron AUX -> Nexstar HC, cmd NXS_GET_FW_VER: AUX packet <0x3b, 0x03, 0x20, 0x04, 0xfe, 0xdb> (checksum 0xdb)
[00041386ms,usb] INDI Celestron AUX -> Nexstar+ HC, cmd NXS_GET_FW_VER: AUX packet <0x3b, 0x03, 0x20, 0x0d, 0xfe, 0xd2> (checksum 0xd2)
[00042482ms,usb] INDI Celestron AUX -> AZM MC, cmd MTR_GET_VERSION: AUX packet <0x3b, 0x03, 0x20, 0x10, 0xfe, 0xcf> (checksum 0xcf)
[00042653ms,aux] AZM MC -> INDI Celestron AUX, cmd NXS_GET_FW_VER: AUX packet <0x3b, 0x07, 0x10, 0x20, 0xfe, (0x07 0x0f 0x20 0x4e), 0x47> (checksum 0x47)
[00042757ms,usb] INDI Celestron AUX -> ALT MC, cmd MTR_GET_VERSION: AUX packet <0x3b, 0x03, 0x20, 0x11, 0xfe, 0xce> (checksum 0xce)
[00042928ms,aux] ALT MC -> INDI Celestron AUX, cmd NXS_GET_FW_VER: AUX packet <0x3b, 0x07, 0x11, 0x20, 0xfe, (0x07 0x0f 0x20 0x4e), 0x46> (checksum 0x46)
[00043032ms,usb] INDI Celestron AUX -> GPS, cmd GPS_GET_FW_VER: AUX packet <0x3b, 0x03, 0x20, 0xb0, 0xfe, 0x2f> (checksum 0x2f)
[00044124ms,usb] INDI Celestron AUX -> Nexstar EVO WiFi, cmd WIFI_GET_FW_VER: AUX packet <0x3b, 0x03, 0x20, 0xb5, 0xfe, 0x2a> (checksum 0x2a)
[00045223ms,usb] INDI Celestron AUX -> Battery Power Cont, cmd BAT_GET_FW_VER: AUX packet <0x3b, 0x03, 0x20, 0xb6, 0xfe, 0x29> (checksum 0x29)
[00046327ms,usb] INDI Celestron AUX -> AZM MC, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x03, 0x20, 0x10, 0x01, 0xcc> (checksum 0xcc)
[00046489ms,aux] AZM MC -> INDI Celestron AUX, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x06, 0x10, 0x20, 0x01, (0x00 0x00 0x01), 0xc8> (checksum 0xc8)
[00046591ms,usb] INDI Celestron AUX -> ALT MC, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x03, 0x20, 0x11, 0x01, 0xcb> (checksum 0xcb)
[00046753ms,aux] ALT MC -> INDI Celestron AUX, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x06, 0x11, 0x20, 0x01, (0xff 0xff 0xff), 0xcb> (checksum 0xcb)
[00047861ms,usb] INDI Celestron AUX -> AZM MC, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x03, 0x20, 0x10, 0x01, 0xcc> (checksum 0xcc)
[00048023ms,aux] AZM MC -> INDI Celestron AUX, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x06, 0x10, 0x20, 0x01, (0x00 0x00 0x01), 0xc8> (checksum 0xc8)
[00048125ms,usb] INDI Celestron AUX -> ALT MC, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x03, 0x20, 0x11, 0x01, 0xcb> (checksum 0xcb)
[00048287ms,aux] ALT MC -> INDI Celestron AUX, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x06, 0x11, 0x20, 0x01, (0xff 0xff 0xff), 0xcb> (checksum 0xcb)
[00049391ms,usb] INDI Celestron AUX -> AZM MC, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x03, 0x20, 0x10, 0x01, 0xcc> (checksum 0xcc)
[00049553ms,aux] AZM MC -> INDI Celestron AUX, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x06, 0x10, 0x20, 0x01, (0x00 0x00 0x01), 0xc8> (checksum 0xc8)
[00049655ms,usb] INDI Celestron AUX -> ALT MC, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x03, 0x20, 0x11, 0x01, 0xcb> (checksum 0xcb)
[00049817ms,aux] ALT MC -> INDI Celestron AUX, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x06, 0x11, 0x20, 0x01, (0xff 0xff 0xff), 0xcb> (checksum 0xcb)
[00050921ms,usb] INDI Celestron AUX -> AZM MC, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x03, 0x20, 0x10, 0x01, 0xcc> (checksum 0xcc)
[00051083ms,aux] AZM MC -> INDI Celestron AUX, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x06, 0x10, 0x20, 0x01, (0x00 0x00 0x01), 0xc8> (checksum 0xc8)
[00051185ms,usb] INDI Celestron AUX -> ALT MC, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x03, 0x20, 0x11, 0x01, 0xcb> (checksum 0xcb)
[00051348ms,aux] ALT MC -> INDI Celestron AUX, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x06, 0x11, 0x20, 0x01, (0xff 0xff 0xff), 0xcb> (checksum 0xcb)
[00052451ms,usb] INDI Celestron AUX -> AZM MC, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x03, 0x20, 0x10, 0x01, 0xcc> (checksum 0xcc)
[00052613ms,aux] AZM MC -> INDI Celestron AUX, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x06, 0x10, 0x20, 0x01, (0x00 0x00 0x01), 0xc8> (checksum 0xc8)
[00052715ms,usb] INDI Celestron AUX -> ALT MC, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x03, 0x20, 0x11, 0x01, 0xcb> (checksum 0xcb)
[00052877ms,aux] ALT MC -> INDI Celestron AUX, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x06, 0x11, 0x20, 0x01, (0xff 0xff 0xff), 0xcb> (checksum 0xcb)
[00053981ms,usb] INDI Celestron AUX -> AZM MC, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x03, 0x20, 0x10, 0x01, 0xcc> (checksum 0xcc)
[00054143ms,aux] AZM MC -> INDI Celestron AUX, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x06, 0x10, 0x20, 0x01, (0x00 0x00 0x01), 0xc8> (checksum 0xc8)
[00054245ms,usb] INDI Celestron AUX -> ALT MC, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x03, 0x20, 0x11, 0x01, 0xcb> (checksum 0xcb)
[00054407ms,aux] ALT MC -> INDI Celestron AUX, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x06, 0x11, 0x20, 0x01, (0xff 0xff 0xff), 0xcb> (checksum 0xcb)
[00055511ms,usb] INDI Celestron AUX -> AZM MC, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x03, 0x20, 0x10, 0x01, 0xcc> (checksum 0xcc)
[00055673ms,aux] AZM MC -> INDI Celestron AUX, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x06, 0x10, 0x20, 0x01, (0x00 0x00 0x01), 0xc8> (checksum 0xc8)
[00055775ms,usb] INDI Celestron AUX -> ALT MC, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x03, 0x20, 0x11, 0x01, 0xcb> (checksum 0xcb)
[00055937ms,aux] ALT MC -> INDI Celestron AUX, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x06, 0x11, 0x20, 0x01, (0xff 0xff 0xff), 0xcb> (checksum 0xcb)
[00057042ms,usb] INDI Celestron AUX -> AZM MC, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x03, 0x20, 0x10, 0x01, 0xcc> (checksum 0xcc)
[00057204ms,aux] AZM MC -> INDI Celestron AUX, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x06, 0x10, 0x20, 0x01, (0x00 0x00 0x01), 0xc8> (checksum 0xc8)
[00057306ms,usb] INDI Celestron AUX -> ALT MC, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x03, 0x20, 0x11, 0x01, 0xcb> (checksum 0xcb)
[00057468ms,aux] ALT MC -> INDI Celestron AUX, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x06, 0x11, 0x20, 0x01, (0xff 0xff 0xff), 0xcb> (checksum 0xcb)
[00058572ms,usb] INDI Celestron AUX -> AZM MC, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x03, 0x20, 0x10, 0x01, 0xcc> (checksum 0xcc)
[00058734ms,aux] AZM MC -> INDI Celestron AUX, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x06, 0x10, 0x20, 0x01, (0x00 0x00 0x01), 0xc8> (checksum 0xc8)
[00058836ms,usb] INDI Celestron AUX -> ALT MC, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x03, 0x20, 0x11, 0x01, 0xcb> (checksum 0xcb)
[00058998ms,aux] ALT MC -> INDI Celestron AUX, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x06, 0x11, 0x20, 0x01, (0xff 0xff 0xff), 0xcb> (checksum 0xcb)
[00059933ms,usb] INDI Celestron AUX -> AZM MC, cmd MTR_SET_AUTOGUIDE_RATE: AUX packet <0x3b, 0x04, 0x20, 0x10, 0x46, (0x33), 0x53> (checksum 0x53)
[00060013ms,usb] INDI Celestron AUX -> ALT MC, cmd MTR_SET_AUTOGUIDE_RATE: AUX packet <0x3b, 0x04, 0x20, 0x11, 0x46, (0xcc), 0xb9> (checksum 0xb9)
[00060152ms,aux] AZM MC -> INDI Celestron AUX, cmd MTR_SET_AUTOGUIDE_RATE: AUX packet <0x3b, 0x03, 0x10, 0x20, 0x46, 0x87> (checksum 0x87)
[00060287ms,aux] ALT MC -> INDI Celestron AUX, cmd MTR_SET_AUTOGUIDE_RATE: AUX packet <0x3b, 0x03, 0x11, 0x20, 0x46, 0x86> (checksum 0x86)
[00060382ms,usb] INDI Celestron AUX -> AZM MC, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x03, 0x20, 0x10, 0x01, 0xcc> (checksum 0xcc)
[00060453ms,usb] INDI Celestron AUX -> ALT MC, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x03, 0x20, 0x11, 0x01, 0xcb> (checksum 0xcb)
[00060615ms,aux] AZM MC -> INDI Celestron AUX, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x06, 0x10, 0x20, 0x01, (0x00 0x00 0x01), 0xc8> (checksum 0xc8)
[00061720ms,usb] INDI Celestron AUX -> AZM MC, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x03, 0x20, 0x10, 0x01, 0xcc> (checksum 0xcc)
[00062814ms,usb] INDI Celestron AUX -> ALT MC, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x03, 0x20, 0x11, 0x01, 0xcb> (checksum 0xcb)
[00062976ms,aux] ALT MC -> INDI Celestron AUX, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x06, 0x11, 0x20, 0x01, (0xff 0xff 0xff), 0xcb> (checksum 0xcb)
[00064080ms,usb] INDI Celestron AUX -> AZM MC, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x03, 0x20, 0x10, 0x01, 0xcc> (checksum 0xcc)
[00064242ms,aux] AZM MC -> INDI Celestron AUX, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x06, 0x10, 0x20, 0x01, (0x00 0x00 0x01), 0xc8> (checksum 0xc8)
[00064344ms,usb] INDI Celestron AUX -> ALT MC, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x03, 0x20, 0x11, 0x01, 0xcb> (checksum 0xcb)
[00064506ms,aux] ALT MC -> INDI Celestron AUX, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x06, 0x11, 0x20, 0x01, (0xff 0xff 0xff), 0xcb> (checksum 0xcb)
[00065610ms,usb] INDI Celestron AUX -> AZM MC, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x03, 0x20, 0x10, 0x01, 0xcc> (checksum 0xcc)
[00065772ms,aux] AZM MC -> INDI Celestron AUX, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x06, 0x10, 0x20, 0x01, (0x00 0x00 0x01), 0xc8> (checksum 0xc8)
[00065874ms,usb] INDI Celestron AUX -> ALT MC, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x03, 0x20, 0x11, 0x01, 0xcb> (checksum 0xcb)
[00066036ms,aux] ALT MC -> INDI Celestron AUX, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x06, 0x11, 0x20, 0x01, (0xff 0xff 0xff), 0xcb> (checksum 0xcb)

I set the Guiding Rate W/E to 0.2 (HEX: 0x33 = DEC: 51, 51/256 $\approx$ 0.2) and N/S to 0.8 (HEX: 0xCC = DEC:204, 204/256 $\approx$ 0.8) and can see how the AUX packet is correctly sent to AVX mount:

[00059933ms,usb] INDI Celestron AUX -> AZM MC, cmd MTR_SET_AUTOGUIDE_RATE: AUX packet <0x3b, 0x04, 0x20, 0x10, 0x46, (0x33), 0x53> (checksum 0x53)
[00060013ms,usb] INDI Celestron AUX -> ALT MC, cmd MTR_SET_AUTOGUIDE_RATE: AUX packet <0x3b, 0x04, 0x20, 0x11, 0x46, (0xcc), 0xb9> (checksum 0xb9)
[00060152ms,aux] AZM MC -> INDI Celestron AUX, cmd MTR_SET_AUTOGUIDE_RATE: AUX packet <0x3b, 0x03, 0x10, 0x20, 0x46, 0x87> (checksum 0x87)
[00060287ms,aux] ALT MC -> INDI Celestron AUX, cmd MTR_SET_AUTOGUIDE_RATE: AUX packet <0x3b, 0x03, 0x11, 0x20, 0x46, 0x86> (checksum 0x86)

After terminating the indiserver and restarting it again, I can see that the command MTR_GET_AUTOGUIDE_RATE is issued and correctly read:

[00513453ms,usb] INDI Celestron AUX -> AZM MC, cmd MTR_GET_VERSION: AUX packet <0x3b, 0x03, 0x20, 0x10, 0xfe, 0xcf> (checksum 0xcf)
[00513624ms,aux] AZM MC -> INDI Celestron AUX, cmd NXS_GET_FW_VER: AUX packet <0x3b, 0x07, 0x10, 0x20, 0xfe, (0x07 0x0f 0x20 0x4e), 0x47> (checksum 0x47)
[00513728ms,usb] INDI Celestron AUX -> ALT MC, cmd MTR_GET_VERSION: AUX packet <0x3b, 0x03, 0x20, 0x11, 0xfe, 0xce> (checksum 0xce)
[00513899ms,aux] ALT MC -> INDI Celestron AUX, cmd NXS_GET_FW_VER: AUX packet <0x3b, 0x07, 0x11, 0x20, 0xfe, (0x07 0x0f 0x20 0x4e), 0x46> (checksum 0x46)
[00514003ms,usb] INDI Celestron AUX -> AZM MC, cmd MTR_GET_AUTOGUIDE_RATE: AUX packet <0x3b, 0x03, 0x20, 0x10, 0x47, 0x86> (checksum 0x86)
[00514148ms,aux] AZM MC -> INDI Celestron AUX, cmd MTR_GET_AUTOGUIDE_RATE: AUX packet <0x3b, 0x04, 0x10, 0x20, 0x47, (0x33), 0x52> (checksum 0x52)
[00514248ms,usb] INDI Celestron AUX -> ALT MC, cmd MTR_GET_AUTOGUIDE_RATE: AUX packet <0x3b, 0x03, 0x20, 0x11, 0x47, 0x85> (checksum 0x85)
[00514394ms,aux] ALT MC -> INDI Celestron AUX, cmd MTR_GET_AUTOGUIDE_RATE: AUX packet <0x3b, 0x04, 0x11, 0x20, 0x47, (0xcc), 0xb8> (checksum 0xb8)

@knro
Copy link
Collaborator

knro commented Feb 25, 2023

Thanks, this is useful as well, but I meant the actual guide pulses MC_AUX_GUIDE, not the rate. The issue I saw is that regardless of how long the pulses are sent, the encoder position remains the same in the logs which indicates no motion at all from the pulses. Is this what you see or does it move a bit with pulses as expected?

@tstibor
Copy link
Contributor Author

tstibor commented Feb 26, 2023

Ok I see. I just checked it, sending guide impulse does not show any MC_AUX_GUIDE packets.
I checked it in the celestron AUX code and the problem is the detection:

    int configMountType = ALT_AZ;
    IUGetConfigOnSwitchIndex(getDeviceName(), "MOUNT_TYPE", &configMountType);
    m_MountType = static_cast<MountType>(configMountType);

    // Detect Equatorial Mounts
    if (strstr(getDeviceName(), "CGX") ||
            strstr(getDeviceName(), "CGEM") ||
            strstr(getDeviceName(), "Advanced VX") ||
            strstr(getDeviceName(), "Wedge"))
    {
        // Force equatorial for such mounts
        m_MountType = EQ_GEM;
        if (strstr(getDeviceName(), "Wedge") != nullptr)
            m_MountType = EQ_FORK;
    }

When forcing in bool CelestronAUX::guidePulse(INDI_EQ_AXIS axis, uint32_t ms, int8_t rate)


// For Equatorial mounts, use regular guiding.
    if (1 == 1)
    {
        uint8_t ticks = std::min(255u, ms / 10);
        AUXBuffer data(2);
        data[0] = rate;
        data[1] = ticks;
        AUXCommand cmd(MC_AUX_GUIDE, APP, axis == AXIS_DE ? ALT : AZM, data);
        if (axis == AXIS_DE)
            m_GuideDETimer.start(ticks * 10);
        else
            m_GuideRATimer.start(ticks * 10);
        return sendAUXCommand(cmd);
    }

It works and I see the following AUX packets:


[00123927ms,usb] INDI Celestron AUX -> AZM MC, cmd MTR_GET_VERSION: AUX packet <0x3b, 0x03, 0x20, 0x10, 0xfe, 0xcf> (checksum 0xcf)
[00124099ms,aux] AZM MC -> INDI Celestron AUX, cmd NXS_GET_FW_VER: AUX packet <0x3b, 0x07, 0x10, 0x20, 0xfe, (0x07 0x0f 0x20 0x4e), 0x47> (checksum 0x47)
[00124203ms,usb] INDI Celestron AUX -> ALT MC, cmd MTR_GET_VERSION: AUX packet <0x3b, 0x03, 0x20, 0x11, 0xfe, 0xce> (checksum 0xce)
[00124374ms,aux] ALT MC -> INDI Celestron AUX, cmd NXS_GET_FW_VER: AUX packet <0x3b, 0x07, 0x11, 0x20, 0xfe, (0x07 0x0f 0x20 0x4e), 0x46> (checksum 0x46)
[00124478ms,usb] INDI Celestron AUX -> AZM MC, cmd MTR_GET_AUTOGUIDE_RATE: AUX packet <0x3b, 0x03, 0x20, 0x10, 0x47, 0x86> (checksum 0x86)
[00124623ms,aux] AZM MC -> INDI Celestron AUX, cmd MTR_GET_AUTOGUIDE_RATE: AUX packet <0x3b, 0x04, 0x10, 0x20, 0x47, (0x33), 0x52> (checksum 0x52)
[00124723ms,usb] INDI Celestron AUX -> ALT MC, cmd MTR_GET_AUTOGUIDE_RATE: AUX packet <0x3b, 0x03, 0x20, 0x11, 0x47, 0x85> (checksum 0x85)
[00124868ms,aux] ALT MC -> INDI Celestron AUX, cmd MTR_GET_AUTOGUIDE_RATE: AUX packet <0x3b, 0x04, 0x11, 0x20, 0x47, (0xcc), 0xb8> (checksum 0xb8)
[00124969ms,usb] INDI Celestron AUX -> AZM MC, cmd MTR_IS_CORDWRAP_ON: AUX packet <0x3b, 0x03, 0x20, 0x10, 0x3b, 0x92> (checksum 0x92)
[00125112ms,aux] AZM MC -> INDI Celestron AUX, cmd MTR_IS_CORDWRAP_ON: AUX packet <0x3b, 0x04, 0x10, 0x20, 0x3b, (0x00), 0x91> (checksum 0x91)
[00125210ms,usb] INDI Celestron AUX -> AZM MC, cmd MTR_GET_CORDWRAP_POSITION: AUX packet <0x3b, 0x03, 0x20, 0x10, 0x3c, 0x91> (checksum 0x91)
[00125376ms,aux] AZM MC -> INDI Celestron AUX, cmd MTR_GET_CORDWRAP_POSITION: AUX packet <0x3b, 0x06, 0x10, 0x20, 0x3c, (0x00 0x00 0x00), 0x8e> (checksum 0x8e)
[00125484ms,usb] INDI Celestron AUX -> AZM MC, cmd MTR_GET_MODEL: AUX packet <0x3b, 0x03, 0x20, 0x10, 0x05, 0xc8> (checksum 0xc8)
[00125634ms,aux] AZM MC -> INDI Celestron AUX, cmd MTR_GET_MODEL: AUX packet <0x3b, 0x05, 0x10, 0x20, 0x05, (0x14 0x85), 0x2d> (checksum 0x2d)
[00125732ms,usb] INDI Celestron AUX -> Main Board, cmd MB_GET_FW_VER: AUX packet <0x3b, 0x03, 0x20, 0x01, 0xfe, 0xde> (checksum 0xde)
[00126828ms,usb] INDI Celestron AUX -> Nexstar HC, cmd NXS_GET_FW_VER: AUX packet <0x3b, 0x03, 0x20, 0x04, 0xfe, 0xdb> (checksum 0xdb)
[00127924ms,usb] INDI Celestron AUX -> Nexstar+ HC, cmd NXS_GET_FW_VER: AUX packet <0x3b, 0x03, 0x20, 0x0d, 0xfe, 0xd2> (checksum 0xd2)
[00129021ms,usb] INDI Celestron AUX -> AZM MC, cmd MTR_GET_VERSION: AUX packet <0x3b, 0x03, 0x20, 0x10, 0xfe, 0xcf> (checksum 0xcf)
[00129193ms,aux] AZM MC -> INDI Celestron AUX, cmd NXS_GET_FW_VER: AUX packet <0x3b, 0x07, 0x10, 0x20, 0xfe, (0x07 0x0f 0x20 0x4e), 0x47> (checksum 0x47)
[00129297ms,usb] INDI Celestron AUX -> ALT MC, cmd MTR_GET_VERSION: AUX packet <0x3b, 0x03, 0x20, 0x11, 0xfe, 0xce> (checksum 0xce)
[00129468ms,aux] ALT MC -> INDI Celestron AUX, cmd NXS_GET_FW_VER: AUX packet <0x3b, 0x07, 0x11, 0x20, 0xfe, (0x07 0x0f 0x20 0x4e), 0x46> (checksum 0x46)
[00129572ms,usb] INDI Celestron AUX -> GPS, cmd GPS_GET_FW_VER: AUX packet <0x3b, 0x03, 0x20, 0xb0, 0xfe, 0x2f> (checksum 0x2f)
[00130665ms,usb] INDI Celestron AUX -> Nexstar EVO WiFi, cmd WIFI_GET_FW_VER: AUX packet <0x3b, 0x03, 0x20, 0xb5, 0xfe, 0x2a> (checksum 0x2a)
[00131765ms,usb] INDI Celestron AUX -> Battery Power Cont, cmd BAT_GET_FW_VER: AUX packet <0x3b, 0x03, 0x20, 0xb6, 0xfe, 0x29> (checksum 0x29)
[00132867ms,usb] INDI Celestron AUX -> AZM MC, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x03, 0x20, 0x10, 0x01, 0xcc> (checksum 0xcc)
[00133030ms,aux] AZM MC -> INDI Celestron AUX, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x06, 0x10, 0x20, 0x01, (0xff 0xff 0xff), 0xcc> (checksum 0xcc)
[00133132ms,usb] INDI Celestron AUX -> ALT MC, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x03, 0x20, 0x11, 0x01, 0xcb> (checksum 0xcb)
[00133294ms,aux] ALT MC -> INDI Celestron AUX, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x06, 0x11, 0x20, 0x01, (0x00 0x00 0x00), 0xc8> (checksum 0xc8)
[00133397ms,usb] INDI Celestron AUX -> ALT MC, cmd MTR_AUX_GUIDE: AUX packet <0x3b, 0x05, 0x20, 0x11, 0x26, (0x50 0x14), 0x40> (checksum 0x40)
[00133534ms,aux] ALT MC -> INDI Celestron AUX, cmd MTR_AUX_GUIDE: AUX packet <0x3b, 0x03, 0x11, 0x20, 0x26, 0xa6> (checksum 0xa6)
[00134399ms,usb] INDI Celestron AUX -> AZM MC, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x03, 0x20, 0x10, 0x01, 0xcc> (checksum 0xcc)

Sending additional guide pulse shows:

[00149977ms,usb] INDI Celestron AUX -> ALT MC, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x03, 0x20, 0x11, 0x01, 0xcb> (checksum 0xcb)
[00150139ms,aux] ALT MC -> INDI Celestron AUX, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x06, 0x11, 0x20, 0x01, (0x00 0x01 0x55), 0x72> (checksum 0x72)
[00150242ms,usb] INDI Celestron AUX -> AZM MC, cmd MTR_AUX_GUIDE: AUX packet <0x3b, 0x05, 0x20, 0x10, 0x26, (0x14 0x96), 0xfb> (checksum 0xfb)
[00150379ms,aux] AZM MC -> INDI Celestron AUX, cmd MTR_AUX_GUIDE: AUX packet <0x3b, 0x03, 0x10, 0x20, 0x26, 0xa7> (checksum 0xa7)
[00151244ms,usb] INDI Celestron AUX -> AZM MC, cmd MTR_GET_POSITION: AUX packet <0x3b, 0x03, 0x20, 0x10, 0x01, 0xcc> (checksum 0xcc)

So probably it would be good to merge this "Model determination" PR and in a next PR determine based on the Model
whether it is a GEM, ALT_AZ or FORK mount. Does the mount detection method work for your mount. For my Celestron AVX it does not work and used the default ALT_AZ type rather than GEM mount.

@tstibor
Copy link
Contributor Author

tstibor commented Feb 26, 2023

The Celestron AUX driver is reporting itself in getDeviceName() as:

240	    if (m_MountType == ALT_AZ)
(gdb) p getDeviceName()
$2 = 0x5555555c7e70 "Celestron AUX"

and unfortunately not as the model name

@knro
Copy link
Collaborator

knro commented Feb 26, 2023

This is because you need to set INDI_DEV environment variable to the final name before starting debugging. When running the actual driver from a client like KStars, it starts it with a specific name being the desired label. At any rate, let me check with CGX-L I have here to see how it behaves.

@knro knro merged commit 73ba1ad into indilib:master Feb 26, 2023
@knro
Copy link
Collaborator

knro commented Feb 26, 2023

Ok I tested with guiding and it works OK. However, I am still unclear on whether the HC is required for the initial startup or not? I got this explanation from Celestron:

If you go to MENU(7) -> Utilities -> Get Axis Position, you will see Azm and Alt axes reported. These are not local altitude and azimuth coordinates. They are encoder values.
Alt/Az mounts initialize the encoders to 0 both axes at power up.

The HC will re-initialize the encoders of GEM mounts so that the axes are set to 90 and 90. This initialization happens after you go to the switch position (or go to the index position if you don’t have switches).

The NS+ hand control on an Alt Az mount only, will re-initialize the encoder values during (or immediately after) alignment to values that are APPROXIMATELY equal to local alt azimuth. This is intended as a convenience for debugging – they could be off by several degrees from the real local altitude and azimuth.

There is a “Get Alt Az” method available through USART API (serial port on the bottom of the HC) which returns the true local altitude and azimuth positions. This call only works after the mount has been aligned and returns values based on knowledge of the mount model, the encoder values, and the time.

So it appears you cannot simple use AUX via USB/PC port directly without initially using the HC to set it up and perform some sort of alignment or index positioning?

@ckuethe
Copy link

ckuethe commented Feb 26, 2023

I can use AUX-via-HC-USB without ever going outside to touch the mount, even after power cycling my whole telescope. Sure, the first time it was set up I used the hand controller to move to the index marks, then set set that as the home position. After that, nothing else has been required to use the hand controller.

Next time I have clear skies I can try a quick align, which seems to just tell the HC that I am polar aligned and at the index marks and please just get out of my way... maybe that will have some effect on guiding, etc. It'd be nice if there was a quick align protocol command to do the same thing.

@tstibor
Copy link
Contributor Author

tstibor commented Feb 27, 2023

I sniffed via the DIY usbauxrelay MCU the AUX-bus while the HC connected. After switching on the HC the following AUX packets are sent:


[00806673ms,aux] Nexstar+ HC -> ALT MC, cmd MTR_GET_MODEL: AUX packet <0x3b, 0x03, 0x0d, 0x11, 0x05, 0xda> (checksum 0xda)
[00806820ms,aux] ALT MC -> Nexstar+ HC, cmd MTR_GET_MODEL: AUX packet <0x3b, 0x05, 0x11, 0x0d, 0x05, (0x14 0x85), 0x3f> (checksum 0x3f)
[00806953ms,aux] Nexstar+ HC -> AZM MC, cmd MTR_GET_MODEL: AUX packet <0x3b, 0x03, 0x0d, 0x10, 0x05, 0xdb> (checksum 0xdb)
[00807099ms,aux] AZM MC -> Nexstar+ HC, cmd MTR_GET_MODEL: AUX packet <0x3b, 0x05, 0x10, 0x0d, 0x05, (0x14 0x85), 0x40> (checksum 0x40)
[00807232ms,aux] Nexstar+ HC -> AZM MC, cmd MTR_GET_VERSION: AUX packet <0x3b, 0x03, 0x0d, 0x10, 0xfe, 0xe2> (checksum 0xe2)
[00807399ms,aux] AZM MC -> Nexstar+ HC, cmd NXS_GET_FW_VER: AUX packet <0x3b, 0x07, 0x10, 0x0d, 0xfe, (0x07 0x0f 0x20 0x4e), 0x5a> (checksum 0x5a)
[00807538ms,aux] Nexstar+ HC -> AZM MC, cmd MTR_IS_APPROACH_DIR_NEG: AUX packet <0x3b, 0x03, 0x0d, 0x10, 0xfc, 0xe4> (checksum 0xe4)
[00807679ms,aux] AZM MC -> Nexstar+ HC, cmd MTR_IS_APPROACH_DIR_NEG: AUX packet <0x3b, 0x04, 0x10, 0x0d, 0xfc, (0x00), 0xe3> (checksum 0xe3)
[00807815ms,aux] Nexstar+ HC -> ALT MC, cmd MTR_IS_APPROACH_DIR_NEG: AUX packet <0x3b, 0x03, 0x0d, 0x11, 0xfc, 0xe3> (checksum 0xe3)
[00807956ms,aux] ALT MC -> Nexstar+ HC, cmd MTR_IS_APPROACH_DIR_NEG: AUX packet <0x3b, 0x04, 0x11, 0x0d, 0xfc, (0x00), 0xe2> (checksum 0xe2)
[00808092ms,aux] Nexstar+ HC -> Focuser, cmd FOCUS_GET_FW_VER: AUX packet <0x3b, 0x03, 0x0d, 0x12, 0xfe, 0xe0> (checksum 0xe0)
[00808220ms,aux] Nexstar+ HC -> Focuser, cmd FOCUS_GET_FW_VER: AUX packet <0x3b, 0x03, 0x0d, 0x12, 0xfe, 0xe0> (checksum 0xe0)
[00808348ms,aux] Nexstar+ HC -> Focuser, cmd FOCUS_GET_FW_VER: AUX packet <0x3b, 0x03, 0x0d, 0x12, 0xfe, 0xe0> (checksum 0xe0)
[00808477ms,aux] Nexstar+ HC -> Focuser, cmd FOCUS_GET_FW_VER: AUX packet <0x3b, 0x03, 0x0d, 0x12, 0xfe, 0xe0> (checksum 0xe0)
[00808605ms,aux] Nexstar+ HC -> Focuser, cmd FOCUS_GET_FW_VER: AUX packet <0x3b, 0x03, 0x0d, 0x12, 0xfe, 0xe0> (checksum 0xe0)
[00808733ms,aux] Nexstar+ HC -> Dew Heater Controller, cmd DEWHEATER_GET_FW_VER: AUX packet <0x3b, 0x03, 0x0d, 0xbb, 0xfe, 0x37> (checksum 0x37)
[00809007ms,aux] Nexstar+ HC -> Dew Heater Controller, cmd DEWHEATER_GET_FW_VER: AUX packet <0x3b, 0x03, 0x0d, 0xbb, 0xfe, 0x37> (checksum 0x37)
[00809360ms,aux] Nexstar+ HC -> Dew Heater Controller, cmd DEWHEATER_GET_FW_VER: AUX packet <0x3b, 0x03, 0x0d, 0xbb, 0xfe, 0x37> (checksum 0x37)
[00809713ms,aux] Nexstar+ HC -> Dew Heater Controller, cmd DEWHEATER_GET_FW_VER: AUX packet <0x3b, 0x03, 0x0d, 0xbb, 0xfe, 0x37> (checksum 0x37)
[00810066ms,aux] Nexstar+ HC -> Dew Heater Controller, cmd DEWHEATER_GET_FW_VER: AUX packet <0x3b, 0x03, 0x0d, 0xbb, 0xfe, 0x37> (checksum 0x37)
[00810449ms,aux] Nexstar+ HC -> AZM MC, cmd MTR_SET_POSITION: AUX packet <0x3b, 0x06, 0x0d, 0x10, 0x04, (0x40 0x00 0x00), 0x99> (checksum 0x99)
[00810587ms,aux] AZM MC -> Nexstar+ HC, cmd MTR_SET_POSITION: AUX packet <0x3b, 0x03, 0x10, 0x0d, 0x04, 0xdc> (checksum 0xdc)
[00810745ms,aux] Nexstar+ HC -> ALT MC, cmd MTR_SET_POSITION: AUX packet <0x3b, 0x06, 0x0d, 0x11, 0x04, (0x40 0x00 0x00), 0x98> (checksum 0x98)
[00810882ms,aux] ALT MC -> Nexstar+ HC, cmd MTR_SET_POSITION: AUX packet <0x3b, 0x03, 0x11, 0x0d, 0x04, 0xdb> (checksum 0xdb)
[00811040ms,aux] Nexstar+ HC -> AZM MC, cmd MTR_SET_CORDWRAP_POSITION: AUX packet <0x3b, 0x06, 0x0d, 0x10, 0x3a, (0xc0 0x00 0x00), 0xe3> (checksum 0xe3)
[00811182ms,aux] AZM MC -> Nexstar+ HC, cmd MTR_SET_CORDWRAP_POSITION: AUX packet <0x3b, 0x03, 0x10, 0x0d, 0x3a, 0xa6> (checksum 0xa6)
[00811314ms,aux] Nexstar+ HC -> AZM MC, cmd MTR_CORDWRAP_ON: AUX packet <0x3b, 0x03, 0x0d, 0x10, 0x38, 0xa8> (checksum 0xa8)
[00811441ms,aux] AZM MC -> Nexstar+ HC, cmd MTR_CORDWRAP_ON: AUX packet <0x3b, 0x03, 0x10, 0x0d, 0x38, 0xa8> (checksum 0xa8)
[00811598ms,aux] Nexstar+ HC -> ALT MC, cmd MTR_SET_CORDWRAP_POSITION: AUX packet <0x3b, 0x06, 0x0d, 0x11, 0x3a, (0xc0 0x00 0x00), 0xe2> (checksum 0xe2)
[00811740ms,aux] ALT MC -> Nexstar+ HC, cmd MTR_SET_CORDWRAP_POSITION: AUX packet <0x3b, 0x03, 0x11, 0x0d, 0x3a, 0xa5> (checksum 0xa5)
[00811873ms,aux] Nexstar+ HC -> ALT MC, cmd MTR_CORDWRAP_ON: AUX packet <0x3b, 0x03, 0x0d, 0x11, 0x38, 0xa7> (checksum 0xa7)
[00812000ms,aux] ALT MC -> Nexstar+ HC, cmd MTR_CORDWRAP_ON: AUX packet <0x3b, 0x03, 0x11, 0x0d, 0x38, 0xa7> (checksum 0xa7)

After these packets are sent from HC to MC, I confirmed on the HC:

  • Set to INDEX
  • Date/Time
  • Quick Align

After hitting ENTER (Quick Align) the following AUX packets are sent:

[00898865ms,aux] Nexstar+ HC -> AZM MC, cmd MTR_SET_POSITION: AUX packet <0x3b, 0x06, 0x0d, 0x10, 0x04, (0x40 0x00 0x00), 0x99> (checksum 0x99)
[00899002ms,aux] AZM MC -> Nexstar+ HC, cmd MTR_SET_POSITION: AUX packet <0x3b, 0x03, 0x10, 0x0d, 0x04, 0xdc> (checksum 0xdc)
[00899160ms,aux] Nexstar+ HC -> ALT MC, cmd MTR_SET_POSITION: AUX packet <0x3b, 0x06, 0x0d, 0x11, 0x04, (0x40 0x00 0x00), 0x98> (checksum 0x98)
[00899297ms,aux] ALT MC -> Nexstar+ HC, cmd MTR_SET_POSITION: AUX packet <0x3b, 0x03, 0x11, 0x0d, 0x04, 0xdb> (checksum 0xdb)
[00899455ms,aux] Nexstar+ HC -> AZM MC, cmd MTR_SET_CORDWRAP_POSITION: AUX packet <0x3b, 0x06, 0x0d, 0x10, 0x3a, (0xc0 0x00 0x00), 0xe3> (checksum 0xe3)
[00899597ms,aux] AZM MC -> Nexstar+ HC, cmd MTR_SET_CORDWRAP_POSITION: AUX packet <0x3b, 0x03, 0x10, 0x0d, 0x3a, 0xa6> (checksum 0xa6)
[00899729ms,aux] Nexstar+ HC -> AZM MC, cmd MTR_CORDWRAP_ON: AUX packet <0x3b, 0x03, 0x0d, 0x10, 0x38, 0xa8> (checksum 0xa8)
[00899856ms,aux] AZM MC -> Nexstar+ HC, cmd MTR_CORDWRAP_ON: AUX packet <0x3b, 0x03, 0x10, 0x0d, 0x38, 0xa8> (checksum 0xa8)
[00900014ms,aux] Nexstar+ HC -> ALT MC, cmd MTR_SET_CORDWRAP_POSITION: AUX packet <0x3b, 0x06, 0x0d, 0x11, 0x3a, (0xc0 0x00 0x00), 0xe2> (checksum 0xe2)
[00900156ms,aux] ALT MC -> Nexstar+ HC, cmd MTR_SET_CORDWRAP_POSITION: AUX packet <0x3b, 0x03, 0x11, 0x0d, 0x3a, 0xa5> (checksum 0xa5)
[00900288ms,aux] Nexstar+ HC -> ALT MC, cmd MTR_CORDWRAP_ON: AUX packet <0x3b, 0x03, 0x0d, 0x11, 0x38, 0xa7> (checksum 0xa7)
[00900415ms,aux] ALT MC -> Nexstar+ HC, cmd MTR_CORDWRAP_ON: AUX packet <0x3b, 0x03, 0x11, 0x0d, 0x38, 0xa7> (checksum 0xa7)
[00900572ms,aux] Nexstar+ HC -> AZM MC, cmd MTR_PTRACK: AUX packet <0x3b, 0x06, 0x0d, 0x10, 0x06, (0x00 0x00 0x00), 0xd7> (checksum 0xd7)
[00900706ms,aux] AZM MC -> Nexstar+ HC, cmd MTR_PTRACK: AUX packet <0x3b, 0x03, 0x10, 0x0d, 0x06, 0xda> (checksum 0xda)
[00900861ms,aux] Nexstar+ HC -> ALT MC, cmd MTR_PTRACK: AUX packet <0x3b, 0x06, 0x0d, 0x11, 0x06, (0x00 0x00 0x00), 0xd6> (checksum 0xd6)
[00900995ms,aux] ALT MC -> Nexstar+ HC, cmd MTR_PTRACK: AUX packet <0x3b, 0x03, 0x11, 0x0d, 0x06, 0xd9> (checksum 0xd9)
[00901140ms,aux] Nexstar+ HC -> AZM MC, cmd MTR_PTRACK: AUX packet <0x3b, 0x05, 0x0d, 0x10, 0x06, (0xff 0xff), 0xda> (checksum 0xda)
[00901271ms,aux] AZM MC -> Nexstar+ HC, cmd MTR_PTRACK: AUX packet <0x3b, 0x03, 0x10, 0x0d, 0x06, 0xda> (checksum 0xda)

I used before the Celestron GPS driver and always did a quick align, and then sync'ed on 2-3 stars via astrometry and everything was fine. I guess the same should apply for the AUX driver as well. I tested the Celestron AUX driver just indoor.

The important packets after Quick-Align seems to be:

[00898865ms,aux] Nexstar+ HC -> AZM MC, cmd MTR_SET_POSITION: AUX packet <0x3b, 0x06, 0x0d, 0x10, 0x04, (0x40 0x00 0x00), 0x99> (checksum 0x99)
[00899002ms,aux] AZM MC -> Nexstar+ HC, cmd MTR_SET_POSITION: AUX packet <0x3b, 0x03, 0x10, 0x0d, 0x04, 0xdc> (checksum 0xdc)
[00899160ms,aux] Nexstar+ HC -> ALT MC, cmd MTR_SET_POSITION: AUX packet <0x3b, 0x06, 0x0d, 0x11, 0x04, (0x40 0x00 0x00), 0x98> (checksum 0x98)
[00899297ms,aux] ALT MC -> Nexstar+ HC, cmd MTR_SET_POSITION: AUX packet <0x3b, 0x03, 0x11, 0x0d, 0x04, 0xdb> (checksum 0xdb)
[00899455ms,aux] Nexstar+ HC -> AZM MC, cmd MTR_SET_CORDWRAP_POSITION: AUX packet <0x3b, 0x06, 0x0d, 0x10, 0x3a, (0xc0 0x00 0x00), 0xe3> (checksum 0xe3)
[00899597ms,aux] AZM MC -> Nexstar+ HC, cmd MTR_SET_CORDWRAP_POSITION: AUX packet <0x3b, 0x03, 0x10, 0x0d, 0x3a, 0xa6> (checksum 0xa6)
[00899729ms,aux] Nexstar+ HC -> AZM MC, cmd MTR_CORDWRAP_ON: AUX packet <0x3b, 0x03, 0x0d, 0x10, 0x38, 0xa8> (checksum 0xa8)
[00899856ms,aux] AZM MC -> Nexstar+ HC, cmd MTR_CORDWRAP_ON: AUX packet <0x3b, 0x03, 0x10, 0x0d, 0x38, 0xa8> (checksum 0xa8)
[00900014ms,aux] Nexstar+ HC -> ALT MC, cmd MTR_SET_CORDWRAP_POSITION: AUX packet <0x3b, 0x06, 0x0d, 0x11, 0x3a, (0xc0 0x00 0x00), 0xe2> (checksum 0xe2)
[00900156ms,aux] ALT MC -> Nexstar+ HC, cmd MTR_SET_CORDWRAP_POSITION: AUX packet <0x3b, 0x03, 0x11, 0x0d, 0x3a, 0xa5> (checksum 0xa5)
[00900288ms,aux] Nexstar+ HC -> ALT MC, cmd MTR_CORDWRAP_ON: AUX packet <0x3b, 0x03, 0x0d, 0x11, 0x38, 0xa7> (checksum 0xa7)
[00900415ms,aux] ALT MC -> Nexstar+ HC, cmd MTR_CORDWRAP_ON: AUX packet <0x3b, 0x03, 0x11, 0x0d, 0x38, 0xa7> (checksum 0xa7)

@tstibor
Copy link
Contributor Author

tstibor commented Feb 27, 2023

When the RTC is activated the AUX packets looks as follows (same procedure as above).:

[00384443ms,aux] Nexstar+ HC -> ALT MC, cmd MTR_GET_MODEL: AUX packet <0x3b, 0x03, 0x0d, 0x11, 0x05, 0xda> (checksum 0xda)
[00384589ms,aux] ALT MC -> Nexstar+ HC, cmd MTR_GET_MODEL: AUX packet <0x3b, 0x05, 0x11, 0x0d, 0x05, (0x14 0x85), 0x3f> (checksum 0x3f)
[00384722ms,aux] Nexstar+ HC -> AZM MC, cmd MTR_GET_MODEL: AUX packet <0x3b, 0x03, 0x0d, 0x10, 0x05, 0xdb> (checksum 0xdb)
[00384868ms,aux] AZM MC -> Nexstar+ HC, cmd MTR_GET_MODEL: AUX packet <0x3b, 0x05, 0x10, 0x0d, 0x05, (0x14 0x85), 0x40> (checksum 0x40)
[00385001ms,aux] Nexstar+ HC -> AZM MC, cmd MTR_GET_VERSION: AUX packet <0x3b, 0x03, 0x0d, 0x10, 0xfe, 0xe2> (checksum 0xe2)
[00385168ms,aux] AZM MC -> Nexstar+ HC, cmd NXS_GET_FW_VER: AUX packet <0x3b, 0x07, 0x10, 0x0d, 0xfe, (0x07 0x0f 0x20 0x4e), 0x5a> (checksum 0x5a)
[00385307ms,aux] Nexstar+ HC -> AZM MC, cmd MTR_IS_APPROACH_DIR_NEG: AUX packet <0x3b, 0x03, 0x0d, 0x10, 0xfc, 0xe4> (checksum 0xe4)
[00385449ms,aux] AZM MC -> Nexstar+ HC, cmd MTR_IS_APPROACH_DIR_NEG: AUX packet <0x3b, 0x04, 0x10, 0x0d, 0xfc, (0x00), 0xe3> (checksum 0xe3)
[00385584ms,aux] Nexstar+ HC -> ALT MC, cmd MTR_IS_APPROACH_DIR_NEG: AUX packet <0x3b, 0x03, 0x0d, 0x11, 0xfc, 0xe3> (checksum 0xe3)
[00385726ms,aux] ALT MC -> Nexstar+ HC, cmd MTR_IS_APPROACH_DIR_NEG: AUX packet <0x3b, 0x04, 0x11, 0x0d, 0xfc, (0x00), 0xe2> (checksum 0xe2)
[00385861ms,aux] Nexstar+ HC -> Focuser, cmd FOCUS_GET_FW_VER: AUX packet <0x3b, 0x03, 0x0d, 0x12, 0xfe, 0xe0> (checksum 0xe0)
[00385990ms,aux] Nexstar+ HC -> Focuser, cmd FOCUS_GET_FW_VER: AUX packet <0x3b, 0x03, 0x0d, 0x12, 0xfe, 0xe0> (checksum 0xe0)
[00386118ms,aux] Nexstar+ HC -> Focuser, cmd FOCUS_GET_FW_VER: AUX packet <0x3b, 0x03, 0x0d, 0x12, 0xfe, 0xe0> (checksum 0xe0)
[00386246ms,aux] Nexstar+ HC -> Focuser, cmd FOCUS_GET_FW_VER: AUX packet <0x3b, 0x03, 0x0d, 0x12, 0xfe, 0xe0> (checksum 0xe0)
[00386374ms,aux] Nexstar+ HC -> Focuser, cmd FOCUS_GET_FW_VER: AUX packet <0x3b, 0x03, 0x0d, 0x12, 0xfe, 0xe0> (checksum 0xe0)
[00386502ms,aux] Nexstar+ HC -> Dew Heater Controller, cmd DEWHEATER_GET_FW_VER: AUX packet <0x3b, 0x03, 0x0d, 0xbb, 0xfe, 0x37> (checksum 0x37)
[00386776ms,aux] Nexstar+ HC -> Dew Heater Controller, cmd DEWHEATER_GET_FW_VER: AUX packet <0x3b, 0x03, 0x0d, 0xbb, 0xfe, 0x37> (checksum 0x37)
[00387129ms,aux] Nexstar+ HC -> Dew Heater Controller, cmd DEWHEATER_GET_FW_VER: AUX packet <0x3b, 0x03, 0x0d, 0xbb, 0xfe, 0x37> (checksum 0x37)
[00387482ms,aux] Nexstar+ HC -> Dew Heater Controller, cmd DEWHEATER_GET_FW_VER: AUX packet <0x3b, 0x03, 0x0d, 0xbb, 0xfe, 0x37> (checksum 0x37)
[00387835ms,aux] Nexstar+ HC -> Dew Heater Controller, cmd DEWHEATER_GET_FW_VER: AUX packet <0x3b, 0x03, 0x0d, 0xbb, 0xfe, 0x37> (checksum 0x37)
[00388218ms,aux] Nexstar+ HC -> AZM MC, cmd MTR_SET_POSITION: AUX packet <0x3b, 0x06, 0x0d, 0x10, 0x04, (0x40 0x00 0x00), 0x99> (checksum 0x99)
[00388356ms,aux] AZM MC -> Nexstar+ HC, cmd MTR_SET_POSITION: AUX packet <0x3b, 0x03, 0x10, 0x0d, 0x04, 0xdc> (checksum 0xdc)
[00388514ms,aux] Nexstar+ HC -> ALT MC, cmd MTR_SET_POSITION: AUX packet <0x3b, 0x06, 0x0d, 0x11, 0x04, (0x40 0x00 0x00), 0x98> (checksum 0x98)
[00388651ms,aux] ALT MC -> Nexstar+ HC, cmd MTR_SET_POSITION: AUX packet <0x3b, 0x03, 0x11, 0x0d, 0x04, 0xdb> (checksum 0xdb)
[00388809ms,aux] Nexstar+ HC -> AZM MC, cmd MTR_SET_CORDWRAP_POSITION: AUX packet <0x3b, 0x06, 0x0d, 0x10, 0x3a, (0xc0 0x00 0x00), 0xe3> (checksum 0xe3)
[00388951ms,aux] AZM MC -> Nexstar+ HC, cmd MTR_SET_CORDWRAP_POSITION: AUX packet <0x3b, 0x03, 0x10, 0x0d, 0x3a, 0xa6> (checksum 0xa6)
[00389083ms,aux] Nexstar+ HC -> AZM MC, cmd MTR_CORDWRAP_ON: AUX packet <0x3b, 0x03, 0x0d, 0x10, 0x38, 0xa8> (checksum 0xa8)
[00389210ms,aux] AZM MC -> Nexstar+ HC, cmd MTR_CORDWRAP_ON: AUX packet <0x3b, 0x03, 0x10, 0x0d, 0x38, 0xa8> (checksum 0xa8)
[00389367ms,aux] Nexstar+ HC -> ALT MC, cmd MTR_SET_CORDWRAP_POSITION: AUX packet <0x3b, 0x06, 0x0d, 0x11, 0x3a, (0xc0 0x00 0x00), 0xe2> (checksum 0xe2)
[00389509ms,aux] ALT MC -> Nexstar+ HC, cmd MTR_SET_CORDWRAP_POSITION: AUX packet <0x3b, 0x03, 0x11, 0x0d, 0x3a, 0xa5> (checksum 0xa5)
[00389642ms,aux] Nexstar+ HC -> ALT MC, cmd MTR_CORDWRAP_ON: AUX packet <0x3b, 0x03, 0x0d, 0x11, 0x38, 0xa7> (checksum 0xa7)
[00389769ms,aux] ALT MC -> Nexstar+ HC, cmd MTR_CORDWRAP_ON: AUX packet <0x3b, 0x03, 0x11, 0x0d, 0x38, 0xa7> (checksum 0xa7)
[00406376ms,aux] Nexstar+ HC -> RTC, cmd RTC_GET_FW_VER: AUX packet <0x3b, 0x03, 0x0d, 0xb2, 0xfe, 0x40> (checksum 0x40)
[00406521ms,aux] RTC -> Nexstar+ HC, cmd NXS_GET_FW_VER: AUX packet <0x3b, 0x05, 0xb2, 0x0d, 0xfe, (0x03 0x01), 0x3a> (checksum 0x3a)
[00406653ms,aux] Nexstar+ HC -> RTC, cmd RTC_GET_FW_VER: AUX packet <0x3b, 0x03, 0x0d, 0xb2, 0xfe, 0x40> (checksum 0x40)
[00406798ms,aux] RTC -> Nexstar+ HC, cmd NXS_GET_FW_VER: AUX packet <0x3b, 0x05, 0xb2, 0x0d, 0xfe, (0x03 0x01), 0x3a> (checksum 0x3a)
[00406930ms,aux] Nexstar+ HC -> RTC, cmd UNKNOWN: AUX packet <0x3b, 0x03, 0x0d, 0xb2, 0x05, 0x39> (checksum 0x39)
[00407091ms,aux] RTC -> Nexstar+ HC, cmd UNKNOWN: AUX packet <0x3b, 0x07, 0xb2, 0x0d, 0x05, (0x2b 0x40 0x5c 0xd6), 0x98> (checksum 0x98)
[00426302ms,aux] Nexstar+ HC -> AZM MC, cmd MTR_SET_POSITION: AUX packet <0x3b, 0x06, 0x0d, 0x10, 0x04, (0x40 0x00 0x00), 0x99> (checksum 0x99)
[00426440ms,aux] AZM MC -> Nexstar+ HC, cmd MTR_SET_POSITION: AUX packet <0x3b, 0x03, 0x10, 0x0d, 0x04, 0xdc> (checksum 0xdc)
[00426597ms,aux] Nexstar+ HC -> ALT MC, cmd MTR_SET_POSITION: AUX packet <0x3b, 0x06, 0x0d, 0x11, 0x04, (0x40 0x00 0x00), 0x98> (checksum 0x98)
[00426735ms,aux] ALT MC -> Nexstar+ HC, cmd MTR_SET_POSITION: AUX packet <0x3b, 0x03, 0x11, 0x0d, 0x04, 0xdb> (checksum 0xdb)
[00426892ms,aux] Nexstar+ HC -> AZM MC, cmd MTR_SET_CORDWRAP_POSITION: AUX packet <0x3b, 0x06, 0x0d, 0x10, 0x3a, (0xc0 0x00 0x00), 0xe3> (checksum 0xe3)
[00427034ms,aux] AZM MC -> Nexstar+ HC, cmd MTR_SET_CORDWRAP_POSITION: AUX packet <0x3b, 0x03, 0x10, 0x0d, 0x3a, 0xa6> (checksum 0xa6)
[00427167ms,aux] Nexstar+ HC -> AZM MC, cmd MTR_CORDWRAP_ON: AUX packet <0x3b, 0x03, 0x0d, 0x10, 0x38, 0xa8> (checksum 0xa8)
[00427294ms,aux] AZM MC -> Nexstar+ HC, cmd MTR_CORDWRAP_ON: AUX packet <0x3b, 0x03, 0x10, 0x0d, 0x38, 0xa8> (checksum 0xa8)
[00427451ms,aux] Nexstar+ HC -> ALT MC, cmd MTR_SET_CORDWRAP_POSITION: AUX packet <0x3b, 0x06, 0x0d, 0x11, 0x3a, (0xc0 0x00 0x00), 0xe2> (checksum 0xe2)
[00427593ms,aux] ALT MC -> Nexstar+ HC, cmd MTR_SET_CORDWRAP_POSITION: AUX packet <0x3b, 0x03, 0x11, 0x0d, 0x3a, 0xa5> (checksum 0xa5)
[00427726ms,aux] Nexstar+ HC -> ALT MC, cmd MTR_CORDWRAP_ON: AUX packet <0x3b, 0x03, 0x0d, 0x11, 0x38, 0xa7> (checksum 0xa7)
[00427853ms,aux] ALT MC -> Nexstar+ HC, cmd MTR_CORDWRAP_ON: AUX packet <0x3b, 0x03, 0x11, 0x0d, 0x38, 0xa7> (checksum 0xa7)
[00428010ms,aux] Nexstar+ HC -> AZM MC, cmd MTR_PTRACK: AUX packet <0x3b, 0x06, 0x0d, 0x10, 0x06, (0x00 0x00 0x00), 0xd7> (checksum 0xd7)
[00428144ms,aux] AZM MC -> Nexstar+ HC, cmd MTR_PTRACK: AUX packet <0x3b, 0x03, 0x10, 0x0d, 0x06, 0xda> (checksum 0xda)
[00428299ms,aux] Nexstar+ HC -> ALT MC, cmd MTR_PTRACK: AUX packet <0x3b, 0x06, 0x0d, 0x11, 0x06, (0x00 0x00 0x00), 0xd6> (checksum 0xd6)
[00428433ms,aux] ALT MC -> Nexstar+ HC, cmd MTR_PTRACK: AUX packet <0x3b, 0x03, 0x11, 0x0d, 0x06, 0xd9> (checksum 0xd9)
[00428577ms,aux] Nexstar+ HC -> AZM MC, cmd MTR_PTRACK: AUX packet <0x3b, 0x05, 0x0d, 0x10, 0x06, (0xff 0xff), 0xda> (checksum 0xda)
[00428709ms,aux] AZM MC -> Nexstar+ HC, cmd MTR_PTRACK: AUX packet <0x3b, 0x03, 0x10, 0x0d, 0x06, 0xda> (checksum 0xda)

@knro
Copy link
Collaborator

knro commented Feb 27, 2023

That's some great progress @tstibor !! Do you think we can prepare a function to call these from the AUX driver so we can end up with the same effect as using the HC? Then it would be possible to completely get rid of the HC and just rely on the driver as-is for everything!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants