Siemens RVD120, RVD140 with 1 stopbit
Detaljer
Beskrivning
This is a script for Siemens RVD120 and RVD140 controllers for district heating and d.h.w.
Based on version 1.0
This is a read only script, for writing values please contact Abelko.
Bruksanvisning
OBS! This script require a software patch from Siemens setting the unit to 1 Stop bit
Set communication to 8 bit, No parity and 1 stop bit
Juridisk information
Alla skript tillhandahålls i befintligt skick och all användning sker på eget ansvar. Felaktig använding kan leda till skadad eller förstörd utrustning.
Skript kod
% Skapad med Modbus Creator
DEVICETYPE RVD NAMED "RVD" TYPEID 21457 IS
PARAMETER
Id : "Adress";
PUBLIC
V1 : "Heating Curve Slope" [""]DEC2;
V2 : "Paralell displacement of heating curve" [""]DEC2; % 1/64
V3 : "DHW Operation mode" [""]; % 1=on, 0= off
V4 : "SP DHW temp normal" [""]; % 1/64, unit depends on plant type
V5 : "SP DHW temp reduced" [""]; % 1/64, unit depends on plant type
V6 : "DHW temp sensor" [""]; % 0 = d.h.w. storage tank / no circulating pump 1 = heat exchanger, heat losses partly compensated (80 %) 2 = heat exchanger, heat losses fully compensated (100 %)
V7 : "Q7/Y8 Relay contact" [""]; % 0 = de-energized 1 = energized
V8 : "VS1 Pump" [""]; % 0 = de-energized 1 = energized
V9 : "K7 Relay contact" [""]; % 0 = de-energized 1 = energized
V10 : "B9 Outside Sensor" ["?C"]DEC1; % 1/64
V11 : "B1 Flow sensor" ["?C"]DEC1; % 1/64
V12 : "B3 DHW/Storagetank 1 sensor" ["?C"]DEC1; % 1/64
V13 : "A6 Room unit sensor" ["?C"]DEC1; % 1/64
PRIVATE
count3;
tmp;
BAUDRATE 9600;
CHECKSUM MODBUS SWAPPED;
TELEGRAM Read3 NAMED "Read 3" IS
QUESTION
DATA[0] := BYTE(Id); % Enhetens Modbus adress
DATA[1] := HEX(03); % Modbus kommando för att läsa register
DATA[2] <- RWORD(
IF(count3>12) THEN count3 := 0; ENDIF;
IF (count3=0) THEN tmp := 213;
ELSIF (count3=1) THEN tmp := 221;
ELSIF (count3=2) THEN tmp := 241;
ELSIF (count3=3) THEN tmp := 242;
ELSIF (count3=4) THEN tmp := 243;
ELSIF (count3=5) THEN tmp := 1027;
ELSIF (count3=6) THEN tmp := 1040;
ELSIF (count3=7) THEN tmp := 1036;
ELSIF (count3=8) THEN tmp := 1042;
ELSIF (count3=9) THEN tmp := 1044;
ELSIF (count3=10) THEN tmp := 1045;
ELSIF (count3=11) THEN tmp := 1046;
ELSIF (count3=12) THEN tmp := 1047;
ENDIF;
DATA:= tmp;
);
DATA[4] := RWORD(01);
ANSWER SIZE 7
DATA[0] = BYTE(Id);
DATA[1] = BYTE(03);
DATA[3] -> RWORD(
IF (count3=0) THEN IF (DATA>=32768) THEN V1:=(DATA-65536)/100; ELSE V1:=DATA/100; ENDIF;
ELSIF (count3=1) THEN IF (DATA>=32768) THEN V2:=(DATA-65536)/64; ELSE V2:=DATA/64; ENDIF;
ELSIF (count3=2) THEN IF (DATA>=32768) THEN V3:=(DATA-65536); ELSE V3:=DATA; ENDIF;
ELSIF (count3=3) THEN IF (DATA>=32768) THEN V4:=(DATA-65536)/64; ELSE V4:=DATA/64; ENDIF;
ELSIF (count3=4) THEN IF (DATA>=32768) THEN V5:=(DATA-65536)/64; ELSE V5:=DATA/64; ENDIF;
ELSIF (count3=5) THEN IF (DATA>=32768) THEN V6:=(DATA-65536); ELSE V6:=DATA; ENDIF;
ELSIF (count3=6) THEN IF (DATA>=32768) THEN V7:=(DATA-65536); ELSE V7:=DATA; ENDIF;
ELSIF (count3=7) THEN IF (DATA>=32768) THEN V8:=(DATA-65536); ELSE V8:=DATA; ENDIF;
ELSIF (count3=8) THEN IF (DATA>=32768) THEN V9:=(DATA-65536); ELSE V9:=DATA; ENDIF;
ELSIF (count3=9) THEN IF (DATA>=32768) THEN V10:=(DATA-65536)/64; ELSE V10:=DATA/64; ENDIF;
ELSIF (count3=10) THEN IF (DATA>=32768) THEN V11:=(DATA-65536)/64; ELSE V11:=DATA/64; ENDIF;
ELSIF (count3=11) THEN IF (DATA>=32768) THEN V12:=(DATA-65536)/64; ELSE V12:=DATA/64; ENDIF;
ELSIF (count3=12) THEN IF (DATA>=32768) THEN V13:=(DATA-65536)/64; ELSE V13:=DATA/64; ENDIF;
ENDIF;
count3 := count3+1;
);
TIMEOUT 300
END;
END;
DEVICETYPE RVD NAMED "RVD" TYPEID 21457 IS
PARAMETER
Id : "Adress";
PUBLIC
V1 : "Heating Curve Slope" [""]DEC2;
V2 : "Paralell displacement of heating curve" [""]DEC2; % 1/64
V3 : "DHW Operation mode" [""]; % 1=on, 0= off
V4 : "SP DHW temp normal" [""]; % 1/64, unit depends on plant type
V5 : "SP DHW temp reduced" [""]; % 1/64, unit depends on plant type
V6 : "DHW temp sensor" [""]; % 0 = d.h.w. storage tank / no circulating pump 1 = heat exchanger, heat losses partly compensated (80 %) 2 = heat exchanger, heat losses fully compensated (100 %)
V7 : "Q7/Y8 Relay contact" [""]; % 0 = de-energized 1 = energized
V8 : "VS1 Pump" [""]; % 0 = de-energized 1 = energized
V9 : "K7 Relay contact" [""]; % 0 = de-energized 1 = energized
V10 : "B9 Outside Sensor" ["?C"]DEC1; % 1/64
V11 : "B1 Flow sensor" ["?C"]DEC1; % 1/64
V12 : "B3 DHW/Storagetank 1 sensor" ["?C"]DEC1; % 1/64
V13 : "A6 Room unit sensor" ["?C"]DEC1; % 1/64
PRIVATE
count3;
tmp;
BAUDRATE 9600;
CHECKSUM MODBUS SWAPPED;
TELEGRAM Read3 NAMED "Read 3" IS
QUESTION
DATA[0] := BYTE(Id); % Enhetens Modbus adress
DATA[1] := HEX(03); % Modbus kommando för att läsa register
DATA[2] <- RWORD(
IF(count3>12) THEN count3 := 0; ENDIF;
IF (count3=0) THEN tmp := 213;
ELSIF (count3=1) THEN tmp := 221;
ELSIF (count3=2) THEN tmp := 241;
ELSIF (count3=3) THEN tmp := 242;
ELSIF (count3=4) THEN tmp := 243;
ELSIF (count3=5) THEN tmp := 1027;
ELSIF (count3=6) THEN tmp := 1040;
ELSIF (count3=7) THEN tmp := 1036;
ELSIF (count3=8) THEN tmp := 1042;
ELSIF (count3=9) THEN tmp := 1044;
ELSIF (count3=10) THEN tmp := 1045;
ELSIF (count3=11) THEN tmp := 1046;
ELSIF (count3=12) THEN tmp := 1047;
ENDIF;
DATA:= tmp;
);
DATA[4] := RWORD(01);
ANSWER SIZE 7
DATA[0] = BYTE(Id);
DATA[1] = BYTE(03);
DATA[3] -> RWORD(
IF (count3=0) THEN IF (DATA>=32768) THEN V1:=(DATA-65536)/100; ELSE V1:=DATA/100; ENDIF;
ELSIF (count3=1) THEN IF (DATA>=32768) THEN V2:=(DATA-65536)/64; ELSE V2:=DATA/64; ENDIF;
ELSIF (count3=2) THEN IF (DATA>=32768) THEN V3:=(DATA-65536); ELSE V3:=DATA; ENDIF;
ELSIF (count3=3) THEN IF (DATA>=32768) THEN V4:=(DATA-65536)/64; ELSE V4:=DATA/64; ENDIF;
ELSIF (count3=4) THEN IF (DATA>=32768) THEN V5:=(DATA-65536)/64; ELSE V5:=DATA/64; ENDIF;
ELSIF (count3=5) THEN IF (DATA>=32768) THEN V6:=(DATA-65536); ELSE V6:=DATA; ENDIF;
ELSIF (count3=6) THEN IF (DATA>=32768) THEN V7:=(DATA-65536); ELSE V7:=DATA; ENDIF;
ELSIF (count3=7) THEN IF (DATA>=32768) THEN V8:=(DATA-65536); ELSE V8:=DATA; ENDIF;
ELSIF (count3=8) THEN IF (DATA>=32768) THEN V9:=(DATA-65536); ELSE V9:=DATA; ENDIF;
ELSIF (count3=9) THEN IF (DATA>=32768) THEN V10:=(DATA-65536)/64; ELSE V10:=DATA/64; ENDIF;
ELSIF (count3=10) THEN IF (DATA>=32768) THEN V11:=(DATA-65536)/64; ELSE V11:=DATA/64; ENDIF;
ELSIF (count3=11) THEN IF (DATA>=32768) THEN V12:=(DATA-65536)/64; ELSE V12:=DATA/64; ENDIF;
ELSIF (count3=12) THEN IF (DATA>=32768) THEN V13:=(DATA-65536)/64; ELSE V13:=DATA/64; ENDIF;
ENDIF;
count3 := count3+1;
);
TIMEOUT 300
END;
END;
Användarnas noteringar
Du måste vara inloggad för att göra en notering. Bli medlem eller logga in. Vi använder en moderator som godkänner noteringarna innan de visas.