+playsoft Posted January 30, 2014 Share Posted January 30, 2014 Steve kindly provided me with details of the hybrid 8K write/8K read mode supported by the Atarimax 5200 Ultimate SD cart. I have been using this mode primarily for the 8K read bank but now that I've experimented with the 8K write bank I thought I'd pass along the details in case they are useful. To use hybrid mode the image must be 512K in length with a ".hyb" extension. The cartridge is mapped:$4000..$7FFF banked area$8000..$BFFF fixed read area, top 16K of imageThe banked area can be either a 16K read bank or a 8K write/8K read bank.The cartridge has 512K of onboard SRAM and when you select an image it is copied into SRAM. The 8K write/8K read mode allows your 5200 program to write to the onboard SRAM.You select the bank by touching $BFC0..$BFFD where $BFC0 selects the bottom 8K of the image, $BFC1 selects the next 8K etc...When a 8K write/8K read bank is selected the following mapping applies in the banked area:$4000..$5FFF provides write only access$6000..$7FFF provides read only (and execute) accessThere is a significant restriction when writing, in that the way the cartridge write latching works means that 6502 dummy cycles can cause spurious writes elsewhere in the bank. For example, I find that sta (zp),y works ok when y is 0, but not when other values of y are used - I see additional spurious writes elsewhere in the bank.The attached demo program has 10 high resolution images stored in the first 10 banks accessible via the 0..9 keys. You can move the cursor around with the joystick and draw over them in white by pressing fire, or black with alternate fire. Start will fast cycle through all the images, any key will stop it. Rather than being anything useful (or particularly enjoyable) this is just to demonstrate use of the cart SRAM.The attached source code is ca65 - the bin directory is in my path and I use build.bat to assemble. demo.zip source.zip 2 1 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
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.