SM Controller Communication Driver

 

SM Controller is driver to communicate with controller for Electricity/Lighting.

 

1. Read settings

 

<Figure 1> is read setting example of SM Controller communication driver.

<Figure 1> Read setting example of SM Controller communication driver

Device part of  <Figure 1> input Device type (TCP/IP), IP address of equipment(192.168.0.1), Service port(5000) respectively, according to device setting.

Also, input the delay time of reading after writing(0 ~ 10,000 mSec, Default = 2000) at Option part.

 

SM Controller communication driver's read schedule

Read schedule setting parameters are as follows:

1)    STATION – Device number between 0 and 255.

2)    Read command – Input the command among B, D, E, H, J, P, T, a and Blank(or etc letter). (Refer to <Table 1>)

In case of setting the read command as blank(or etc letter), save the data which is Total data/Initialization of electrical fire measurement data and Event.

But, add the reading, as following format.

;READ,     1,     E,     0,    0,   1,         // Save command of reading total data

;READ,     1,     P,     0,  200,   1,          // Save command of reading electrical fire measurement data.

3)    Read start address – Don't care.

4)    Save start address for Communication Server – Saving start address of Communication Server.

5)    Read size - The number of data to read. Fixed to 1. Read size is fixed according to read command.

 

Read schedule example)

READ,     1,     D,     0,    0,   1,

 

<Table 1> is read command type and save address of read value, of SM Controller communication driver. 

Read Command

Contents

Save Address for Communication Memory

Remarks

B

Reading Polling Unit

Save Addr + 0 : Polling Unit value

Device number between 0 and 255

D

Reading Unit

