William Kane / Generic

Dependents:   LaserioLib

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers abcc_crc16.h Source File

abcc_crc16.h

00001 /*******************************************************************************
00002 ********************************************************************************
00003 **                                                                            **
00004 ** ABCC Driver version 4.01.01 (2015-12-14)                                   **
00005 **                                                                            **
00006 ** Delivered with:                                                            **
00007 **    ABP         7.16.01 (2015-10-14)                                        **
00008 **                                                                            */
00009 /*******************************************************************************
00010 ********************************************************************************
00011 ** COPYRIGHT NOTIFICATION (c) 2013 HMS Industrial Networks AB                 **
00012 **                                                                            **
00013 ** This code is the property of HMS Industrial Networks AB.                   **
00014 ** The source code may not be reproduced, distributed, or used without        **
00015 ** permission. When used together with a product from HMS, permission is      **
00016 ** granted to modify, reproduce and distribute the code in binary form        **
00017 ** without any restrictions.                                                  **
00018 **                                                                            **
00019 ** THE CODE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. HMS DOES NOT    **
00020 ** WARRANT THAT THE FUNCTIONS OF THE CODE WILL MEET YOUR REQUIREMENTS, OR     **
00021 ** THAT THE OPERATION OF THE CODE WILL BE UNINTERRUPTED OR ERROR-FREE, OR     **
00022 ** THAT DEFECTS IN IT CAN BE CORRECTED.                                       **
00023 ********************************************************************************
00024 ********************************************************************************
00025 ** File Description:
00026 ** This is the public header file for the CRC calculation routines.
00027 ********************************************************************************
00028 ********************************************************************************
00029 ** Services:
00030 **
00031 **    CRC_Crc16()                   - CRC16 checksum calculation function.
00032 ********************************************************************************
00033 ********************************************************************************
00034 */
00035 
00036 #ifndef CRC16_H
00037 #define CRC16_H
00038 
00039 #include "abcc_drv_cfg.h"
00040 #include "abcc_td.h"
00041 
00042 /*******************************************************************************
00043 **
00044 ** Typedefs
00045 **
00046 ********************************************************************************
00047 */
00048 
00049 /*******************************************************************************
00050 **
00051 ** Public Services
00052 **
00053 ********************************************************************************
00054 */
00055 
00056 /*---------------------------------------------------------------------------
00057 **
00058 ** CRC_Crc16()
00059 **
00060 ** Calculates a CRC16 checksum on the indicated bytes.
00061 **
00062 **---------------------------------------------------------------------------
00063 **
00064 ** Inputs:
00065 **    pbBufferStart            - Where to start calculation
00066 **    iLength                  - The amount of bytes to include
00067 **
00068 ** Outputs:
00069 **    Returns                  - The calculated CRC16 checksum
00070 **
00071 ** Usage:
00072 **    iCrc = CRC_Crc16( pbStart, 20 );
00073 **
00074 **---------------------------------------------------------------------------
00075 */
00076 
00077 EXTFUNC UINT16 CRC_Crc16( UINT8* pbBufferStart, UINT16 iLength );
00078 
00079 
00080 #endif  /* inclusion lock */
00081 
00082 
00083 /*******************************************************************************
00084 **
00085 ** End of crc.h
00086 **
00087 ********************************************************************************
00088 */