Jump to content
IGNORED

A8DS - An Atari 8-bit Emulator for the DS/DSi/XL/LL


Recommended Posts

On 5/11/2023 at 8:43 PM, llabnip said:

There are probably other a8 emulators for the 2DS/3DS that would use the higher resolution. 

I kind of doubt it, but I didn't know there were games that had higher resolutions.

Unless you just mean higher resolution than the DS.

Link to comment
Share on other sites

2 hours ago, Asaki said:

I kind of doubt it, but I didn't know there were games that had higher resolutions.

Unless you just mean higher resolution than the DS.

Right - I mean that there are probably A8 emulators designed to take advantage of the 2DS/3DS XL 800x240 resolution which still need scaling (up scaling in this case) but it helps to have the additional pixels to work with.

Link to comment
Share on other sites

20 hours ago, Philsan said:

If you have still time, double stereo would be nice.

 

It's on 'the list' :)

 

Right now I'm adding a few more of the CART schemes including the Standard 4K and the Bounty Bob Strikes Back (among others).

 

Then I hope to add a little Cartridge banking picker for when you load a .ROM (vs a .CAR which has the header info). This way, I can disambiguate a cartridge on loading.

 

Edit: Version 3.2b checked in with most of the cartridge banking schemes now supported. If you load via a .CAR file, it should pick the right cart type. If you load via a ROM file, it will take a guess that might or might not be correct - but now you can override the cart detection on a per-game basis using the Gear/Settings menu.

 

image.png.7864b57d8ffc302031cc4a1ded3a9840.png

  • Like 2
  • Thanks 2
Link to comment
Share on other sites

On 5/13/2023 at 2:56 PM, llabnip said:

Right - I mean that there are probably A8 emulators designed to take advantage of the 2DS/3DS XL 800x240 resolution which still need scaling (up scaling in this case) but it helps to have the additional pixels to work with.

I haven't been following super closely lately,  but last I checked, there are very few homebrews that take advantage of the 800 width mode. I know the Super Mario 64 port does.

I'd only seen one 5200/8bit emulator, and it hasn't been updated in ages. I think all the links are dead now. No 800x240 support as far as I can tell.

  • Like 1
Link to comment
Share on other sites

I did finally get around to updating the readme - no idea if anyone bothers to read it, but I wanted to get out the information on some of the new features. 

 

Especially important is this new section:

 

Screen Scaling and Smooth Scrolling :

An NTSC Atari 800 uses a video chip that outputs 320 x 192 (nominal). Many games utilize the overscan and underscan areas. Further, PAL systems utilize more scanlines. This is unfortunate for our hero the DS/DSi which has a fixed resolution of 256x192. As such, the system must scale the video image down - losing pixel rows and columns as it does so. A8DS allows for some help in this department - you can use the Gear/Settings to tweak the scaling and offsets to get as many usable pixels onto the screen (for example, some games may utilize a "sky" or "ground" area that isn't critical for gameplay and can safely be off-screen).

 

One other trick is the use of Smooth Scroll. You can assign to any DS key (I usually use the X and Y keys) one of the following 'meta' functions:

  • VERTICAL+ or VERTICAL- ... shift the screen up or down 16 pixels and smooth-scroll it back into place
  • VERTICAL++ or VERTICAL-- ... shift the screen up or down 32 pixels and smooth-scroll it back into place
  • HORIZONTAL+ or HORIZONTAL- ... shift the screen left or right 32 pixels and smooth-scroll it back into place
  • HORIZONTAL++ or HORIZONTAL-- ... shift the screen left or right 64 pixels and smooth-scroll it back into place

This really helps games where there might be some score other infrequently referenced information at the top/bottom of the screen. Witness here Caverns of Mars which I've mapped to show the entire screen minus the bottom row of text... using VERTICAL+ I can press the X button to quickly glance at the bottom line and let it scroll back up during gameplay.

 

Caverns of Mars Caverns of Mars

 

If a game was released for both NTSC and PAL and does not utilize the same number of visible scanlines, you're usually better off with the NTSC versions on the DS handheld. The reason is simple: you are less likely to have to scale and drop pixel rows with an NTSC output. However, with the use of scaling and smooth scrolling, you should be able to get workable versions of games in either TV standard.

 

Lastly, I've released version 3.3 with the cart tweaks and other small bug fixes in place. Unfortunately, I had to make one last tweak to the configuration settings which I debated 'living with' but as the last version was only released 2 days ago, I figure the small number of users that have A8DS running won't be too mad at me for correcting this oversight. As a bonus, we can now store 2500 individual game settings going forward.

  • Like 5
Link to comment
Share on other sites

The newly re-written configuration handling is paying dividends. At lunch I was able to get a high-score table in. You can save 10 scores for each game - sort them by score, alphanumerical, time (racing games), etc. It remembers the last initials used so you don't have to pick your name each time (unless you've got multiple people using the DS/DSi).

 

Gone is the (i) info button which wasn't much use and the new Trophy icon is used to enter high-scores for a given game:

 

image.thumb.png.9235c4caa082854ef2968232cae7d50e.png

 

