PDA

View Full Version : rpix86 version 0.08 released!



wraggster
June 30th, 2013, 23:01
It has been a while since I last worked on rpix86, as I have been focusing on getting the GCW0 version done. However I am now a little bit stuck with the GCW0 version (or rather, the things I need to do to it next are rather boring), so I decided to work this week on the rpix86 for a change. This was my last working week before my summer vacation, so I did not have all that much time to work on it. Thus, there are no major new features, mainly just a few minor fixes.



First, I fixed the text mode cursor problem where there were sometimes extra cursor images left on the screen. This happened at least in Norton SYSINFO. This was caused by the software setting the cursor start scanline to a large value, like 63, with the ending scanline being the default 7. This should skip the cursor drawing completely, but my routine always drew at least one scanline of the cursor, which was wrong.
Next, I worked on getting NHL '94 running, as it was mentioned on the Raspberry Pi forum as not running correctly. I implemented a special handling for a JPO opcode, and also a version of storing data into Mode-X graphics memory using a REP STOSB operation where the indices are decreasing. There are still some problems in NHL '94, especially with SoundBlaster audio. Also it seems to drop back to DOS at first startup, but starts correctly when starting it again.
I have also been working on getting QBASIC running, as it has also needed some special handling of JPO and JPE opcodes. Back in May I managed to implement those opcodes for it, but then ran into a problem where the whole screen just went black when a BASIC program was started. Now I debugged that problem and found out that it sets the text mode palette using VGA palette routines, which I did not properly support in text mode. I made some changes and got it to work better, but it still does some incorrect palette adjustments. I will attempt to fix these better in the upcoming versions.
While debugging the QBASIC palette problem I noticed that rpix86 did not reset the active screen page properly when switching from graphics to text mode, so I fixed that. This probably did not cause any visible problems, though.
One sharp-eyed user of rpix86 had also noticed that while Caps Lock is active, pressing shift and Q, W, E, R or T keys produced the same capital letters as pressing them without shift. This was caused by a problem in my DOS key translation table. This same problem exists in the Art of Assembly (http://cs.smith.edu/~thiebaut/ArtOfAssembly/CH20/CH20-4.html#HEADING4-1) documentation that I used as a source for my routines. This problem is now fixed in this version of rpix86.
I also got a report that when running rpix86 in the X Window environment and using a UK keyboard, the hash key (#) did not work but instead got logged as an unmapped key. Since X sends already mapped keycodes to rpix86, it is somewhat difficult to reverse the mapping to get the actual hardware scancode that rpix86 needs. This is made more complicated because of the various language-specific keyboard layouts in existence. In DSx86 I only supported US keyboard, but that is not sufficient in rpix86. I have now adjusted the key-to-scancode mapping in rpix86, so hopefully at least the UK keyboard is now properly supported. You will still need to run "KEYB UK" command within rpix86 to get the proper key mappings, as the key emulation in rpix86 will always use US key mapping by default.
Finally today I adjusted the emulated AdLib timers to actually use the hardware clock and thus get more accurate results. I did this in hopes that it will improve the AdLib detection routine behaviour in some games that currently do not detect the AdLib presense. This seemed to help at least in Commander Keen 7: Keen Dreams game.

Unfinished features I have been working onIn addition to the changes mentioned above, there are some additional changes that however are not yet finished and/or properly tested. Back in May I got a request to add support for accessing the Raspberry Pi GPIO ports from within rpix86. This seemed like an interesting idea, and as the person who requested this was a programmer and was willing to create some code that would help me in integrating this, I made a special version of rpix86 for him to test. The documentation for this feature is still missing and it requires a third-party shared library to be present, so this is still somewhat of a work-in-progress.
I have also debugged the Sound Blaster and AdLib problems in NHL '94 and Commander Keen 7, but those will still need more debugging. Same with the QBASIC palette problems I mentioned above.
Hopefully I did not break anything with this new version. Some of the changes I made I have only tested in a couple of games, so let me know if some game that used to work fails in this version. Thanks for your continued interest in rpix86!

http://rpix86.patrickaalto.com/rblog.html