MSPM0G3507: Is it possible to use the CRC peripheral to calculate an Ethernet FCS

Part Number: MSPM0G3507
Other Parts Discussed in Thread: SYSCONFIG

The CRC peripheral supports ISO-3309 (0x04C11DB7), however I'm unable to use it to calculate a valid Ethernet FCS and I'm hoping I'm just configuring the peripheral incorrectly. Here's an example Ethernet II frame:

AAAAAAAAAAAA5555555555550004DEADBEEF

The correct FCS for this frame is 0x855D5CB0, but I'm unable to get this result using the CRC peripheral. If it's possible, what's the correct settings (Input/Output Bit Order, Input Byte Order, and CRC Seed) and can I use DMA to feed the Ethernet frame to the CRC peripheral?

TIA!

  • Hi Rob,
    I would recommend to take a look at our CRC examples in the SDK for further guidance. 

    Best Regards,

    Diego Abad

  • Hi Diego,

    Thank you for your response.

    I'm aware of that example, but there's no mention of using the CRC peripheral to calculate a Ethernet FCS. I assume someone else has attempted to do this already either at TI or the community and I was hoping I could get a yes/no answer. There are not a lot of knobs on the CRC peripheral and I've turned them all without success. However, I'm hopeful considering the CRC peripheral has the ISO-3309 polynomial.

    I do have another question with the original question still pending. When using sysconfig to configure the CRC to use DMA, it's locking the DMA configuration to use words for the source and destination when the reference manual specifically states that the CRC peripheral can work with bytes, half words, and words. Is this a bug in the sysconfig tool?

  • Hi Rob,

    You are correct, there isn't an specific code or record of Ethernet FCS with our CRC accelerator. I would think the implementation will require the setting of the correct seed into the calculations, as well as feeding the CRC information into the right format. I think the biggest thing to clarify will be how to format the frame into an array of 32bit values without loosing information (as it is, the frame will need another two bytes to be able to be separated into an even array of 32-bits)

    The example in the SDK doesn't show it, but there are some functions that can be used for byte, half word, and word configuration. You can find more information in the dl_crc.h/.c files.

    Best Regards,

    Diego Abad

  • Thank you Diego,

    Is the SysConfig tool correct in locking the DMA transfer length to only 32-bit words, or is this a bug? The reference manual states that the CRC peripheral supports byte, half-word, and word so I feel like this is a bug.

  • Hi Rob,
    It seems to be a bug. I'll send Jira ticket about it.

    Best Regards,

    Diego Abad