Old fashion design for PC-104
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

41 lines
926 B

//----------------------------------------------------------------------------
// Laser Guard Ltd.
// Copyright © 2000-2002. All Rights Reserved.
// Version 1.0 01/01/2000
// Last modification: 17/10/2001
// PROJECT:
// SUBSYSTEM:
// FILE: CRC.H
// AUTHOR: Sergey Chizhevskiy
// OVERVIEW
// ~~~~~~~~
// Header file of CRC.H
//----------------------------------------------------------------------------
#ifndef __CRC__H__INCLUDED__
#define __CRC__H__INCLUDED__
#if _MSC_VER > 1000
#pragma once
#endif
#define INITIAL_CRC 0xFFFF
#define CRC_TABLE s_CRC16
class CCRC
{
public:
CCRC();
virtual ~CCRC();
public:
WORD Calculate( PBYTE pData, INT nCount );
WORD CalculateRev( PBYTE pData, INT nCount );
private:
static WORD s_CRC16[256];
static WORD s_CRC16_REV[256];
static WORD s_CRCCCITT[256];
static WORD s_CRCCCITT_REV[256];
};
#endif