Questions? Comments or like to contact us? Use this form to message us.


Tel:    +1.604.421.2835

Sign up for our newsletter to get informed about NexDome news or new products.

Dec 25, 2018

ASCOM driver for firmware


So I recompiled the current driver and here are my findings so far when testing from TheSkyX Pro using the mount simulator and the ASCOM dome driver:

- Slewing (GoTo) works fine (end in the same positions as the X2 plugin so that's a good sign).

- Find home works.

- Park/unpark works.

- Open/close shutter works but both reports an error 206 in TSX which is ERR_CMDFAILED, even though the dome does open and close properly.


So I need to see what is causing the shutter error.


Dec 25, 2018

So, I found some clues :

15:25:59.615 Shutter Voltage Invalid (1208,1000M2)

15:26:59.663 Shutter Voltage Invalid (1209,1000M3)


so the driver ask for the voltage but also get the shutter status in the same buffer apparently.

So that's another synchronous vs asynchronous issue.

So probably more fixes in the firmware for all shutter commands to read the response on each command sent.

Dec 26, 2018

So 1208 and 1209. Are voltage? The 1000 is minimum volts you’ve set? What is m2 and M3?

Dec 26, 2018

yes : 1208 = 12.08V, 1209 = 12.09V, M2 = opening, M3 = closing

I try adding some more check in the firmware to try to read response from the shutter as command are sent but I still see the above messages..

16:05:51.839 Shutter Voltage Invalid (1202,1000M2)

16:06:21.917 Shutter Voltage Invalid (1202,1000M3)

So it really looks like it's something in the ASCOM driver that mangles the responses as I don't see this error in TSX with the X2 driver.

I've made some cleanup in the repo so I'm going to commit this for now (I removed the extra stuff and moved some things around so it's less confusing as to what directory contains what).




Dec 26, 2018Edited: Dec 26, 2018

more breaking... now open/close is no longer doing anything in ASCOM (still works with X2 so I know the shutter is seen by the rotator arduino).

Oh.. I looked at the profile and the "canSetShutter" is back to false ! .. I HATE ASCOM !!!!

Now the interesting thing is that in this state I get the 206 error in TSX very quickly.

I then reset the canSetShutter to true and I can open/close in TSX but still get that error.



Dec 26, 2018

So now with more debug, we get the M2 status on its own :

16:38:13.931 Slow update Get

16:38:13.932 serialMessageList part m0

16:38:13.934 serialMessageList part P12417

16:38:13.937 serialMessageList part M2

16:38:13.939 serialMessageList part F0

16:38:13.941 serialMessageList part k1195,1000

16:38:13.943 serialMessageList part K1208,1000M2


This shows that it's present on its own but also mangled with the voltages for the shutter.

I need to check the shutter firmware code.


Dec 26, 2018

Ok found a bug in the shutter firmware where a '#' was missing at the end of the voltage response. fixing.


Dec 26, 2018

so now more K1208,1000M2 in the log, one more bug gone :)

Now we need to figure out why the ASCOM code is not getting the shutter state.

It looks like a timer thing and some value not set somewhere.

We do get the shutter status :

serialMessageList part    M1


I'm going to stop there for today,

I've committed all my code so feel free to look into the ASCOM code. Most of what we care about is in Driver.cs

Dec 31, 2018

So I spent the last 2 hours trying to figure out the shutter issue. As far as I can tell the ASCOM driver is not updating the shutter status for the app in a timely manner. I tested with TheSkyX Pro and see this :


000000 12/30/2018 18:16:01.407 Link Established with ASCOM Dome
000001 12/30/2018 18:16:02.924 Alt=00:00:00, Az=000:00:00
000002 12/30/2018 18:16:07.527 Alt=00:00:00, Az=000:00:00 (Polled 4 times since last logged)
000003 12/30/2018 18:16:12.454 Alt=00:00:00, Az=000:00:00 (Polled 4 times since last logged)
000004 12/30/2018 18:16:13.473 OpenShutter() Command Issued
000005 12/30/2018 18:16:13.477 	ShutterStatus is now shutterClosed/1
000006 12/30/2018 18:16:13.478 	...value is not yet valid following OpenShutter().  Waiting 500ms... (attempt 1 of 10)
000007 12/30/2018 18:16:14.054 	ShutterStatus is now shutterClosed/1
000008 12/30/2018 18:16:14.071 	...value is not yet valid following OpenShutter().  Waiting 500ms... (attempt 2 of 10)
000009 12/30/2018 18:16:14.469 	ShutterStatus is now shutterClosed/1
000010 12/30/2018 18:16:14.484 	...value is not yet valid following OpenShutter().  Waiting 500ms... (attempt 3 of 10)
000011 12/30/2018 18:16:15.087 	ShutterStatus is now shutterClosed/1
000012 12/30/2018 18:16:15.108 	...value is not yet valid following OpenShutter().  Waiting 500ms... (attempt 4 of 10)
000013 12/30/2018 18:16:15.469 	ShutterStatus is now shutterClosed/1
000014 12/30/2018 18:16:15.482 	...value is not yet valid following OpenShutter().  Waiting 500ms... (attempt 5 of 10)
000015 12/30/2018 18:16:15.970 	ShutterStatus is now shutterClosed/1
000016 12/30/2018 18:16:15.982 	...value is not yet valid following OpenShutter().  Waiting 500ms... (attempt 6 of 10)
000017 12/30/2018 18:16:16.470 	ShutterStatus is now shutterClosed/1
000018 12/30/2018 18:16:16.485 	...value is not yet valid following OpenShutter().  Waiting 500ms... (attempt 7 of 10)
000019 12/30/2018 18:16:16.970 	ShutterStatus is now shutterClosed/1
000020 12/30/2018 18:16:16.983 	...value is not yet valid following OpenShutter().  Waiting 500ms... (attempt 8 of 10)
000021 12/30/2018 18:16:17.490 	ShutterStatus is now shutterClosed/1
000022 12/30/2018 18:16:17.509 	...value is not yet valid following OpenShutter().  Waiting 500ms... (attempt 9 of 10)
000023 12/30/2018 18:16:17.970 	ShutterStatus is now shutterClosed/1
000024 12/30/2018 18:16:17.984 	...value is not yet valid following OpenShutter().  Waiting 500ms... (attempt 10 of 10)
000025 12/30/2018 18:16:19.553 Alt=00:00:00, Az=000:00:00 (Polled 1 times since last logged)
000026 12/30/2018 18:16:24.493 Alt=00:00:00, Az=000:00:00 (Polled 4 times since last logged)
000027 12/30/2018 18:16:29.520 Alt=00:00:00, Az=000:00:00 (Polled 4 times since last logged)
000028 12/30/2018 18:16:34.540 Alt=00:00:00, Az=000:00:00 (Polled 4 times since last logged)

When testing with POTH, I can open/close but the actual status doesn't update for a good 30 seconds.. Not sure why and where to fix this.

We really need someone that understand ASCOM to help fixing this.


Dec 31, 2018

I did a big cleanup in the new official repo.

I renamed all the PDM Dome to NexDome, fix the Inno Setup installer file so that install, upgrade and uninstall now works.

So now the ASCOM driver is called 'NexDome Driver' in the ASCOM chooser instead of 'PDM NexDome Driver'.

Pat did a great job of getting us there and as the code is moving to the official NexDome Github, renaming was needed. Pat still has his name in the code and the commit logs.

Now that I can do a clean compile and install we have a better chance of figuring out how to fix the shutter state reporting issue.


I fixed a few things and apparently now the shutter open/close also works in TheSkyx Pro using the ASCOM driver.

I still see some crashes when clicking on "Cancel" in the ASCOM dome chooser in TSX. Not sure why yet.

I'm also not sure why TSX can't display the proper settings dialog once connected whereas POTH can.

We still need the help of a proper ASCOM coder and C# coder (I kind of can do some as it's very close to C++ but I'm sure a real C# coder would find and fix the issues in no time).

New code is here :



Question - in my logs there is a aweful lot ot time spent polling the rain sensor. I don't have the hardware for it so I'd rather it never check. Might there be a way we could rem out the rainsensor in our firmware? 90% of my logs are rain status F0.



Jan 20

The code always check and as there is no rain sensor I made the shield to report that it's not raining so that we don't have to make special firmware.

Of course you can always comment the rain check code from the firmware but I believe the log you're seeing is in the ASCOM driver which is really where it should be disabled.


when it does a NAME GET PDMnexdome, or a VERSION GET where is it "GETTING" from? from the firmware code?

Jan 20

Are we talking about ASCOM here ?

Version get is basicaly asking to the Arduino what code version it's running using the v# command (and also the V# for the shutter version).

Also when I run the terminal to Arduino... and connect to the com port. I use to sit and wait for a command. What it does now is continually reports back Shutter rain status F0#... OVER AND OVER non stop? I Can't even send a command. Any idea what could cause this? If I clear output it continues. I get no CR or LF though I select I want one. Just one line of shutter rain status F0#shutter rain status F0#.... over and over non stop?


Jan 20Edited: Jan 21

You're connecting to the shutter or the rotator ?

My last 2.1 code has all debug disabled ( here : ).

the F0 should only be sent every 30 seconds or so.

If I connect to the rotator Arduino it does nothing until I enter a command.

If I connect to the shutter Arduino and debug are enable I see the rain check every 30 seconds or so and if debug are disable I see nothing (it will respond to some commands).

So you shouldn't see anything from the rotator unless you enter a command, and certainly not a deluge of F0#


also when we see shutter get setup info Is that pulling out the motor settings we've entered previous? Speed, accel and steps?


Jan 20Edited: Jan 20

internal void GetSetupInfo() line 899

it sends a set of command to get all the data and if canSetShutter is true it also get the shutter data.

So the answer is yes.



Jan 21

So in Driver.cs, all checks are done in this method :


        private void OnStatusUpdateTimer(object source, EventArgs e)
            if (canSetShutter == true)

            if (slowUpdateCounter >= 30)
                tl.LogMessage("Slow update", "Get");
                slowUpdateCounter = 0;
                if (canSetShutter)

The bold line is the line that sends the command to the rotator sensor to check for the sensor status.

If you don't want it to check you need to disable this line.


You might want to get the version of the ASCOM code and the firmwares from the new repo as a few things have changed (hopefully for the better) :

This is now the official place for the firmware and ASCOM driver. I'm not updating any of the old PDM code.


New Posts
  • This is the process i go through to get to the speed settings for the shutter, so a few questions: First I open ascom dome control panel I click connect. Of course it doesnt let you change values unless its disconnected, so i disconnect and reopen the nexdome ascom server monitoring window, hit setup: Seems no matter what values i put below, here 600/1500 etc, the speed of the shutter is the same. I had tried lowering these at first to see if it would help with the motor sticking. Is this the right procedure to lower the values and test? Also, i know there is a much longer thread here about updating the firmware on the shutter/rotator, but, what does the update firmware button here do? At one point i clicked it when only the rotator was connected, it claimed it updated? How do i know if i even need to update either? Both came brand new recently? Thanks in advance
  • I've completed the motor install (although i may be missing parts on the motor related to this, the set key that holds the pin in place was missing, found an m4 for now that seems to hold it but the pin doesnt go in fully, see this thread for more details) First issue (or maybe not), when i push the motor and it moves up, i think when the panel that has the band through it goes under the first panel, half way up, it sticks for a half second, flexes and pops and keeps going. After this at times on the way up, even during the first half, sometimes the motor stalls briefly. The biggest issue is after its up fully and you bring it down, the first 16" or so going back it stalls and moans repeatedly, however, interestingly i can work it forward by doing an on off real quick multiple times, OR by pressing upward on the motor. Here is a video clip of the stalling (most of it near the end): At this point i took all the wheels off the rear, added washers, so now they have quite a bit of flex available. The retention bracket is installed, but i had my son work the motor while i pulled back on the bracket and wheel on one side only, no change. When you pull the panels in the rear when its up there, apart, you can see grinding marks on each panel on the sides. So at this point i'm left with removing the retention brackets on both sides as a final test, and to be able to get the panels apart to add antifriction tape someone recommended. It appears the front panels will need to come off (not the rear solid non moving one), then apply tape as here: Here is an external view of the situation: This is the antifriction tape i've ordered (1" x 15 feet, two rolls,TapeCase 423-5 UHMW) : I dont know what else to try, other than what i have planned at this point. Pretty frustrated. Incidentally, i have the inside dome rotation working pretty solidly, so this is the only sticking point, pun intended. Thanks in advance.
  • Im breaking my shutter issues into multi parts here, in this one, i seem to be missing the set screw on the part by the gear as in this image: The part circled was naturally coming out. I'd like to get the official part to fix this, however in the meantime i've added what seems to mostly fit but not flush, m4 set screw and the locking pin goes in a tad further: Any suggestions here? From someone else, it appears that pin should slide all the way inside (i dont know if this could be related to the motor stalling/sticking issue i have (sep thread))