<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.amstrad-cpc.net/index.php?action=history&amp;feed=atom&amp;title=Programming%3ACRC16</id>
	<title>Programming:CRC16 - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.amstrad-cpc.net/index.php?action=history&amp;feed=atom&amp;title=Programming%3ACRC16"/>
	<link rel="alternate" type="text/html" href="https://wiki.amstrad-cpc.net/index.php?title=Programming:CRC16&amp;action=history"/>
	<updated>2026-09-04T00:13:17Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.46.0</generator>
	<entry>
		<id>https://wiki.amstrad-cpc.net/index.php?title=Programming:CRC16&amp;diff=9413&amp;oldid=prev</id>
		<title>PulkoMandy: Category:Programming</title>
		<link rel="alternate" type="text/html" href="https://wiki.amstrad-cpc.net/index.php?title=Programming:CRC16&amp;diff=9413&amp;oldid=prev"/>
		<updated>2006-08-13T14:06:13Z</updated>

		<summary type="html">&lt;p&gt;&lt;a href=&quot;/wiki/Category:Programming&quot; title=&quot;Category:Programming&quot;&gt;Category:Programming&lt;/a&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw-interface=&quot;&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 14:06, 13 August 2006&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l43&quot;&gt;Line 43:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 43:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;    ret&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;    ret&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;/pre&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;/pre&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;[[Category:Programming]]&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>PulkoMandy</name></author>
	</entry>
	<entry>
		<id>https://wiki.amstrad-cpc.net/index.php?title=Programming:CRC16&amp;diff=9412&amp;oldid=prev</id>
		<title>Octoate: CRC16 calculation</title>
		<link rel="alternate" type="text/html" href="https://wiki.amstrad-cpc.net/index.php?title=Programming:CRC16&amp;diff=9412&amp;oldid=prev"/>
		<updated>2006-07-17T10:47:02Z</updated>

		<summary type="html">&lt;p&gt;CRC16 calculation&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;&amp;#039;&amp;#039;This code is untested and may not work as advertised or at all.&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
CRC16:&lt;br /&gt;
;Borrowed from http://zilog.sh.cvut.cz/~base/misc/z80bits.html&lt;br /&gt;
; and moddified to be a loop&lt;br /&gt;
;The arrow comments show what lines I added or commented out from the original.&lt;br /&gt;
;Inputs:    de-&amp;gt;data bc=number of bytes&lt;br /&gt;
;Outputs:   hl=CRC16&lt;br /&gt;
   push bc     ;&amp;lt;---&amp;lt;&amp;lt;&amp;lt;&lt;br /&gt;
   push de     ;&amp;lt;---&amp;lt;&amp;lt;&amp;lt;&lt;br /&gt;
   push af     ;&amp;lt;---&amp;lt;&amp;lt;&amp;lt;&lt;br /&gt;
   ld hl,$FFFF&lt;br /&gt;
   push bc     ;&amp;lt;---&amp;lt;&amp;lt;&amp;lt;&lt;br /&gt;
CRC16_Read:&lt;br /&gt;
   ld a,(de)&lt;br /&gt;
   inc de&lt;br /&gt;
   xor h&lt;br /&gt;
   ld h,a&lt;br /&gt;
   ld b,8&lt;br /&gt;
CRC16_CrcByte:&lt;br /&gt;
   add hl,hl&lt;br /&gt;
   jr nc,CRC16_Next&lt;br /&gt;
   ld a,h&lt;br /&gt;
   xor $10&lt;br /&gt;
   ld h,a&lt;br /&gt;
   ld a,l&lt;br /&gt;
   xor $21&lt;br /&gt;
   ld l,a&lt;br /&gt;
CRC16_Next:&lt;br /&gt;
   djnz CRC16_CrcByte&lt;br /&gt;
;   dec c      ;&amp;gt;&amp;gt;&amp;gt;---&amp;gt;&lt;br /&gt;
   pop bc      ;&amp;lt;---&amp;lt;&amp;lt;&amp;lt;&lt;br /&gt;
   dec bc      ;&amp;lt;---&amp;lt;&amp;lt;&amp;lt;&lt;br /&gt;
   push bc     ;&amp;lt;---&amp;lt;&amp;lt;&amp;lt;&lt;br /&gt;
   ld a,b      ;&amp;lt;---&amp;lt;&amp;lt;&amp;lt;&lt;br /&gt;
   or c        ;&amp;lt;---&amp;lt;&amp;lt;&amp;lt;&lt;br /&gt;
   jr nz,CRC16_Read&lt;br /&gt;
   pop bc      ;&amp;lt;---&amp;lt;&amp;lt;&amp;lt;&lt;br /&gt;
   pop af      ;&amp;lt;---&amp;lt;&amp;lt;&amp;lt;&lt;br /&gt;
   pop de      ;&amp;lt;---&amp;lt;&amp;lt;&amp;lt;&lt;br /&gt;
   pop bc      ;&amp;lt;---&amp;lt;&amp;lt;&amp;lt;&lt;br /&gt;
   ret&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Octoate</name></author>
	</entry>
</feed>