ActiveX Interface

COM Registration

The EpicsCAServer.exe and EpicsCAClient.exe programs are "AxtiveX Automation Servers". They are self-registering when run with the "-RegServer" option. The supplied register.bat files do this for Win98, NT, Win2000.

To check the registration,

  1. run the "regedit" program. Under HKEY_CLASSES_ROOT you should find "EpicsCAServer.ProcessVariable" and "EpicsCAClient.ProcessVariable".
  2. Check e.g. the "EpicsCAServer.ProcessVariable/CLSID", it looks like "{5F190F33-E77D-11D2-8F1D-00105AC8D47C}".
  3. Browse to HKEY_CLASSES_ROOT/CLSID/{5F190F33-E77D-11D2-8F1D-00105AC8D47C}. Under there, you should find an entry for "LocalServer32" that points to the location of the executable EpicsCAServer.exe.

Usage

The syntax varies, but most Win32 programming languages have some means of connecting to an ActiveX automation server by name.
In Visual Basic, you use
Set PV = CreateObject("EpicsCAServer.ProcessVariable")
As a result, the Win32 operating system will locate the ActiveX Automation Server for this object ("COM Class") by looking at the registry, very similar to what's described in the previous section. Win32 will run that application and create a ProcessVariable in there.
This example, where the string for the object name is passed, is called late binding.
Alternatively, many languages allow you to create a "Reference" to the EpicsCAServer.ProcessVariable. You can then directly call "New" on this type, the compiled code will use the CLSID and directly access methods and properties vai their numerical codes/offsets instead of querying by name.
LabVIEW has an "Automation Open" VI. When clicking on this, you can select the EpicsCAServer/Client ProcessVariable. After wiring the result to the invoke or property nodes, you can select the method to invoke or property to change.
For Visual Basic, you can view the methods and properties on the Object Browser after establishing a reference.
Read the ActiveX section of the manual for your program to learn more.

EpicsCAServer.ProcessVariable

You should use your programming tools' object browser to see what methods and properties are actually accessible. In general, the result should be similar to this:

EpicsCAClient.ProcessVariable

Again, check your programming tools' object browser.