<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Burning to EPROM &amp; Real Hardware on Programming the Atari VCS in Assembly</title><link>https://cdeever.github.io/atari-vcs/docs/burning-eprom/</link><description>Recent content in Burning to EPROM &amp; Real Hardware on Programming the Atari VCS in Assembly</description><generator>Hugo</generator><language>en-us</language><atom:link href="https://cdeever.github.io/atari-vcs/docs/burning-eprom/index.xml" rel="self" type="application/rss+xml"/><item><title>Choosing the Chip</title><link>https://cdeever.github.io/atari-vcs/docs/burning-eprom/choosing-the-chip/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://cdeever.github.io/atari-vcs/docs/burning-eprom/choosing-the-chip/</guid><description>&lt;h1 id="choosing-the-chip"&gt;Choosing the Chip&lt;a class="anchor" href="#choosing-the-chip"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;&amp;ldquo;EPROM&amp;rdquo; is the traditional name, but you have a few families to pick from, and the choice mostly comes down to &lt;em&gt;how painful it is to reprogram when you find a bug&lt;/em&gt; — and you will find bugs.&lt;/p&gt;
&lt;h2 id="the-three-families"&gt;The three families&lt;a class="anchor" href="#the-three-families"&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;table&gt;
 &lt;thead&gt;
 &lt;tr&gt;
 &lt;th&gt;Family&lt;/th&gt;
 &lt;th&gt;Examples&lt;/th&gt;
 &lt;th&gt;Erase method&lt;/th&gt;
 &lt;th&gt;Reusable?&lt;/th&gt;
 &lt;th&gt;Notes&lt;/th&gt;
 &lt;/tr&gt;
 &lt;/thead&gt;
 &lt;tbody&gt;
 &lt;tr&gt;
 &lt;td&gt;&lt;strong&gt;UV EPROM (windowed)&lt;/strong&gt;&lt;/td&gt;
 &lt;td&gt;2716, 2732, 2764, 27256, 27512&lt;/td&gt;
 &lt;td&gt;UV light (~15–20 min in a UV eraser box)&lt;/td&gt;
 &lt;td&gt;Yes, many times&lt;/td&gt;
 &lt;td&gt;The classic. The quartz window over the die lets a UV eraser box wipe it clean for reuse. Just keep the window covered with a sticker in normal use, or ambient UV slowly corrupts it.&lt;/td&gt;
 &lt;/tr&gt;
 &lt;tr&gt;
 &lt;td&gt;&lt;strong&gt;OTP EPROM (no window)&lt;/strong&gt;&lt;/td&gt;
 &lt;td&gt;same part numbers, plastic package&lt;/td&gt;
 &lt;td&gt;—&lt;/td&gt;
 &lt;td&gt;&lt;strong&gt;No — one shot&lt;/strong&gt;&lt;/td&gt;
 &lt;td&gt;Electrically identical die, but the plastic package has &lt;em&gt;no window&lt;/em&gt;, so there&amp;rsquo;s no way to get UV to it. Programs once, then it&amp;rsquo;s permanent. Cheap for production; avoid while iterating.&lt;/td&gt;
 &lt;/tr&gt;
 &lt;tr&gt;
 &lt;td&gt;&lt;strong&gt;EEPROM&lt;/strong&gt;&lt;/td&gt;
 &lt;td&gt;28C16, 28C64, 28C256&lt;/td&gt;
 &lt;td&gt;Electrically, in the programmer&lt;/td&gt;
 &lt;td&gt;Yes, instantly&lt;/td&gt;
 &lt;td&gt;No UV lamp. Slightly pricier, sometimes slower write, very convenient for iteration.&lt;/td&gt;
 &lt;/tr&gt;
 &lt;tr&gt;
 &lt;td&gt;&lt;strong&gt;Flash / &amp;ldquo;electrically-erasable EPROM&amp;rdquo;&lt;/strong&gt;&lt;/td&gt;
 &lt;td&gt;W27C512, W27C020 (Winbond), SST39SF&lt;/td&gt;
 &lt;td&gt;Electrically, in the programmer&lt;/td&gt;
 &lt;td&gt;Yes, instantly&lt;/td&gt;
 &lt;td&gt;Cheap, reusable, no UV — the modern homebrew favorite. The Winbond W27C512 is a drop-in-ish 27512 replacement that erases in the programmer.&lt;/td&gt;
 &lt;/tr&gt;
 &lt;/tbody&gt;
