Developing for 32- and 64-bits

Running on a 64-bit Windows operating system does not mean all applications and ASCOM drivers are 64-bit. Most astronomy applications (except camera controllers for large format cameras) run under the 32-bit subsystem, and use 32-bit drivers. They are unaware that they are running on a 64-bit system. This is a technical miracle from Microsoft.

The ASCOM architecture supports both 32- and 64-bit environments, however there is a great deal of confusion and old wives' tales surrounding this area. It's beyond the scope of this article to give general information on the 32- and 64-bit subsystems in Windows. What is important to driver writers, though, is that the implementation of COM (see About ASCOM) is separate for 32- and 64-bit applications and drivers.

As of Platform 7 we have removed templates for DLL type drivers where a 32-bit application cannot use a 64-bit DLL driver, and vice versa. We supply templates only for EXE type drivers (so-called LocalServers) which are bitness-proof. An EXE driver can be either a 32-bit or -64 bit executable, and be used by both 32-bit and 64-bit applications.