19.01.2013 Views

Citect for Windows Driver Specification DanBuss DNIP Driver

Citect for Windows Driver Specification DanBuss DNIP Driver

Citect for Windows Driver Specification DanBuss DNIP Driver

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

<strong>Driver</strong> Design <strong>Specification</strong><br />

variables from other function blocks).<br />

If bit 2 is set, then this variable will be of a ‘One Shot’ type. It will be read once (with same<br />

priority as all other new variables) and then it will be updated very slowly (once per hour is<br />

default, may be set in CITECT.INI)<br />

08 The function block type that this variable belongs to.<br />

21 The variable’s order in this function block (hex, it is equal to the last number in the template)<br />

5 The DANBUSS variable type, used internally <strong>for</strong> conversion.<br />

typedef enum MPTypes {<br />

MP_MPBLOCKNAME, /* = 18 byte */<br />

MP_AIPARAMETER, /* = 8 byte */<br />

MP_DIPARAMETER, /* = 6 byte */<br />

MP_AOPARAMETER, /* = 5 byte */<br />

MP_DOPARAMETER, /* = 3 byte */<br />

MP_ASPARAMETER, /* = 3 byte */<br />

MP_DSPARAMETER, /* = 2 byte */<br />

MP_PTRPARAMETER, /* = 4 byte */<br />

MP_DATPARAMETER, /* = 2 byte */<br />

MP_UTCPARAMETER /* = 4 byte */<br />

} MPTypes;<br />

4 <strong>Citect</strong>’s type, is used to indicate any special <strong>for</strong>mat <strong>for</strong> time presentation etc.<br />

typedef enum CITypes {<br />

CI_USERAW, // Results in the raw <strong>for</strong>mat, no conversion is made<br />

CI_UTCDATE, // Results in date string, <strong>for</strong>mat 1997-11-21 from UTC<br />

CI_UTCTIME, // Results in time string, <strong>for</strong>mat 21:15 from UTC<br />

CI_TIME // Results in time string, <strong>for</strong>mat 21:15 from int<br />

CI_STRWEEK // Results in time string, <strong>for</strong>mat 4 21:15 from int (4=weekday)<br />

} CITypes;<br />

This results in that this variable will be read only once (with very slow update, defaulted to once per<br />

hour). The driver will read the complete function block into the cache element’s data area. This<br />

means that if <strong>Citect</strong> asks <strong>for</strong> another variable within this function block at this device, it will read directly<br />

from the cache element’s data area, and not from the device.This variable should not be a<br />

ScanList member (a ScanList is the DANBUSS function that reads up to 36 variables in one request).<br />

This variable can not be a ScanList member, though it causes the driver to read the entire<br />

function block. The variable belongs to the function block type TIMCON (time program). The variable<br />

is number 33 (0x21) in this function block, it is of the DANBUSS type Analog Output, and will be<br />

converted to the CI_STRWEEK type in string <strong>for</strong>mat when passed to and from <strong>Citect</strong>.<br />

<strong>DanBuss</strong> <strong>DNIP</strong>.doc 10

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!