Seatex Seapath 200 Installation Manual, rev. 13
Appendix B – Output protocols from Seapath
63
The codes are:
N: Normal.
R: Reduced
accuracy.
I: Invalid.
NR: Normal or reduced accuracy.
6.15
Cyclic redundancy check algorithm
The 16-bit Block Cyclic Redundancy Check algorithm used to calculate the checksum in
some formats is described in C and Fortran source code below.
C code:
#define POLY 0x8408
unsigned short blkcrc(
unsigned char *bufptr, /* message buffer */
unsigned long len /* number of bytes */
)
{
unsigned char i;
unsigned short data;
unsigned short crc = 0xffff;
if (len == 0L) {
return ~crc;
}
do {
for (i=0, data = (unsigned short) (0xff & *+);
i < 8;
i++, data >>= 1) {
if ((crc & 0x0001) ^ (data & 0x0001)) {
crc = (crc >> 1) ^ POLY;
} else {
crc >>= 1;
}
}
} while (--len);
crc = ~crc;
data = crc;
crc = (crc << 8) | ((data >> 8) & 0xff);
return crc;
}
Fortran code:
SUBROUTINE blkcrc(inbuffer, len, crc)
INTEGER*2 len, i , bit
INTEGER*4 crc, data, poly
CHARACTER inbuffer*(*)
poly = 16#8408
crc = 16#FFFF
data = 0
Summary of Contents for Seatex Seapath 200
Page 1: ...Seatex Seapath 200 Installation Manual Issued 2008 06 09 ...
Page 2: ...Blank page ...
Page 4: ...IV Blank page ...
Page 6: ...VI Blank page ...
Page 10: ...X Blank page ...
Page 14: ...XIV Blank page ...
Page 18: ...Seatex Seapath 200 Installation Manual rev 13 Introduction 4 Blank page ...
Page 22: ...Seatex Seapath 200 Installation Manual rev 13 Specifications 8 Blank page ...
Page 53: ...Seatex Seapath 200 Installation Manual rev 13 Installation drawings 39 ...
Page 54: ...Seatex Seapath 200 Installation Manual rev 13 Installation drawings 40 ...
Page 55: ...Seatex Seapath 200 Installation Manual rev 13 Installation drawings 41 ...
Page 56: ...Seatex Seapath 200 Installation Manual rev 13 Installation drawings 42 ...
Page 64: ...Seatex Seapath 200 Installation Manual rev 13 Appendix A Installation worksheet 50 Blank page ...
Page 80: ...Seatex Seapath 200 Installation Manual rev 13 Appendix C Installation of coax connectors 66 ...
Page 81: ...Seatex Seapath 200 Installation Manual rev 13 Appendix C Installation of coax connectors 67 ...
Page 82: ...Seatex Seapath 200 Installation Manual rev 13 Appendix C Installation of coax connectors 68 ...
Page 83: ...Seatex Seapath 200 Installation Manual rev 13 Appendix C Installation of coax connectors 69 ...