image.thumb.png.4fc1257120d053ba0255cc78cd8885e4.png

 

  • Like 5
Link to comment
Share on other sites

2 hours ago, llabnip said:

At lunch I was able to get a high-score table in. You can save 10 scores for each game - sort them by score, alphanumerical, time (racing games), etc. It remembers the last initials used so you don't have to pick your name each time (unless you've got multiple people using the DS/DSi).

Oh that's really cool. I usually have to jot them down somewhere.

  • Like 1
Link to comment
Share on other sites

Last night I worked on colors. I think I've sorted the NTSC vs PAL color tables.  Originally I had a sort of 'BRIGHT' and 'MUTED' palette setting but that's not very accurate. That's gone in 3.3c and replaced with NTSC vs PAL.

 

Since I'm a goofy American, I'd appreciate someone who grew up with PAL games/apps give me a clue as to whether I've got it generally right on A8DS for the LCD screen.

 

Lastly - right now I have a config setting for NTSC vs PAL machine (60 vs 50Hz and scanline differences) and also a Palette setting (NTSC vs PAL) - is there ever a reason you would set the machine to PAL but the color palette to NTSC? I don't mind leaving the setting but also don't mind simplifying. 

 

Thanks again for all the great feedback here!

 

Example of Caverns of Mars with the new PAL palette:

image.png.cf30dff01b0cbb82a3e4689ceb66b1a0.png

  • Like 2
  • Thanks 1
Link to comment
Share on other sites

1 hour ago, llabnip said:

Since I'm a goofy American, I'd appreciate someone who grew up with PAL games/apps give me a clue as to whether I've got it generally right on A8DS for the LCD screen.

Keep in mind that the original "phat" DS and the DS Lite have different colorspaces, so you'll see some big differences there. I assume, like most homebrews, you're aiming for Lite's colorspace.

I don't know what DSi does, but I would assume it's the same as the Lite.

On the 3DS in DS mode, they simulate the phat's colorspace. It's pretty good IMO.

  • Like 1
Link to comment
Share on other sites

Just checked in a daily build 3.4a with a new Alpha Frame Blend I'm experimenting with. This occurs in DS hardware so has no real cost to the emulation speed and helps with small "bullet-like" objects that tend to get lost on the non-XL screens.

 

The original DSi LCD screen has a fairly fast update and games like Atlantis or Caverns of Mars II tend to use very small objects for bullets which work fine when showing on an old tube TV which holds the phosphor image nicely. And the DSi XL tends to have a slower fade and so also looks quite nice. But the DSi (and DS-Lite to some extent) tends not to show these small objects very well - it's easy to lose them in the fast gameplay.  

 

This new ALPHA BLEND setting (which is defaulted OFF but you can globally enable it if you find it useful) will combine and output two successive frames. This has the visual effect of brightening the output and making small objects stand out a bit more with no impact on emulation speed.  I may play around with the alpha blend equation a bit to see what looks best - but I'm currently doing a 75/25 blend in this test version which means 75% of the output is the current frame and 25% is the previous frame to try and approximate the phosphor fade of a TV.   If you enable it on a per-game basis, you will have to re-load the game for the new setting to take effect.

 

image.png.4bc9f0b5c99ace70752b961a591ffbf2.png

  • Like 5
Link to comment
Share on other sites

Just an update... this week I tried to understand various flashing schemes to see how PacMan Arcade and Jim Slide XL (among others) save data to the flash memory in the Atarimax carts. 

 

I just couldn't Grok it... so I'm switching tactics. I'm adding a more generic save/restore state with two new icons on the main screen:

image.png.0cdfd00769b58b88cae950c1ce0f21e4.png

 

It's almost working - at least with non expanded memory games. I should have something ready to try in a day or two. This will let you snap out the state of any game to the SD card and restore it back - which should work on any game/program no matter if XEX, CAR/ROM/ ATR, etc. Right now it's only one save state per game/program... but I may get fancier in the future.

  • Like 5
Link to comment
Share on other sites

https://github.com/wavemotion-dave/A8DS

V3.6 : 29-May-2023 by wavemotion-dave

  • Added the ability to save and restore state - use the DOWN/UP icons on the main screen.
  • Minor memory optimization to squeeze out another frame or two of performance.
  • Added 576K COMPY SHOP as a RAM option

