User Profile

Collapse

Profile Sidebar

Collapse
khatavkar
khatavkar
Last Activity: Jan 12 '10, 10:48 AM
Joined: Nov 5 '09
Location:
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • khatavkar
    started a topic calculation of 32 bit CRC(Cyclic Redundancy Code)in C
    in C

    calculation of 32 bit CRC(Cyclic Redundancy Code)in C

    please help me!!
    i have written a program to calculate 32 bit CRC(used for ETHERNET)..but its not working and giving correct output..
    please let me know my mistakes..

    output should be :E7 B0 51 93
    Code:
    /**************  program starts here *************************/
    typedef unsigned long ul;
    typedef unsigned char uchar;
    
    uchar buffer_bytes[64] = {0x00,0x14,0x85,0x31,0x24,0x10,0x00,0x15,0x00,0x15,0x9f,0x07,0x08,0x06,0x00,0x01,0x08,0x00,0x06,0x04,0x00,0x02,0x00,0x15,0x00,0x15,0x9f,0x07,0xc0,0xa8,0x00,0x02,0x00,0x14,0x85,0x31,0x24,0x10,0xc0,0xa8,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00};
    ...
    See more | Go to post
    Last edited by Banfa; Jan 11 '10, 12:37 PM. Reason: Added code tags

  • khatavkar
    replied to calculation of crc-16 in C
    in C
    I am going to create an algorithm,& a small program also..in C'language..
    Also ,i am not able to decide polynomial for this calcaulation,co uld u please help me!!
    See more | Go to post

    Leave a comment:


  • khatavkar
    started a topic calculation of crc-16 in C
    in C

    calculation of crc-16 in C

    I am using an ethernet and for sending ECHO reply,its important to calculate CRC.Should Iconsider data while calculating 16-bit CRC, and if YES then where shoul i append the EXTRA zeros,
    1. at the place of CRC itself or
    2.in the end..

    for example:
    if msg is:
    45 00 00 3c 02 13 00 00 80 01 [two bytes of crc] [source IP] [destination IP]

    should i consider source and destination IP's while calculating...
    See more | Go to post
No activity results to display
Show More
Working...