TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Tamas Szigeti
NA
16
0
checksum code in c#
Jul 28 2014 6:58 PM
I need to rewrite the code below in c#.
I think the code is written in c but I only understand a few lines.
Can some help me explain the code?
byte crc8(byte *str, int len)
{
int i, f;
byte data;
byte crc;
crc = 0 ;
while (len--)
{
data = *str++;
for = (i = 0; i < 8; i++)
{
f = 1 & (data ^ crc);
crc >>= 1;
data >>= 1 ;
if (f) {
crc ^= 0x8c;
}
}
}
return crc;
}
Reply
Answers (
2
)
String as Hyperlink in c#
How to save image to database using N-tier architecture