Took a bit longer than I thought. The problem was that so many of the speed optimizations require pointers to banks of memory but you can't just save/restore those out to a save file (well... you can - but as soon as you change code/memory it will not load the save file properly ... and we change code/memory on almost every release). So I had to add a scheme to save off the logical mapping of memory pointers - e.g. "this pointer points to cartridge space at an offset of 0x4000 bytes".  This should allow future-proofing the save/load states. It's also smart enough to not save off unused memory - so even if you have your default A8DS machine set to 1088K, games that are just using a fraction of main memory will shrink down to a save file of about 90K (I could get it smaller but that's good enough for SD cards these days). Games utilizing more of the expanded memory will, obviously, have correspondingly larger save files. 

 

Oh... I also added the 576K COMPY SHOP RAM as an option with separate ANTIC memory access. Because... why not?!

 

  • Like 6
Link to comment
Share on other sites

Thanks for the feedback, Simon - it's hugely appreciated. I realize this emulator is a niche of a niche ... and mostly it's written for my enjoyment (both as a programmer and as a retro enthusiast) but it's gratifying to know there are a few others using it.

 

I'm working on some quality of life improvements for the next release.  I realized only recently that games like Robotron and Space Dungeon both allow "twin-sticks" to move/fire. This actually works great on the DS since the d-pad and the ABXY buttons form a sort of natural twin-sticky situation. So I expanded the new config to allow mapping keys to either Joystick 1 (default) or Joystick 2 and this allows smooth move-and-shoot action on those games (not sure if any other games will benefit... but those game are pretty great so it's worth it). Even the diagonal shooting (e.g. pressing XA or YB, etc.) is pretty easy.

 

I'm also adding the 64K base memory machine and putting the memory in proper order (they got a little off-kilter in configuration as I added them in a non-increasing order). With the new configuration handling, I can do this seamlessly without disrupting any existing configurations upon upgrade.

For the future? Depends on time and motivation. I want to take advantage of the DS - both buttons and touch-screen. I realize that this emulator will have shortcomings (mostly in the display department) but it does have some strengths. I'd like to add a cheat menu, the ability to bring up text-based manuals and/or store some custom notes on a game and other things that might just improve the overall user experience. I'm toying with custom graphical overlays for the bottom screen so you can design a nice touch-interface graphic for games like Star Raiders with custom hot-spots for the various functions (Hyper Warp, Galactic Chart, Front/Aft view, etc).

 

 

 

image.thumb.png.3c880eb83e768c5b58db8dee6806a1cf.png

  • Like 4
Link to comment
Share on other sites

4 hours ago, llabnip said:

I realize this emulator is a niche of a niche ...

 

Case in point: after installing some of your other emulators, I went looking for something to emulate the Commodore 64 on the DS and posted here on AA in the Commodore forum.  I only found one that looks to have been abandoned in 2008, and it also appears to have frame rate issues (people in threads were blaming the SID emulation).   (Not asking that you adopt this emulator, it's more an observation that the DS truly is a niche platform for this stuff). 

 

Still, you've managed to hit nearly all the classic 8-bit systems I personally enjoy, so I definitely appreciate it!

 

Edited by FifthPlayer
  • Like 1
Link to comment
Share on other sites

1 hour ago, FifthPlayer said:

Still, you've managed to hit nearly all the classic 8-bit systems I personally enjoy, so I definitely appreciate it!

You're quite welcome! The 7 classic systems I maintain emulators for are all systems I own and I've enjoyed over the years though it really comes down to the 'big 4' for me:

 

  • Atari 2600 - aka Atari VCS - aka my gateway to all things video gaming. Got it in 1980 and fell in love with Adventure and Haunted House and Space Invaders. Still my favorite classic system.
  • Intellivision - never owned by my best friend up the street had one and we played endless AD&D Cloudy Mountain, Treasure of Tarmin and Tron Deadly Dics.
  • Colecovision - my 'upgrade' to the VCS with all the great arcade ports. Loved going to Toys-Backwards-R-Us and looking at all the games behind the plastic/glass. I've a special place in my heart for Ladybug and QBert on this system.
  • TI-99/4a - my buddy's upgrade to his Intellivision. So much fun delving 10 levels deep in Tunnels of Doom and playing through the Scott Adams adventures... SAY YOHO!

 

I think I'd be happy with just those 4 but I was fortunate to inherit some of @alekmaul's amazing ports he did circa 2008-2011 which included the Atari 7800 and the Atari 8-bit (more specifically - the Atari 5200) and he graciously gave me permission to update, enhance and maintain them.  To my knowledge, he did not do a C64 emulator and, as you said, the existing FrodoDS has a number of issues. The main reason I haven't taken that on is the time commitment is at least 100 hours just to get something workable on the system (much of that just trying to get familiar with the peculiarities of the hardware) - and that's starting with some existing codebase. Another reason is that I never had, nor used, a C64. I'm sure it's a fine system... but I'm an Atarian :D

  • Like 6
  • Thanks 1
Link to comment
Share on other sites

11 hours ago, llabnip said:

I'd like to add a cheat menu, the ability to bring up text-based manuals and/or store some custom notes on a game and other things that might just improve the overall user experience. I'm toying with custom graphical overlays for the bottom screen so you can design a nice touch-interface graphic for games like Star Raiders with custom hot-spots for the various functions (Hyper Warp, Galactic Chart, Front/Aft view, etc).

Maybe a little "game select matrix" overlay for those games with hundreds of options? @_@

  • Like 1
Link to comment
Share on other sites

I hadn't thought about R: / modem support. The DSi does have semi-modern wi-fi (in that it will at least support WPA2 unlike older DS-Lite/Phat which only handle WEP) so connectivity is a possibility.

 

I'll consider it given other time commitments and priorities. 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...