&lt;/table&gt;
&lt;p&gt;&lt;strong&gt;For iterating on a game, pick something electrically erasable&lt;/strong&gt; (EEPROM or a Winbond/SST flash part). Reserve UV EPROMs for when you specifically want the vintage experience or already own a stack of them — the burn → test → &amp;ldquo;oops&amp;rdquo; → 20-minute-erase cycle gets old fast.&lt;/p&gt;</description></item><item><title>Preparing the ROM Image</title><link>https://cdeever.github.io/atari-vcs/docs/burning-eprom/preparing-the-image/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://cdeever.github.io/atari-vcs/docs/burning-eprom/preparing-the-image/</guid><description>&lt;h1 id="preparing-the-rom-image"&gt;Preparing the ROM Image&lt;a class="anchor" href="#preparing-the-rom-image"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;The bytes you send to the programmer are not always the bytes DASM emitted. Two things have to be right: the &lt;strong&gt;reset vectors&lt;/strong&gt; must land at the very top of the address the console fetches from, and the image must &lt;strong&gt;fill the chip&lt;/strong&gt; in a way the cartridge wiring expects.&lt;/p&gt;
&lt;h2 id="the-reset-vectors-must-be-at-the-top"&gt;The reset vectors must be at the top&lt;a class="anchor" href="#the-reset-vectors-must-be-at-the-top"&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;When the console powers on, the 6507 reads its program-counter start address from the reset vector at &lt;code&gt;$FFFC&lt;/code&gt;/&lt;code&gt;$FFFD&lt;/code&gt;. On the cartridge that is the &lt;strong&gt;last two bytes of ROM space&lt;/strong&gt;. Every ROM in this book ends with:&lt;/p&gt;</description></item><item><title>Wiring the Cartridge</title><link>https://cdeever.github.io/atari-vcs/docs/burning-eprom/wiring-the-cartridge/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://cdeever.github.io/atari-vcs/docs/burning-eprom/wiring-the-cartridge/</guid><description>&lt;h1 id="wiring-the-cartridge"&gt;Wiring the Cartridge&lt;a class="anchor" href="#wiring-the-cartridge"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;Once the chip is programmed it has to be wired into something the console&amp;rsquo;s cartridge slot can read. This is where the project leaves software and becomes electronics — and where the mistakes stop being syntax errors and start being &lt;em&gt;bus contention&lt;/em&gt; and &lt;em&gt;floating address lines&lt;/em&gt;.&lt;/p&gt;
&lt;blockquote class='book-hint '&gt;
&lt;p&gt;&lt;strong&gt;Strong recommendation:&lt;/strong&gt; copy the connections from a &lt;strong&gt;proven, published cartridge schematic or reproduction PCB&lt;/strong&gt; (AtariAge has well-documented designs) rather than improvising them. The pin-level details below are to help you &lt;em&gt;understand and verify&lt;/em&gt; such a design, not to reverse-engineer one from scratch. This is the one part of the pipeline where &amp;ldquo;close enough&amp;rdquo; produces hardware that intermittently works, which is worse than hardware that never works.&lt;/p&gt;</description></item><item><title>Gotchas: Works in Stella, Dies on Hardware</title><link>https://cdeever.github.io/atari-vcs/docs/burning-eprom/gotchas/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://cdeever.github.io/atari-vcs/docs/burning-eprom/gotchas/</guid><description>&lt;h1 id="gotchas-works-in-stella-dies-on-hardware"&gt;Gotchas: Works in Stella, Dies on Hardware&lt;a class="anchor" href="#gotchas-works-in-stella-dies-on-hardware"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;This is the page worth bookmarking. The bugs here share a signature: &lt;strong&gt;the game is perfect in the emulator and wrong on the console.&lt;/strong&gt; That signature is diagnostic — it means the fault is in an assumption the emulator papers over, not in your game logic.&lt;/p&gt;
&lt;h2 id="ram-is-not-zero-on-real-hardware"&gt;RAM is not zero on real hardware&lt;a class="anchor" href="#ram-is-not-zero-on-real-hardware"&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Stella conveniently clears the 128 bytes of RAM at startup. &lt;strong&gt;A real 6507 powers on with RAM full of random garbage.&lt;/strong&gt; If any of your code reads a variable before writing it — a counter, a flag, a sprite position — it works in Stella (where it read 0) and does something random on hardware.&lt;/p&gt;</description></item></channel></rss>