Save Addr + 0 : AD quantity(0 ~ 6, 0 = Don't care)

Save Addr + 1 : Relay quantity(0 ~ 6, 0 = Don't care)

Save Addr + 2 : Asd quantity(0 ~ 3, 0 = Don't care)

Save Addr + 3 : Whether to use PSW(1 = Use)

Save Addr + 4 ~ 387 : PSW Unit Mapping

PSW Unit Mapping(384 WORD) = 32(PSW quantity) x 4(cct quantity) x  3 (Relay information)

E

Reading Total Data

Save Addr + 0 : Current time Year-2000

Save Addr + 1 ~ 5 : Current time Month, Day, Hour, Min, Sec

Save Addr + 6 : Door status(1 = Lock, 0 = Open)

Save Addr + 7 : Relay control mode status

(0:Auto, 1:Control, 2:Menu, 3:PB)

Save Addr + 8 ~ 23 : PSW status(WORD)

Save Addr + 24 ~ 26 : Relay status(WORD)

Save Addr + 27 ~ 29 : Lighting/Lights-out status(WORD)

Save Addr + 30 : Board DC voltage(Real value x 10)

Save Addr + 31 : Battery voltage(Real value x 10)

Save Addr + 32 ~ 35 : R/S/T phase voltage(Real value x 10)

Save Addr + 36 ~ 83 : CT 48circuit 5min measurement value

Save Addr + 84 ~ 131 : ZCT 48circuit 5min measurement value

Board DC/Battery/R/S/T voltage =

Read value / Calculate as 10

H

Reading Total Wattage

Save Addr + 0 ~ 47 : CT 48circuit total wattage(DWORD)

Save Addr + 48 ~ 95 : ZCT 48circuit total wattage(DWORD)

J

Reading Environment

Save Addr + 0 : Current time Year-2000

Save Addr + 1 ~ 5 : Current time Month, Day, Hour, Min, Sec

Save Addr + 6 ~ 53 : Lighting time by circuit(WORD, 48 circuit)

Save Addr + 54 ~ 101 : Lights-out time by circuit(WORD, 48 circuit)

Save Addr + 102 ~ 149 : CT 48circuit error value(WORD)

Save Addr + 150 ~ 197 : ZCT 48circuit error value(WORD)

If Lighting/Lights out is 0,  always light on

P

Reading Electrical Fire Measurement

Save Addr + 0 : Current time Year-2000

Save Addr + 1 ~ 5 : Current time Month, Day, Hour, Min, Sec

Save Addr + 6 ~ 8 : R/S/T phase voltage(Real value x 10)

Save Addr + 9 ~ 56 : Arc 48 circuit(WORD)

Save Addr + 57 ~ 104 : Short circuit 48 circuit(WORD)

Save Addr + 105 ~ 152 : Current 48 circuit(WORD)

Save Addr + 153 ~ 200 : Temp 48 circuit(WORD)

Save Addr + 201 ~ 395: R/S/T and Arc/Short circuit/Current/Temp

Number of error for each 48(BYTE)

T

Reading Environment Setting of Electrical Fire

Save Addr + 0 : Current time Year-2000

Save Addr + 1 ~ 5 : Current time Month, Day, Hour, Min, Sec

Save Addr + 6 ~ 8 : R/S/T phase voltage standard value(Real value x 10)

Save Addr + 9 ~ 56 : Arc 48 circuit standard value(WORD)

Save Addr + 57 ~ 104 : Short circuit 48 circuit standard value(WORD)

Save Addr + 105 ~ 152 : Current 48 circuit standard value(WORD)

Save Addr + 153 ~ 200 : Temp 48 circuit standard value(WORD)

Save Addr + 201 ~ 395: R/S/T and Arc/Short circuit/Current/Temp

Monitoring- time for each 48(WORD)

a

Reading Status Value of Circuit Breaker Failure Analysis Device

Save Addr + 0 : Circuit breaker model(0x10:ACB, 0x20:VCB,

0x30:VCS, 0x40:ATS, 0x50:BAT)

Save Addr + 1 : Circuit breaker motion type(0x00:Open, 0x01:Close,

0x02:motor, 0x04:stroke, 0x08:reserved)

Save Addr + 2 : Circuit breaker motion time Year-2000

Save Addr + 3 ~ 7 : Circuit breaker motion time Month, Day, Hour, Min, Sec

Save Addr + 8 : Circuit breaker diagnosis contents(Refer to remarks)

Save Addr + 9 : Motion trip time(Float data)

Save Addr + 10 : Motion trip peak current (Float data)

Save Addr + 11 : Motion trip RMS current (Float data)

Save Addr + 12 : Motion trip voltage (Float data)

Circuit breaker diagnosis contents by bit

0x00:Normal

0x01:Circuit breaker motion time abnormality

0x02:Circuit breaker motion current abnormality

0x04:Circuit breaker motion voltage abnormality

0x08, 0x10, 0x20, 0x40, 0x80:reserved

<Table 1> Read command type and save address of read value, of SM Controller communication driver

SM Controller communication driver's read value is saved at same address of WORD/DWORD/FLOAT memory(Only type of saved value is different) as same value.

If you click the icon 2 in protocol option part at <Figure 1>, you can see the dialog box such as <Figure 2>. You can also set read schedule by using this part.

<Figure 2> Example of SM Controller driver's dialog box
 

You can set read schedule by using 3, 4, 5 button and listbox of <Figure 2>.

Also, delay time of reading after writing can be set at 'Write After Sleep' area of <Figure 2>.

<Figure 3> Example of SM Controller driver's read schedule Add/Edit dialog box

When you click Add button or Edit button in dialog box of <Figure 2>, dialog box of <Figure 3> is shown.

 

2. Writing settings

You can control Relay etc by using writing settings.

 

Digital Write

Digital write and analog write have the same setting parameters except output value(0 or 1).

 

Analog Write

Analog write setting parameters are as follows:

1)  PORT                  Connected port number. (Not COM number)

2)  STATION                           Device number between 0 and 255.

3)  ADDRESS     Writing address according to Command(Extra1). (Refer to <Table 1> and <Table 2>)

B, D, E, H, J, P, T, a : Start address for read value,

L : Relay number between 1 and 48,

C : Addressing writing between 0 and 387,

I : Addressing writing between 0 and 197,

