English Instruction and operation manual S 415 Thermal mass flow sensor Dear Customer, Thank you for choosing our product. Please read the operating instructions in full and carefully observe them before you start up the device. The manufacturer cannot be held liable for any damage which occurs as a result of non-observance or non-
compliance with this manual. Should the device be tampered with in any manner other than a procedure which is described and specified in the manual, the warranty is canceled and the manufacturer is exempt from liability. The device is destined exclusively for the described application. SUTO offers no guarantee for the suitability for any other purpose. SUTO is also not liable for consequential damage resulting from the delivery, capability or use of this device. 2 S 415 1 Safety instructions......................................................................4 2 RF Exposure Information and Statement........................................6 3 Application.................................................................................7 4 Features....................................................................................7 5 Technical data.............................................................................8 5.1 General................................................................................8 5.2 Electrical data.......................................................................9 5.3 Output-signals......................................................................9 5.4 Accuracy .............................................................................9 6 Dimensional drawing..................................................................10 7 Installation...............................................................................11 7.1 Installation considerations....................................................11 7.2 Electrical connection ..........................................................11 8 Sensor signal outputs................................................................12 8.1 Analog output.....................................................................12 8.2 Pulse output.......................................................................13 8.2.1 Pulse Connection Diagram...............................................14 8.3 Modbus output....................................................................15 9 Configuration............................................................................16 10 Calibration..............................................................................17 11 Disposal or waste....................................................................17 12 Warranty................................................................................17 13 Appendix A Specifications......................................................19 13.1 Flow ranges......................................................................19 13.2 Error code.........................................................................20 14 Appendix B - Modbus communication example............................21 15 Appendix C - LRC and CRC calculation........................................23 S 415 3 Safety instructions 1 Safety instructions Please check if this instruction manual accords to the product type. Please observe all notes and instructions indicated in this manual. It contains essential information which must be observed before and during installation, operation and maintenance. Therefore this instruction manual must be read carefully by the technician as well as by the responsible user / qualified personnel. This instruction manual must be available at the operation site of the dew point sensor at any time. In case of any obscurities or questions, regarding this manual or the product, please contact the manufacturer. WARNING!
Compressed air!
Any contact with quickly escaping air or bursting parts of the compressed air system can lead to serious injuries or even death!
Do not exceed the maximum permitted pressure range (see sensors label). Only use pressure tight installation material. Avoid that persons get hit by escaping air or bursting parts of the instrument. The system must be pressureless during maintenance work. WARNING!
Voltage used for supply!
Any contact with energized parts of the product, may lead to a electrical shock which can lead to serious injuries or even death!
Consider all regulations for electrical installations. The system must be disconnected from any power supply during maintenance. Any electrical work on system is only allowed by authorized qualified personal. 4 S 415 Safety instructions WARNING!
Permitted operating parameters!
Observe the permitted operating parameters, any operation exceeding this parameters can lead to malfunctions and may lead to damage on the instrument or the system. Do not exceed the permitted operating parameters. Make sure the product is operated in its permitted limitations. Do not exceed or undercut the permitted storage and operation temperature and pressure. The product should be maintained and calibrated frequently, at least annually. General safety instructions It is not allowed to use the product in explosive areas. Please observe the national regulations before/during installation and operation. Remarks It is not allowed to disassemble the product. ATTENTION!
Measurement values can be affected by malfunction!
The product must be installed properly and frequently maintained, otherwise it may lead to wrong measurement values, which can lead to wrong results. Always observe the direction of the flow when installing the sensor. The direction is indicated on the housing. Do not exceed the maximum operation temperature at the sensors tip. Avoid condensation on the sensor element as this will affect accuracy enormously. Storage and transportation Make sure that the transportation temperature is between -30 C ... 70 C, S 415 5 Safety instructions For storage and transportation it is recommended to use the packaging which comes with the sensor. Please make sure that storage temperature of the sensor is between -10 C ... 50 C. Avoid direct UV and solar radiation during storage. For the storage the humidity has to be <90%, no condensation. 2 RF Exposure Information and Statement This equipment complies with FCC RF radiation exposure limits set forth for an uncontrolled environment. This equipment should be installed and operated with minimum distance of 20 cm between the radiator and your body. This device complies with part 15 of the FCC rules. Operation is subject to the following two conditions: (1) this device may not cause harmful interference, and (2) this device must accept any interference received, including interference that may cause undesired operation. NOTE: The manufacturer is not responsible for any radio or TV interference caused by unauthorized modifications to this equipment. Such modifications could void the users authority to operate the equipment. NOTE: This equipment has been tested and found to comply with the limits for a Class B digital device, pursuant to part 15 of the FCC Rules. These limits are designed to provide reasonable protection against harmful interference in a residential installation. This equipment generates uses and can radiate radio frequency energy and, if not installed and used in accordance with the instructions, may cause harmful interference to radio communications. However, there is no guarantee that interference will not occur in a particular installation. If this equipment does cause harmful interference to radio or television reception, which can be determined by turning the equipment off and on, the user is encouraged to try to correct the interference by one or more of the following measures:
6 S 415 RF Exposure Information and Statement
- Reorient or relocate the receiving antenna.
- Increase the separation between the equipment and receiver.
-Connect the equipment into an outlet on a circuit different from that to which the receiver is connected.
-Consult the dealer or an experienced radio/TV technician for help
-This device and its antenna(s) must not be co-located or operating in conjunction with any other antenna or transmitter. 3 Application The S 415 is a thermal mass flow sensor which is designed to measure the consumption of compressed air and nitrogen within the permissible operating parameters. These parameters can be found in the technical data section. The S 415 can measure Volumetric flow of the compressed air or N2. The default factory settings are: Volumetric flow in l/min and total Consumption in m3. Other units can be programmed by the service App S4C-FS which can be downloaded from the Google Play. 4 Features Inline thermal mass flow sensor virtually independent of pressure and temperature changes Process connection G-type thread, DN8, DN15, DN20 and DN25 Very short response time Particularly suitable for measuring at point of use flow and consumption of compressed air or N Integrated display showing volumetric flow 2 Choices of output signals:
Analogue 4 20 mA and pulse output Modbus interface M-Bus interface Bluetooth interface for sensor settings Configurable through Android devices S 415 7 Features 5 Technical data 5.1 General FCC ID: 2ASK2-SUTO-002 Parameters Reference conditions Standard unit flow: l/min Consumption units: m (default) ISO1217 20 C 1000 mbar (Standard-Unit) DIN1343 0 C 1013.25 mbar (Norm-Unit) Principle of measurement Thermal mass flow Sensor Measuring medium Operating temperature Humidity of the meas. medium Operating pressure Pressure drop Glass coated resistive sensor Air, N2 0 ... 50 C fluid temperature and casing
< 90%, no condensation 0 ... 1.0 MPa Maximum pressure drop at the maximum flow of standard calibration range:
DN8 type : 30 hPa DN15 type: 100 hPa DN20 type: 100 hPa DN25 type: 200 hPa Casing Protection class Dimensions Display Tube diameter Process connection Weight Process connection: aluminum alloy Wetted parts: aluminum alloy Top casing: PC + ABS IP54 See dimensional drawing on the next page 4-digit LED display DN8, DN15, DN20, DN25 G inner thread ISO 228-1 0.45 kg (DN8), 0.44 kg (DN15) 0.97 kg (DN20), 0.94 kg (DN25) 8 S 415 Technical data 5.2 Electrical data Power supply 5.3 Output-signals Analogue output Pulse output Modbus output 5.4 Accuracy Accuracy Temperature coefficient Pressure coefficient Turndown ratio Stated accuracy at Repeatability Sampling rate 15 ... 30 VDC, 120 mA @ 24 VDC Signal: 4 ... 20 mA, isolated Scaling: 0 to max flow Max load: 250R 1 pulse per m3 , isolated switch, max. 30 VDC, 200 mA
(pulse length: 10 ... 120 ms, depends on flow rate) See Modbus output. 3.0% of reading 0.3% F.S. (Full Scale)
< 0.1%/K F.S.
<0.5% / bar 50 : 1 Ambient/process temperature 23 C 3 C Ambient/process humidity <90%
Process pressure at 0.6 MPa 1% of reading 3 samples / second S 415 9 6 Dimensional drawing Dimensional drawing A (mm) B (mm) DN 8/15 DN 20/25 35.0 48.0 48.0 61.0 C (mm) 120.4 178.0 D (mm) E (mm) 35.0 48.0 93.0 106.0 10 S 415 Installation 7 Installation S 415 is delivered with following components:
Qty. Description 1 1 1 1 S 415 Thermal mass flow meter 5 m cable with M8 connector and open ends Instruction manual Calibration certificate Item no. S695 4150 S695 4151 S695 4152 S695 4153 A553 0136 No P/N No P/N 7.1 Installation considerations In order to maintain the accuracy stated in the technical data, the sensor must be installed inline and fitted to tubes with the same diameter. The sensor is for indoor use only! At an outdoor installation, the sensor must be protected from solar radiation and rain. It is strongly recommend not to install S 415 permanently in wet environment as it exists usually right after a compressor outlet. 7.2 Electrical connection The flow sensor is equipped with two Connector plugs A and B. By default the sensor is delivered with one 5 m cable with a M8 connector on one side and open wires on the other side. To operate the S 415 one cable connection is sufficient however if the pulse output is to be used or the supply and signal should be on separate cables a second connection cable has to be ordered. S 415 11 Installation Legend to pin assignment GND: Ground for Modbus
-VB: Negative supply voltage
+VB: Positive supply voltage I+:
I-:
Positive 4...20 mA signal Negative 4... 20 mA signal D+: Modbus data +
Modbus data -
D-:
P:
Pulse signal M:
M-Bus data NA: Not applicable Pin assignment connector plug M8 Output Version Modbus Connector Pin 1 D-
D-
I-
I-
M M Pin 2
-VB GND
-VB P
-VB NA brown white A B A B A B Pin 3
+VB GND
+VB P
+VB NA blue Pin 4 D+
D+
I+
I+
M M black Pulse and analog M-Bus Wire color 8 Sensor signal outputs 8.1 Analog output The sensor has an analog output range of 4 ... 20 mA. This output can be scaled to match a desired measuring range. Standard scaling is from 0 to max flow. The corresponding flow in different pipe sizes can be found in the Appendix section. 12 S 415 Sensor signal outputs 8.2 Pulse output The sensor will send out one pulse per consumption unit. This pulse output can be connected to an external pulse counter to count the total consumption. The number of m3 per second are summed up and indicated after one second. Pulse length depends on flow rate. Volumetric flow
[m3/s]
Volumetric flow
[m3/h]
Pulse length
[ms]
3
> 3
> 6 10800
> 10800
> 21600 120 60 30 Max. pulse output per hour 1080 2880 3960 S 415 13 8.2.1 Pulse Connection Diagram Variant 1:
Sensor signal outputs Variant 2:
14 S 415 Sensor signal outputs
: RTU
: 19200
: 1 8.3 Modbus output Mode Baud rate Device address Framing / parity / stop bit : 8, N, 1 Response timeout Response delay Inter-frame spacing Remark
: 1 second
: 0 ms
: 7 char Modbus communication settings can be changed by the service app S4C-FS To learn more about Modbus communication, see Appendix B -
Modbus communication example and Appendix C - LRC and CRC calculation. Index Channel description Resolution Format Length 1 2 Flow Consumption 0.1 1 FLOAT UNIT32 4 Byte 4 Byte Modbus address 6 8 Remarks All numbers are in little-endian format. Function code: 03. The measurement value is always available in the programmed physical unit. S 415 15 9 Configuration Configuration Please download the service app from the Google Play Store in case you need to have any settings changed on the S 415. The app is running on any Android system with Bluetooth supported. To change settings the app needs to scan the QR code on the calibration certificate at first. This ensures that only valid users can access the sensor settings. Follow the instructions in the service app. ATTENTION!
Changes on the settings may lead to wrong measurement results! Contact manufacturer in case you are not familiar with the settings. 16 S 415 Calibration Calibration 10 The sensor is calibrated ex work. The exact calibration date is printed on the certificate which is supplied together with the sensor. The accuracy of the sensor is regulated by the on site conditions, parameters like oil, high humidity or other impurities can affect the calibration and furthermore the accuracy. However we recommend to calibrate the instrument at least once per year. The calibration is excluded from the instruments warranty. For this please contact the manufacturer. 11 Disposal or waste Electronic devices are recyclable material and do not belong in the household waste. The sensor, the accessories and its packing must be disposed according to your local statutory requirements. The dispose can also be carried by the manufacturer of the product, for this please contact the manufacturer. 12 Warranty SUTO provides a warranty for this product of 24 months covering the material and workmanship under the stated operating conditions from the date of delivery. Please report any findings immediately and within the warranty time. If faults occurring during the warranty time SUTO will repair or replace the defective unit, without charge for labour and material costs but there is a charge for other service such as transport and packing costs. Excluded from this warranty is:
Damage caused by:
Improper use and non-adherence to the instruction manual. Use of unsuitable accessories. External influences (e.g. damage caused by vibration, damage during transportation, excess heat or moisture). S 415 17 Warranty The warranty is canceled:
If the user opens the measurement instrument without a direct request written in this instruction manual. If repairs or modifications are undertaken by third parties or unauthorized persons. If the serial number has been changed, damaged or removed. Other claims, especially those for damage occurring outside the instrument are not included unless responsibility is legally binding. Warranty repairs do not extend the period of warranty. ATTENTION!
Batteries have a reduced warranty time of 12 month. 18 S 415 Appendix A Specifications 13 Appendix A Specifications 13.1 Flow ranges Flow ranges in sl/min of air at ISO 1217: 20C and 1000 mbar:
DN25 DN20 DN15 DN8 Size Standard range (S) Low range (L) 0 250 50 1 1000 200 2 2000 400 3 3500 700 Flow ranges in sl/min of N2 at 0C and 1013.25 mbar:
DN20 DN15 DN8 Size Standard range (S) Low range (L) 0 222 44.5 1 890 178 2 1780 356 DN25 3 3110 622 Order no. S695 415 A1453 A1450 A1451 A1452 S 415 Order Table (Air and N2 only) Size Range Output Description 0 1 2 3 S 415, thermal mass flow meter, 3% o.RDG., 24 VDC DN8 G inner thread DN15 G inner thread DN20 G inner thread DN25 G inner thread Standard range version of S415 Low range version of S 415 Analogue 4 20 mA, pulse Digital Modbus/RTU Digital M-Bus S L A B C 19 Appendix A Specifications 13.2 Error code When an error code shows on the LED display, use the following table to identify the error cause. Error code Er. 01 Er. 02 Er. 04 Er. 08 Er. 10 Er. 20 Er. 30 Er. 40 Er. 50 Description Real time clock failure ADC failure EEPROM failure NADN flash failure Pressure sensor failure Flow sensor failure Temperature sensor failure Bluetooth failure Logger failure 20 S 415 Appendix B - Modbus communication example 14 Appendix B - Modbus communication example 03 (0x03) Read holding register Request Slave address Function code Starting address Hi Starting address Lo No. of points Hi No. of points Lo CRC 1 byte 1 byte 1 byte 1 byte 1 byte 1 byte 2 bytes 05 (0x05) Write single coil Request Slave address Function code Coil address Hi Coil address Lo Data Hi Data Lo CRC 1 byte 1 byte 1 byte 1 byte 1 byte 1 byte 2 bytes Response Slave address Function code Byte count Register Hi Register Lo
:
Register Hi Register Lo CRC Response Slave address Function code Coil address Hi Coil address Lo Data Hi Data L CRC 1 byte 1 byte 1 byte 1 byte 1 byte
:
1 byte 1 byte 2 bytes 1 byte 1 byte 1 byte 1 byte 1 byte 1 byte 2 bytes S 415 21 16 (0x10) Write multiple registers Appendix B - Modbus communication example Request Slave address Function code Starting address Hi Starting address Lo No. of registers Hi No. of registers Lo Byte count Data Hi Data Lo
:
Data Hi Data Lo CRC 1 byte 1 byte 1 byte 1 byte 1 byte 1 byte 1 byte 1 byte 1 byte
:
1 byte 1 byte 2 bytes 17 (0x11) Report slave ID Request Slave address Function code CRC 1 byte 1 byte 2 bytes Response Slave address Function code Starting address Hi Starting address Lo No. of registers Hi No. of registers Lo CRC 1 byte 1 byte 1 byte 1 byte 1 byte 1 byte 2 bytes Response Slave address Function code Byte count Slave ID Device run indicator Product code Product name CRC 1 byte 1 byte 1 byte 2 bytes 2 bytes 2 bytes 20 bytes 2 bytes 22 S 415 Appendix C - LRC and CRC calculation Appendix C - LRC and CRC calculation 15 LRC generation The Longitudinal Redundancy Checking (LRC) field is one byte, containing an 8bit binary value. The LRC value is calculated by the transmitting device, which appends the LRC to the message. The device that receives recalculates an LRC during receipt of the message, and compares the calculated value to the actual value it received in the LRC field. If the two values are not equal, an error results. The LRC is calculated by adding together successive 8bit bytes in the message, discarding any carries, and then twos complementing the result. The LRC is an 8bit field, therefore each new addition of a character that would result in a value higher than 255 decimal simply rolls over the fields value through zero. Because there is no ninth bit, the carry is discarded automatically. A procedure for generating an LRC is:
1. Add all bytes in the message, excluding the starting colon and ending CRLF. Add them into an 8bit field, so that carries will be discarded. 2. Subtract the final field value from FF hex (all 1s) to produce the onescomplement. 3. Add 1 to produce the twoscomplement. Placing the LRC into the Message When the 8bit LRC (2 ASCII characters) is transmitted in the message, the highorder character will be transmitted first, followed by the low order character. For example, if the LRC value is 61 hex (0110 0001):
Colon Addr Func Data CR LF Count Data Data Data Data LRC Hi 6 0x36 LRC Lo 1 0x31 Example: an example of a C language function performing LRC generation is shown below. The function takes two arguments:
unsigned char *auchMsg; /* A pointer to the message buffer containing binary data */
/* to be used for generating the LRC, */
unsigned short usDataLen; /* The quantity of bytes in the message buffer. */
S 415 23 Appendix C - LRC and CRC calculation LRC generation function static unsigned char LRC(unsigned char *auchMsg, unsigned short usDataLen)
{
unsigned char uchLRC = 0 ; /* LRC char initialized */
while (usDataLen) /* pass through message buffer */
uchLRC += *auchMsg++ ; /* add buffer byte without carry */
return ((unsigned char)(((char)uchLRC))) ; /* return twos complement */
}
CRC generation The Cyclical Redundancy Checking (CRC) field is two bytes, containing a 16-bit binary value. The CRC value is first generated by the transmitting device, which appends the CRC to the message. The device that receives recalculates a CRC during receipt of the message, and compares the calculated value to the actual value it received in the CRC field. If the two values are not equal, an error results. There are many ways of calculating a CRC checksum. To ensure correct calculation, please refer to [Reference 1] Modbus over serial line, where detailed descriptions and programming examples are available. Even more information and programming examples in different programming languages can be found on: www.modbus.org searching for CRC. Below is a short text description of how the CRC is calculated. This description is then followed by a C programming example. 1. Load a 16-bit register with FFFF hex (all 1s). Call this the CRC register. 2. Exclusive OR the first 8-bit byte of the message with the low-order byte of the 16-bit CRC register, putting the result in the CRC register. 3. Shift the CRC register one bit to the right (toward the LSB), zero-
filling the MSB. Extract and examine the LSB. 4. (If the LSB was 0): Repeat step 3 (another shift). (If the LSB was 1): Exclusive OR the CRC register with the polynomial value 0xA001 (1010 0000 0000 0001). 5. Repeat steps 3 and 4 until 8 shifts have been performed. When this is done, a complete 8-bit byte will have been processed. 6. Repeat steps 2 through 5 for the next 8-bit byte of the message. Continue doing this until all bytes have been processed. 7. The final content of the CRC register is the CRC value. 24 S 415 Appendix C - LRC and CRC calculation 8. When the CRC is placed into the message, its upper and lower bytes must be swapped as described below. Placing the CRC into the message When the 16-bit CRC (two 8-bit bytes) is transmitted in the message, the low-order byte will be transmitted first, followed by the high-order byte. For example, if the CRC value is 1241 hex (0001 0010 0100 0001):
Addr Func Data count Data Data Data Data CRC Lo CRC Hi 0x41 0x12 High-order byte table
/* Table of CRC values for highorder byte */
static unsigned char auchCRCHi[] = {
0x00, 0xC1, 0x81, 0x40, 0x01, 0xC0, 0x80, 0x41, 0x01, 0xC0, 0x80, 0x41, 0x00, 0xC1, 0x81, 0x40, 0x01, 0xC0, 0x80, 0x41, 0x00, 0xC1, 0x81, 0x40, 0x00, 0xC1, 0x81, 0x40, 0x01, 0xC0, 0x80, 0x41, 0x01, 0xC0, 0x80, 0x41, 0x00, 0xC1, 0x81, 0x40, 0x00, 0xC1, 0x81, 0x40, 0x01, 0xC0, 0x80, 0x41, 0x00, 0xC1, 0x81, 0x40, 0x01, 0xC0, 0x80, 0x41, 0x01, 0xC0, 0x80, 0x41, 0x00, 0xC1, 0x81, 0x40, 0x01, 0xC0, 0x80, 0x41, 0x00, 0xC1, 0x81, 0x40, 0x00, 0xC1, 0x81, 0x40, 0x01, 0xC0, 0x80, 0x41, 0x00, 0xC1, 0x81, 0x40, 0x01, 0xC0, 0x80, 0x41, 0x01, 0xC0, 0x80, 0x41, 0x00, 0xC1, 0x81, 0x40, 0x00, 0xC1, 0x81, 0x40, 0x01, 0xC0, 0x80, 0x41, 0x01, 0xC0, 0x80, 0x41, 0x00, 0xC1, 0x81, 0x40, 0x01, 0xC0, 0x80, 0x41, 0x00, 0xC1, 0x81, 0x40, 0x00, 0xC1, 0x81, 0x40, 0x01, 0xC0, 0x80, 0x41, 0x01, 0xC0, 0x80, 0x41, 0x00, 0xC1, 0x81, 0x40, 0x00, 0xC1, 0x81, 0x40, 0x01, 0xC0, 0x80, 0x41, 0x00, 0xC1, 0x81, 0x40, 0x01, 0xC0, 0x80, 0x41, 0x01, 0xC0, 0x80, 0x41, 0x00, 0xC1, 0x81, 0x40, 0x00, 0xC1, 0x81, 0x40, 0x01, 0xC0, 0x80, 0x41, 0x01, 0xC0, 0x80, 0x41, 0x00, 0xC1, 0x81, 0x40, 0x01, 0xC0, 0x80, 0x41, 0x00, 0xC1, 0x81, 0x40, 0x00, 0xC1, 0x81, 0x40, 0x01, 0xC0, 0x80, 0x41, 0x00, 0xC1, 0x81, 0x40, 0x01, 0xC0, 0x80, 0x41, 0x01, 0xC0, 0x80, 0x41, 0x00, 0xC1, 0x81, 0x40, 0x01, 0xC0, 0x80, 0x41, 0x00, 0xC1, 0x81, 0x40, 0x00, 0xC1, 0x81, 0x40, 0x01, 0xC0, 0x80, 0x41, 0x01, 0xC0, 0x80, 0x41, 0x00, 0xC1, 0x81, 0x40, 0x00, 0xC1, 0x81, 0x40, 0x01, 0xC0, 0x80, 0x41, 0x00, 0xC1, 0x81, 0x40, 0x01, 0xC0, 0x80, 0x41, 0x01, 0xC0, 0x80, 0x41, 0x00, 0xC1, 0x81,0x40
} ;
Low-order byte table
/* Table of CRC values for loworder byte */
static char auchCRCLo[] = {
0x00, 0xC0, 0xC1, 0x01, 0xC3, 0x03, 0x02, 0xC2, 0xC6, 0x06, 0x07, 0xC7, 0x05, 0xC5, 0xC4, 0x04, 0xCC, 0x0C, 0x0D, 0xCD, 0x0F, 0xCF, 0xCE, 0x0E, 0x0A, 0xCA, 0xCB, 0x0B, 0xC9, 0x09, 0x08, 0xC8, 0xD8, 0x18, 0x19, 0xD9, 0x1B, 0xDB, 0xDA, 0x1A, 0x1E, 0xDE, 0xDF, 0x1F, 0xDD, 0x1D, 0x1C, 0xDC, 0x14, 0xD4, 0xD5, 0x15, 0xD7, 0x17, 0x16, 0xD6, 0xD2, 0x12, 0x13, 0xD3, 0x11, 0xD1, 0xD0, 0x10, 0xF0, 0x30, 0x31, 0xF1, 0x33, 0xF3, 0xF2, 0x32, 0x36, 0xF6, 0xF7, 0x37, 0xF5, 0x35, 0x34, 0xF4, 0x3C, 0xFC, 0xFD, 0x3D, 0xFF, 0x3F, 0x3E, 0xFE, 0xFA, 0x3A, 0x3B, S 415 25 Appendix C - LRC and CRC calculation 0xFB, 0x39, 0xF9, 0xF8, 0x38, 0x28, 0xE8, 0xE9, 0x29, 0xEB, 0x2B, 0x2A, 0xEA, 0xEE, 0x2E, 0x2F, 0xEF, 0x2D, 0xED, 0xEC, 0x2C, 0xE4, 0x24, 0x25, 0xE5, 0x27, 0xE7, 0xE6, 0x26, 0x22, 0xE2, 0xE3, 0x23, 0xE1, 0x21, 0x20, 0xE0, 0xA0, 0x60, 0x61, 0xA1, 0x63, 0xA3, 0xA2, 0x62, 0x66, 0xA6, 0xA7, 0x67, 0xA5, 0x65, 0x64, 0xA4, 0x6C, 0xAC, 0xAD, 0x6D, 0xAF, 0x6F, 0x6E, 0xAE, 0xAA, 0x6A, 0x6B, 0xAB, 0x69, 0xA9, 0xA8, 0x68, 0x78, 0xB8, 0xB9, 0x79, 0xBB, 0x7B, 0x7A, 0xBA, 0xBE, 0x7E, 0x7F, 0xBF, 0x7D, 0xBD, 0xBC, 0x7C, 0xB4, 0x74, 0x75, 0xB5, 0x77, 0xB7, 0xB6, 0x76, 0x72, 0xB2, 0xB3, 0x73, 0xB1, 0x71, 0x70, 0xB0, 0x50, 0x90, 0x91, 0x51, 0x93, 0x53, 0x52, 0x92, 0x96, 0x56, 0x57, 0x97, 0x55, 0x95, 0x94, 0x54, 0x9C, 0x5C, 0x5D, 0x9D, 0x5F, 0x9F, 0x9E, 0x5E, 0x5A, 0x9A, 0x9B, 0x5B, 0x99, 0x59, 0x58, 0x98, 0x88, 0x48, 0x49, 0x89, 0x4B, 0x8B, 0x8A, 0x4A, 0x4E, 0x8E, 0x8F, 0x4F, 0x8D, 0x4D, 0x4C, 0x8C, 0x44, 0x84, 0x85, 0x45, 0x87, 0x47, 0x46, 0x86, 0x82, 0x42, 0x43, 0x83, 0x41, 0x81, 0x80, 0x40
};
unsigned short CRC16(unsigned char *puchMsg, unsigned short usDataLen){
unsigned char uchCRCHi = 0xFF; /* high byte of CRC initialized
*/
unsigned char uchCRCLo = 0xFF; /* low byte of CRC initialized
*/
unsigned uIndex ; /* will index into CRC lookup table */
while(usDataLen) /* pass through message buffer */
{
uIndex = uchCRCHi ^ *puchMsg++ ; /* calculate the CRC */
uchCRCHi = uchCRCLo ^ auchCRCHi[uIndex] ;
uchCRCLo = auchCRCLo[uIndex] ;
}
return (unsigned short int)((uchCRCHi << 8) | uchCRCLo);
}
26 S 415 S 415 27 SUTO iTEC GmbH SUTO iTEC (ASIA) Co., Ltd. Werkstr. 2 Room 10, 6/F, Block B, Cambridge Plaza 79426 Buggingen 188 San Wan Road, Sheung Shui, N.T. Germany Hong Kong Tel: +49 (0) 7631 936889-0 Fax: +49 (0) 7631 936889-19 Email: sales@suto-itec.com Website: http://www.suto-itec.com Website: http://www.suto-itec.com Tel: +852 2328 9782 Fax: +852 2671 3863 Email: sales@suto-itec.asia All rights reserved Modifications and errors reserved. S415_im_en_2018-2 28 S 415