background image

~ 14 ~ 

NOVATEK-ELECTRO

    

                                                                                                                

PEF-

321АВР

 

Bytes are transmitted at speed of 2400, 4800, 9600, 14400 and 19200 bps. By default, during manufacture, 

the device is configured to operate at a speed of 9600 bps. 

 

Note 

for 

MODBUS RTU

 mode, 8 data bits are transmitted, and for 

MODBUS ASCII

 mode, - 7 data bits are 

transmitted. 

 

6.3.2.2 Frame format 

In the 

MODBUS RTU

 mode, the start and end of the frame are controlled using silence intervals of at least 

3.5 bytes transmission time. The frame should be transmitted as a continuous stream of bytes. The correctness 
of the frame acceptance is further controlled by checking the CRC checksum. 

The address field takes up one byte. Addresses of the slave devices are in the range from 1 to 247. 

Figure 9 shows the RTU frame format. 

 

Silence interval 

>3.5 bytes 

Address 

Function code 

Data 

CRC checksum 

Silence interval 

>3.5 bytes 

1 byte 

1 byte 

Up to 50 bytes 

2 bytes 

 

Fig. 9

 - RTU frame format 

 

In the 

MODBUS ASCII

 mode, the start and end of the frame are controlled using special characters (symbol 

(„:‟  0x3A)  –  to  start  the  frame;  characters  („CRLF‟  0x0D0x0A)  –  to  end  the  frame).  The  frame  should  be 
transmitted  as  a  continuous  stream  of  bytes.  The  correctness  of  the  frame  acceptance  is  further  controlled  by 
checking the LRC checksum. 

The address field takes up two bytes. Addresses of the slave devices are in the range from 1 to 247. 
Figure 10 shows the ASCII frame format. 

 

1 byte 

Address 

Function code 

Data 

CRC checksum 

CRLF 

2 bytes 

2 bytes 

2 bytes 

Up to 504 bytes 

2 bytes 

 

Fig. 10

 - ASCII frame format 

 

Note -

 

in the 

MODBUS ASCII

 mode, each byte of data is encoded with two bytes of ASCII code (for example: 

1 byte of data 0x25 is encoded with two bytes of ASCII code 0x32 and 0x35). 

 

6.3.3 Generation and verification of a checksum 

The  transmitting  device  generates  a  checksum  for  all  bytes  of  the  transmitted  message.  321

АВР  similarly 

generates a checksum for all bytes of the received message and compares it with the checksum received from 
the  transmitting  device.  If  the  generated  checksum  does  not  match  the  accepted  one,  an  error  message  is 
generated. 

 

6.3.3.1 CRC checksum generation 

The checksum in the message is transmitted in the lower byte forward; it is a cyclic check code based on the 

irreducible polynomial 0xA001. 

The subroutine for generating CRC checksum is in C language: 

 

1:    uint16_t GenerateCRC(uint8_t *p

СendRecvBuf, uint16_t uCount) 

2:    { 
3:        con

с uint16_t Polynom = 0xA001; 

4:        uint16_t crc = 0xFFFF; 
5:        uint16_t i; 
6:        uint8_t byte; 
7:        for(i=0; i<(uCount-2); i++){ 
8:            crc = crc ^ p

СendRecvBuf[i]; 

9:            for(byte=0; byte<8; byte++){ 
10:              if((crc& 0x0001) == 0){ 
11:                  crc = crc>> 1; 
12:              }el

сe{ 

13:                 crc = crc>> 1; 
14:                 crc = crc ^ Polynom; 
15:             } 
16:          } 
17:      } 
18:      returncrc; 
19:   } 

 

6.3.3.2 LRC checksum generation 

The checksum in the message is transmitted in high byte forward, which is a longitudinal redundancy check. 

 
 
 

Summary of Contents for PEF-321ABP

Page 1: ...m on the development and production complies with requirements ISO 9001 2015 Dear customer Company NOVATEK ELECTRO LTD thanks you for purchasing our products You will be able to use properly the produ...

Page 2: ...AL ELEMENTS OF THE PRODUCT During operation and maintenance the regulatory document requirements must be met namely Regulations for Operation of Consumer Electrical Installations Safety Rules for Oper...

Page 3: ...vervoltage category III Rated insulation voltage V 450 Rated impulse withstand voltage kV 4 0 Wire cross section for connecting to terminals mm2 0 5 2 Tightening torque of terminal screws N m 0 4 Tabl...

Page 4: ...frame self extinguishing plastic No harmful substances in amount that exceeds permissible exposure limits Table 3 Characteristics of output contacts Used terminals Max current at U 250 V A Number of...

Page 5: ...to power the device or connect the generator 7 8 9 10 11 not involved 31 the second phase of input 2 to power the device or connect the generator 12 13 the state of voltage at input 1 32 the third pha...

Page 6: ...ECTIONS MUST BE PERFORMED WITH THE DEVICE BEING DEENERGIZED An error in installation work may result in damage of the device and instruments connected to it To ensure reliability of electrical connect...

Page 7: ...f operation 321 supports 6 operating modes two equivalent three phase inputs two three phase inputs with priority input 1 two three phase inputs with priority input 2 three phase input 1 and a three p...

Page 8: ...input 1 by contactor K1 and counts the transition time to the secondary input table 5 3 After completion of the 321 time countdown device 321 closes terminals 20 21 sends a signal to start the generat...

Page 9: ...d configure other menu items In order to exit the menu press and hold the OK button for 3 s If no button is pressed within 30 s the menu will exit automatically Table 5 Menu Menu Value Name Descriptio...

Page 10: ...SCII 1 RTU MODBUS modes 134 Parity check parity check is off even parity check odd parity check 135 Number of stop bits or 136 Transfer rate transfer rate 2400 baud transfer rate 4800 baud transfer ra...

Page 11: ...d order dot is lighting 13 14 Phase voltage of phase 3 Low order dot is lighting 15 16 Linear voltage of phases 1 2 High order dot is flashing 17 18 Linear voltage of phases 2 3 Mid order dot is flash...

Page 12: ...s not lighting no voltage 400 AC 16 17 Optotransistor Availability of the battery Is not lighting the battery is disconnected Is lighting the battery is connected 280 AC 400 DC 18 19 Optotransistor Th...

Page 13: ...ite the value to 321 The coefficient of reduction to an integer value is determined by a number of decimal places 1 0 10 1 00 100 1 000 1000 Table 13 Error codes for the MODBUS protocol Error code Nam...

Page 14: ...s Addresses of the slave devices are in the range from 1 to 247 Figure 10 shows the ASCII frame format 1 byte Address Function code Data CRC checksum CRLF 2 bytes 2 bytes 2 bytes Up to 504 bytes 2 byt...

Page 15: ...tion 0x06 provides writing to one 321ABP register The master s request contains the address of the register and data for entering The answer of the device coincides with the request of the master unit...

Page 16: ...ored at the temperature from minus 45 to 60 C and relative humidity of no more than 80 10 ACCEPTANCE CERTIFICATE PEF 321 has been manufactured and accepted in accordance with the requirements of valid...

Reviews: