Fujitsu Series 3 Manual
Here you can view all the pages of manual Fujitsu Series 3 Manual. The Fujitsu manuals for Controller are available online for free. You can easily download all the documents as PDF.
Page 1301
2. CRC Operations 2.2. CRC use examples Figure 2-2 to Figure 2-5 show CRC use examples. Use example 1 CRC16, Byte input fixed Figure 2-2 Use example 1 (CRC16, byte input fixed, core byte order : Big endian) //*********************************************************** // CRC16 (CRC ITU-T) // polynomial: 0x1021 // initial value: 0xFFFF // CRCCR.CRC32: 0 //CRC16 // CRCCR.LTLEND: 0 //big endian // CRCCR.LSBFST: 0 //MSB First // CRCCR.CRCLTE: 0 //CRC big endian //...
Page 1302
2. CRC Operations Use example 2 CRC16, differe nt input bit widths mixed Figure 2-3 Use example 2 (CRC16, different input bit widths mixed, core byte order: Big endian) //************************************************************ // CRC16 (CRC ITU-T) // polynomial: 0x1021 // initial value: 0xFFFF // CRCCR.CRC32: 0 //CRC16 // CRCCR.LTLEND: 0 //big endian // CRCCR.LSBFST: 0 //MSB First // CRCCR.CRCLTE: 0 //CRC big endian // CRCCR.CRCLSF: 0 //CRC MSB First //...
Page 1303
2. CRC Operations Use example 3 CRC32, byte order: Big endian Figure 2-4 Use example 3 (CRC32, byte order: Big endian) //************************************************************ // CRC32 (IEEE-802.3) // polynomial: 0x04C11DB7 // initial value: 0xFFFF_FFFF // CRCCR.CRC32 1 // CRC32 // CRCCR.LTLEND: 0 // big endian // CRCCR.LSBFST: 1 // LSB First // CRCCR.CRCLTE: 0 // CRC big endian // CRCCR.CRCLSF: 1 // CRC LSB First // CRCCR.FXOR: 1 // CRC Final XOR on...
Page 1304
2. CRC Operations Use example 4 CRC32, byte order: Little endian Figure 2-5 Use example 4 (CRC32, byte order: Little endian) //************************************************************ // CRC32 (IEEE-802.3) // polynomial: 0x04C11DB7 // initial value: 0xFFFF_FFFF // CRCCR.CRC32 1 // CRC32 // CRCCR.LTLEND: 1 // big endian // CRCCR.LSBFST: 1 // LSB First // CRCCR.CRCLTE: 1 // CRC big endian // CRCCR.CRCLSF: 1 // CRC LSB First // CRCCR.FXOR: 1 // CRC Final XOR on...
Page 1305
3. CRC Registers 3. CRC Registers This section provides a list of CRC registers. CRC registers Table 3-1 CRC register list Abbreviation Register name See CRCCR CRC Control Register 3.1 CRCINIT Initial Value Register 3.2 CRCIN Input Data Register 3.3 CRCR CRC Register 3.4 FUJITSU SEMICONDUCTOR LIMITED CHAPTER 22: CRC \050Cyclic Redundancy Check\051 MN706-00002-1v0-E 1269 MB9Axxx/MB9Bxxx Series
Page 1306
3. CRC Registers 3.1. CRC Control Register (CRCCR) The CRC Control Register (CRCCR) is used to control CRC calculation. bit 7 6 5 4 3 2 1 0 Field res FXOR CRCLSFCRCLTE LSBFSTLTLEND CRC32 INIT Attribute R/W R/W R/W R/W R/W R/W R/W R/W Initial value 0 0 0 0 0 0 0 0 [bit 7] RES: Reserved bit The read value is 0. Be sure to write 0 to this bit. [bit 6] FXOR: Final XOR control bit This bit is used to output the CRC result as the XOR value or XOR. The OR value is set to ALLH. This bit...
Page 1307
3. CRC Registers [bit 4] CRCLTE: CRC result byte-order setting bit This is a byte-order setting bit for CRC result. This bit is used to rearrange the by te order in each word. Set 0 to speci fy big endian and set 1 to specify little endian. This processing is performed in the latter part of the CRC Register processing. The CRC result is therefore reflected on the read value imme diately after this bit was set. If this bit is set to 1 in CRC16 mode, data is output to bit 31 to bit 16. Bit...
Page 1308
3. CRC Registers [bit 0] INIT: Initialization bit This is an initialization bit. Writing 1 initializes data. This bit does not have a value, and always returns 0 at reading. At initialization, the value of the Initial Value Register is loaded to the CRC Register. Initialization must be performed once at the start of CRC calculation. Description Bit Write Read 0 Invalid 1 Initialization Always reads 0. FUJITSU SEMICONDUCTOR LIMITED CHAPTER 22: CRC \050Cyclic Redundancy Check\051...
Page 1309
3. CRC Registers 3.2. Initial Value Register (CRCINIT) The Initial Value Register (CRCINIT) is used to save the initial values for CRC calculation. bit 31 0 Field D31-D0 Attribute R/W Initial value 0xFFFFFFFF [bit 31:0] D31 to D0: Initial value bit This bit is used to save the initial values for CRC calculation. Write the initial values for CRC calculation to this register. (0xFFFFFFFF at resetting) In CRC16 mode, D15 to D0 are used while D31 to D16 are ignored. FUJITSU...
Page 1310
3. CRC Registers 3.3. Input Data Register (CRCIN) The Input Data Register (CRCIN) is used to set input data for CRC calculation. bit 31 0 Field D31-D0 Attribute R/W Initial value 0x00000000 [bit 31:0] D31 to D0: Input data bit This bit is used to set input data for CRC calculation. Write input data for CRC calculation to this register. There are three types of bit widths: 8, 16, and 32, which can be specified together. The byte and half-word writing positio ns are arbitrary....
All Fujitsu manuals