Applies To:
  • CitectSCADA 1.00 1.01 1.10 1.11 1.20 2.00 2.01 3.00

Summary:
Question: I am writing a new driver using the Citect DDK, should I have in my definitions (.DEF) file? 

Solution:
The best way to build a new driver is to copy the source code from an existing driver. The Driver Tool Kit contains example code for working drivers which you can use as a basis for new drivers. Below is a listing of the DEF file for the modbus driver.

LIBRARY  MODBUS
EXETYPE  WINDOWS
CODE     PRELOAD
DATA     PRELOAD SINGLE
HEAPSIZE 1024
EXPORTS
   WEP @1 RESIDENTNAME
   _Driver @2

For new drivers you should only change the library name. It is very important not to change the existing entries in the EXPORTS section. Citect uses the ordinal number to reference the driver entry point. Changing the ordinal numbers will prevent Citect from calling the driver DLL entry point and may cause a General Protection Fault.

 

Keywords:
 

Attachments