
Doc: I297PLGB 1110 26/11/2010 s. 11 / 12
Wybór taryfy (grupa 252)
Mo
ż
liwy jest wybór aktywnej taryfy z poni
ż
szego zakresu:
o
DMG 800: od 1 do 4
o
DMG 900: od 1 do 8
By wykona
ć
ta operacj
ę
urz
ą
dzenie Master musi by
ć
ustawione jak
podano poni
ż
ej:
o
OUTPUT = 2
Przyk
ł
ad:
Bajt 1 0xFC
(252)
Bajt 2 0x03
(3)
wybór taryfy 3
Tariff selection (group 252)
It is possible to selct the active tariff, the possible range is:
o
DMG 800: from 1 to 4
o
DMG 900: from 1 to 8
To execute this operation the master device exchange memory
must be configured s follows:
o
OUTPUT = 2
Example:
Byte 1 0xFC
(252)
Byte 2 0x03
(3)
Tariff 3 selection
Pomiary konfigurowalne (grupa 255)
Urz
ą
dzenie typu Master (PLC, PC, SCADA) mo
ż
e decydowa
ć
, który
pojedynczy pomiar ma by
ć
odczytany z DMG, maksymalnie 8
pomiarów w tym samym czasie.
By wykona
ć
powy
ż
sz
ą
operacj
ę
urz
ą
dzenie Master musi by
ć
zaprogramowane w nast
ę
puj
ą
cy sposób:
WYJ
Ś
CIE = 2 + (2 x numer pomiaru)
WEJ
Ś
CIE = 2 + (4 x numer pomiaru)
Jak równie
ż
mo
ż
na wybra
ć
odpowiedni model od 20 do 27
z pliku LovatoXX.gsd:
Modu
ł
= Custom X Pomiary
Gdzie X oznacza numer pomiaru.
By wy
ś
wietla
ć
pomiary urz
ą
dzenie Master podaje na wyj
ś
ciu bajt
pami
ę
ci 1 z warto
ś
ci
ą
255 (numer grupy) i w drugim bajcie
ile pomiarów ma by
ć
odczytanych ( warto
ść
od 1 do 8).
W kolejnym bajcie nale
ż
y ustawi
ć
adres odczytu. Adres specyfikuje
si
ę
w ten sam sposób co w protoko
ł
ach Modbus. Mo
ż
na poda
ć
maksymalnie 8 adresów.
Na wej
ś
ciu, urz
ą
dzenie Master mo
ż
e odebra
ć
do 34 bajtów.
W pierwszym znajdowac si
ę
b
ę
dzie warto
ść
255 (numer grupy), drugi
jest bajtem statusu b
łę
du, gdzie ka
ż
dy pojedynczy bit wskazuje czy
wybrany pomiar jest wa
ż
ny czy nie. Na przyk
ł
ad, je
ś
li miernik DMG
wskazuje b
łą
d o kodzie 0x05 (binarnie 00000101) oznacza to,
ż
e adresy pomiarów 1 i 3 nie s
ą
dost
ę
pne. Je
ś
li kod b
łę
du to 0xFF,
oznacza to,
ż
e numer pomiarów nie jest wa
ż
ny lub wszystkie adresy
nie s
ą
wa
ż
ne.
Kolejne bajty zawieraj
ą
warto
ś
ci pomiarów, a ka
ż
dy pomiar zajmuje
4 bajty.
Przyk
ł
ad:
Odczyty napi
ę
cia fazowego L1 (adres Modbus 0x0002) i napi
ę
cia
fazowego L2 (adres Modbus 0x0004).
Wyj
ś
cie
Bajt 1 0xFF
(255)
konfigurowalna grupa pomiarów
Bajt 2 0x02
(2)
ilo
ść
pomiarów
Bajt 3 0x00
(0)
adres pierwszego pomiaru (MSB)
Bajt 4 0x02
(2)
adres pierwszego pomiaru (LSB)
Bajt 5 0x00
(0)
adres drugiego pomiaru (MSB)
Bajt 6 0x04
(4)
adres drugiego pomiaru (LSB)
Wej
ś
cie
Bajt 1 0xFF
(255)
Bajt 2 0x00
(0)
Bajt 3 0x00
(0)
Bajt 4 0x00
(0)
Bajt 5 0x5A
(90)
Bajt 6 0x8C
(140)
Bajt 7 0x00
(0)
Bajt 8 0x00
(0)
Bajt 9 0x5A
(90)
Bajt 10 0xBB
(187)
Napi
ę
cie fazowe L1 = 0x00005A8C = 23180 (tj. 231,80V).
Napi
ę
cie fazowe L2 = 0x00005ABB = 23227 (tj. 232,27V).
Warto
ś
ci nale
ż
y podzieli
ć
przez 100, jak podano w instrukcji Modbus
odno
ś
nie jednostki pomiaru.
Configuarable measures (group 255)
The master device can decide which single measures are to be
read from the DMG, with maximum 8 measures at the same time.
To execute this operation the master device exchange memory
must be configured s follows:
OUTPUT = 2 + (2 x measure Nr.)
INPUT = 2 + (4 x measure Nr.)
Otherwise it is possible to select from LovatoXX.GSD file one of the
modules from 20 to 27:
Module = Custom X Measures
Where X indicates the number of measures.
To visualize the measurements the master writes in the output
memory byte 1 value 255 (group number) and in byte 2 how many
measurements are to be read.
In the following byte sit is necessary to set the address of the
measurement. The address to be specified is the same as used
with modbus protocol. It is possible to specify max 8 addresses.
In input, the master can receive up to 34 bytes. The first will hold
value 255 (group number), the secondi is the error status
byte,where every single bits indicatesi f the selected measurement
is valid or not. For example, if the DMG returns error code 0x05 (
00000101 bin) it means that the address of measurement 1 and 3
are not available If error code is 0xFF, it means that the number of
measurements is not valid or all of the addresses are not valid.
The following bytes hold the values of the measurements, each of
them taking 4-bytes.
Example:
Reading of L1 phase voltage (modbus address 0x0002) and L2 phase
voltage (modbus address 0x0004) .
Output
Byte 1 0xFF
(255)
configurable measures group
Byte 2 0x02
(2)
measure number
Byte 3 0x00
(0)
address of first measure (MSB)
Byte 4 0x02
(2)
address of first measure (LSB)
Byte 5 0x00
(0)
address of second measure (MSB)
Byte 6 0x04
(4)
address of second measure (LSB)
Input
Byte 1 0xFF
(255)
Byte 2 0x00
(0)
Byte 3 0x00
(0)
Byte 4 0x00
(0)
Byte 5 0x5A
(90)
Byte 6 0x8C
(140)
Byte 7 0x00
(0)
Byte 8 0x00
(0)
Byte 9 0x5A
(90)
Byte 10 0xBB
(187)
L1 phase voltage = 0x00005A8C = 23180 (231.80V).
L2 phase voltage = 0x00005ABB = 23227 (232.27V).
Values must be divided by 100, as stated in the unit of measure of
modbus manual.