S : Addressing writing between 0 and 395.

Etc command : Don't care.

4)  Extra1                 Input the read command of B, D, E, H, J, P, T, a or writing command of A, L, z, C, I, S.

                                 B, D, E, H, J, P, T, a  : Refer to <Table 1> about read command, save address and save contents,

                                 A : Set Polling Unit, Input Unit value to designate the output value between 0 and 255,

                                 L : 1 circuit Relay control, control the designated ADDRESS(1 ~ 48) Relay(ON = 1, OFF = Output value of 0)

                                 z : Communication Check Command,

                                 C : Main Sub Unit Setting,

                                 I : Preference command,

                                 S : Preference command of electrical fire device,

                                 K : Control total Relay(If output value is 0, OFF the total Relay. If output value is 1, ON the total Relay).

5)  Extra2                  Don't care.

 

Block Write

Set the block write as follows, by using PlcScanWriteBlock function of script. Block write can use C, I and S command only.

Script name and format : @PlcScanWriteBlock(int port, int station, int address, string extra1, string extra2, object array_value, int array_size);

Example of writing script

ushort   writeVal[5];

 

writeVal[0] = 15;

writeVal[1] = 16;

writeVal[2] = 17;

writeVal[3] = 18;

writeVal[4] = 19;

@PlcScanWriteBlock(0, 1, 10, ¡°C¡±, ¡°¡±, writeVal, 5);

 

Importance) Block write only support C, I, S write command. Also, block write is supported from over 10.1.4.3 version.

 

Reference) C, I and S writing command(include block write) output the command by changing the designated write address value only, after reading current value by using D, J and T command.

 

<Table 2> is writing command type and writing parameter value of SM Controller communication driver.

Writing command Contents

Address setting range

Output value

A Polling Unit Setting

Don't care.

0 ~ 255

L 1 Circuit Relay Control

Relay number between 1 and 48

0 = OFF, 1 = ON

z Communication Check Command

Don't care.

Don't care

C Main Sub Unit Setting

0 : AD Quantity,

1 : Relay Quantity,

2 : ASD Quantity,

3 : Whether to use PSW,

4~ 387 : PSW Unit Mapping

0 ~ 6, 0 = Don't care,

0 ~ 6, 0 = Don't care,

0 ~ 3 0 = Don't care,

0 = Don't care, 1 = Use,

Mapping value of WORD unit

I Preference Command

0 ~ 5 : Set current time of computer,

6 ~ 101 : Lighting/Lights out time by circuit

102 ~ 197 : CT/ZCT error value

Don't care,

Lighting/Lights out(Each 48) of WORD unit,

CT/ZCT error value(Each 48) of WORD unit

S Preference Command of Electrical Fire Device

0 ~ 5 : Set current time of computer,

6 ~ 8 : R/S/T phase voltage(Real value/10),

9 ~ 200 : Arc/Short circuit/Current/Temp standard value,

201 ~ 395 : R/S/T/Arc/Short circuit/Current/Temp monitoring time

Don't care,

R/S/T value of WORD unit,

Arc/Short circuit/Current/Temp standard value (Each 48) of WORD unit,

R/S/T/Arc/Short circuit/Current/Temp monitoring time WORD unit

K Control Total Relay

Don't care

0 = Total Relay OFF, 1 = Total Relay ON

<Table 2> Writing command type and writing parameter value of SM Controller communication driver

Write example 1)

PORT : 0   STATION : 1   ADDRESS : 0001  EXTRA1 : L  EXTRA2 : 0

If you set as above and write analog value, you can do ON/OFF(ON = Output value 1, OFF = Output value 0) the no.1 Relay of SM Controller device connected with no.0 port.

 

33. Communication cable connection of SM Controller device

Connect communication cable and basic power of SM Controller device, as follows.

 

Communication cable connection

Connect adequate UTP communication cable etc to Ethernet terminal of SM Controller device.

1.png
<Figure 4> Appearance of SM Controller device

Basic power connection

Connect AC basic power to power input part of SM Controller device.