PCDIDE COMPILER Custom Computer Services Inc (CCS), PCDIDE COMPILER Datasheet - Page 75

PCD C-COMPILER PIC24, DSPIC

PCDIDE COMPILER

Manufacturer Part Number
PCDIDE COMPILER
Description
PCD C-COMPILER PIC24, DSPIC
Manufacturer
Custom Computer Services Inc (CCS)
Type
Compilerr
Datasheet

Specifications of PCDIDE COMPILER

For Use With/related Products
Microchip PIC24/dsPIC®
Lead Free Status / RoHS Status
Not applicable / Not applicable
Other names
429-1008
Relevant Interrupts :
None
Relevant Include Files:
None, all functions built-in
Relevant getenv() parameters:
None
Example Code:
int16 data = 0x0C32;
write_configuration_memory
(&data, 2);
CRC
The programmable Cyclic Redundancy Check (CRC) in the PIC24F is a software configurable CRC
checksum generator. (Other members of the PCD family do not have this peripheral at the time of
writing this manual). The checksum is a unique number associated with a message or a block of
data containing several bytes. The built-in CRC module has the following features:
Relevant Functions:
setup_crc (polynomial)
crc_init (data)
crc_calc (data)
Relevant Preprocessor:
None
Relevant Interrupts :
#INT_CRC
Relevant Include Files:
None, all functions built-in
Relevant getenv() parameters:
None
Example Code:
Int16 data[8];
int16 result;
setup_adc(15, 3, 1);
crc_init(0xFEEE);
Result =
crc_calc(&data[0], 8);
· Programmable bit length for the CRC generator polynomial. (up to 16 bit length)
· Programmable CRC generator polynomial.
· Interrupt output.
· 8-deep, 16-bit or 16-deep, 8-bit FIFO for data input.
// CRC Polynomial is X16 + X15 + X3 + X1+ 1 or Polynomial = 8005h
Starts the CRC accumulator out at 0xFEEE
Calculate the CRC
This will setup the CRC polynomial.
Sets the initial value used by the CRC module.
Returns the calculated CRC value.
On completion of CRC calculation.
//writes 2 bytes to the configuration memory
61

Related parts for PCDIDE COMPILER