@WSAR1-V1@@COMMENT@I-87017Z/7017Z 20-CH. A/I@DPS@ 2)b[:Us_~'jpٍ!uTM=Y *kcDumPy& qS`mPy& yR:-K\~_M=Y *kr@q]ͽpٍ!|Y]|UͽpTcDy:@NOTE@| i7017z20 connect to remote I/O modules i-7017Z (http://www.icpdas.com/products/Remote_IO/i-7000/i-7017z.htm) i-87017ZW (http://www.icpdas.com.tw/product/solutions/remote_io/rs-485/i-8k&i-87k/i-87017zw.html) *** Target : Target 1: I-8417/8817/8437/8837 , I-7188EG , I-7188XG Target 2: W-8xx7/8xx6 Target 3: uPAC-7186EG Target 4: iPAC-8x47 Target 5: WinPAC-8xx7 / 8xx6 Target 6: VP-25W7 / 23W7 / 25W6 / 23W6 Target 7: XP-8xx7-CE6 / XP-8xx6-CE6 Target 8: VP-2117 Note: If using "i7017z20", the software setting of I-7017Z/I-87017ZW must be set as "Single-End" Differential mode can be used for voltage input and current input Single-Ended mode can be used for voltage input only. ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Important: (1) Since driver version of I-8xx7:4.02 , I-7188EG:3.02 , I-7188XG:3.02 , W-8xx7:3.44 ,uPAC-7186EG : 1.01 (2) Please use DCON utility of Ver. 5.2.0 or advanced version download at your I-8000 CD-ROM or http://ftp.icpdas.com/pub/cd/8000cd/napdos/driver/dcon_utility/ to configure each channel's type code setting before using them. (3) i-7017z/i-87017ZW is better than i-7017/i-87017 & i-7017R/i-87017RC because (A) Each channel can use different range type setting. (B) Channel: 10 differential or 20 single-ended. (C) Insert the 125ohm resistor for the jumper selection (D) Accuracy is better. ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ ******** PLEASE SET i-7017Z/I-87017ZW to "2's Complement" by DCON utility Ver. 5.2.0 or advanced version *********** Channels : 20 Analog input call: ADR_ : integer the address of this I/O modules (1-255), must be a constant value , not a variable return: Q_ : boolean work ok.:TRUE " IF Q_ IS FALSE , IT MEANS COMMUNICATION IS BAD, THE FOLLOWING RETURN VALUE HAS NO MEANING. " NI1_ ~ NI10_ : integer Analog input value of channel 1 ~ 10 Min ---> ---> Max -32768 0 32767 notes(Very Important): before connection please .... on I/O module side, please using "DCON utility Ver.5.0.0" : 1 Set "address" to a unique No. (1~255) 2.Set configuration table with "no checksum" and "2's complement" 3.Set communication parameter to a "baud rate" and "8,N,1" 4.Set "Input range" on I-8xx7/I-7188EG/I-7188XG/uPAC-7186EG & W-8xx7 side: 1.Connect I/O complex equipment "bus7000b" and set its "baud rate" equal to the setting "baud rate" of I/O module 2.max to Target1: 64 (Target 2: 255) remote I/O modules can be connected 3.use each i_7*** function block to connect to I/O modules ICP DAS , Taiwan Aug.12,2011 @PARAM@#AQ_ #A>NI1_ #A>NI2_ #A>NI3_ #A>NI4_ #A>NI5_ #A>NI6_ #A>NI7_ #A>NI8_ #A>NI9_ #A>NI10_ #A>NI11_ #A>NI12_ #A>NI13_ #A>NI14_ #A>NI15_ #A>NI16_ #A>NI17_ #A>NI18_ #A>NI19_ #A>NI20_ @SRC@/* function block name: i_7017 */ #include #include typedef struct { } str_data; uint16 FBINIT_i_7017 (uint16 hinstance) { return (sizeof (str_data)); } void FBACT_i_7017 (uint16 hinstance, str_data *data, str_arg *arg) { } #define BOO_VALUE ((T_BOO *)value) #define ANA_VALUE ((T_ANA *)value) #define REAL_VALUE ((T_REAL *)value) #define TMR_VALUE ((T_TMR *)value) #define MSG_VALUE ((T_MSG *)value) void FBREAD_i_7017 (uint16 hinstance, str_data *data, uint16 parno, void *value) { } ABP fbldef_i_7017 (char *name, IBP *initproc, RBP *readproc) { sys_strcpy (name, "I_7017"); *initproc = (IBP)FBINIT_i_7017; *readproc = (RBP)FBREAD_i_7017; return ((ABP)FBACT_i_7017); } @DEFS@/* function block interface name: i7017z20 */ typedef long T_BOO; typedef long T_ANA; typedef float T_REAL; typedef long T_TMR; typedef char *T_MSG; typedef struct { /* CALL */ T_ANA _adr_; } str_arg; #define ADR_ (arg->_adr_) #define FBLPNO_Q_ 0 #define FBLPNO_NI1_ 1 #define FBLPNO_NI2_ 2 #define FBLPNO_NI3_ 3 #define FBLPNO_NI4_ 4 #define FBLPNO_NI5_ 5 #define FBLPNO_NI6_ 6 #define FBLPNO_NI7_ 7 #define FBLPNO_NI8_ 8 #define FBLPNO_NI9_ 9 #define FBLPNO_NI10_ 10 #define FBLPNO_NI11_ 11 #define FBLPNO_NI12_ 12 #define FBLPNO_NI13_ 13 #define FBLPNO_NI14_ 14 #define FBLPNO_NI15_ 15 #define FBLPNO_NI16_ 16 #define FBLPNO_NI17_ 17 #define FBLPNO_NI18_ 18 #define FBLPNO_NI19_ 19 #define FBLPNO_NI20_ 20 @END@