# Answer to Question #9320 in MatLAB | Mathematica | MathCAD | Maple for Nick

Question #9320

How to make link between crc generator code and error-detecting code so that it can run smoothly?

For reference, my crc generator code is-

% The program generates CRC code for any given input message stream &

% generator polynomial

%msg=[1 1 1 0 0 0 1 1 ]

msg=input('Input Message sequence :');

%poly=[1 1 0 0 1 1]

poly=input('Input Generator Polynomial :');

[M N]=size(poly);

mseg=[msg zeros(1,N-1)];

[q r]=deconv(mseg,poly);

r=abs(r);

for i=1:length(r)

a=r(i);

if ( mod(a,2)== 0 )

r(i)=0;

else

r(i)=1;

end

end

crc=r(length(msg)+1:end)

frame = bitor(mseg,r)

For reference, my crc generator code is-

% The program generates CRC code for any given input message stream &

% generator polynomial

%msg=[1 1 1 0 0 0 1 1 ]

msg=input('Input Message sequence :');

%poly=[1 1 0 0 1 1]

poly=input('Input Generator Polynomial :');

[M N]=size(poly);

mseg=[msg zeros(1,N-1)];

[q r]=deconv(mseg,poly);

r=abs(r);

for i=1:length(r)

a=r(i);

if ( mod(a,2)== 0 )

r(i)=0;

else

r(i)=1;

end

end

crc=r(length(msg)+1:end)

frame = bitor(mseg,r)

Expert's answer

Unfortunately, your question requires a lot of work and cannot be done for free.

Submit it with all requirements as an assignment to our control panel and we'll assist you.

Submit it with all requirements as an assignment to our control panel and we'll assist you.

Need a fast expert's response?

Submit orderand get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

## Comments

## Leave a comment