Aeon Emulator Blog

November 20, 2009


Filed under: Aeon, Protected Mode — Greg Divis @ 9:06 pm

“…the worst part of this implementation is over” – Me, one post ago

I regretted typing that almost immediately, because right after that I found an embarrassing number of bugs in my code and faced hours of very tedious troubleshooting figuring out what was wrong. The result, though, was worth it:


What, a 32-bit protected mode MOD player is not cool enough? Fine:


Ok, so two 32-bit programs working does not mean I’ve got good compatibility yet. I’ll probably be posting a build 0.51 or so after I’ve had a chance to do some regression testing to make sure I haven’t broken anything. Right now, my plan is for version 0.6 to have decent protected mode game compatibility, so you should be able to see some continuous improvement as I approach it. That should also mean more frequent builds (I hope).

But right now, it’s Friday night. I’m taking a break. :)

November 15, 2009

Protected Mode – Not quite there yet

Filed under: Aeon, Protected Mode — Greg Divis @ 6:20 pm

After doing my homework on x86 protected mode, I’ve been working on actually implementing it. As expected, it’s not easy and I’ve encountered lots of gotchas. Before I talk any more about this, here’s where I was at when I wrote this post:


Unfortunately it crashes right after displaying that message, but believe me, it’s better than it was. I certainly have a greater appreciation for the kind of nightmare the Intel engineers that designed the 386 had to deal with – grafting an entirely different mode of operation while maintaining compatibility with 16-bit code. DOS extenders really took advantage of this to allow a 32/16-bit protected mode application to run on top of 16-bit real-mode DOS – and DOS/4GW was possibly the most commonly used of these extenders.

(As an aside, many of the protected-mode-related instructions begin with the byte 0F, so if you’ve seen something like “Opcode blahblah0F not implemented.” from trying to run something in Aeon, that’s probably why.)

At this point, I’ve gotten a DOS/4GW game to at least get its protected mode environment set up. The good news it that I think the worst part of this implementation is over – the crash I’m getting now is due to a feature I haven’t implemented yet, rather that one that I’ve implemented wrong some time in the past. Way easier to debug.

Also, to properly support DOS extenders I had to get an extended memory manager working (among other things). All of that is done, so I’m hoping that soon I’ll have more to show for all of this work than a screenshot of DOS/4GW starting up.

Create a free website or blog at