title: C# CRC implementation
body: <p>I am trying to integrate a Serial-port device into my application, which needs CRC-CCTT validation for the bytes that I send to it.
  I'm kinda new into managing byte packets, and need help for this.</p>
  
  <p>It uses this formula for making the CRC calculus:</p>
  
  <pre><code>[CRC-CCITT P(X)= X16 + C12 + C8 + 1]
  </code></pre>
  
  <p>So for example for the packet: 0xFC 0x05 0x11, the CRC is 0x5627.
  Then I send this packet to the device: 0xFC 0x05 0x11 0x27 0x56</p>
  
  <p>Also, packet lenghts will vary from 5 to 255 (including CRC checks bytes)</p>
  
  <p>I don't know how to implement this, so any idea/suggestions will be welcome.</p>
  
  <p>Hope I made myself clear,
  Thanks in Advance.</p>
  
  <p>EDIT: 
  here is the specification of what I need to do:</p>
  
  <p><img src="https://i.stack.imgur.com/tvYiq.png" alt="enter image description here"></p>