• EXTRA ! EXTRA ! READ ALL ABOUT IT - PCJOHN AND ANOTHER VECTREX FIRS

    From Frank Buss@21:1/5 to John Dondzila on Sat Nov 11 21:11:06 2017
    On Friday, October 29, 1999 at 9:00:00 AM UTC+2, John Dondzila wrote:
    Thanks to Peter Pachla's suggestion, I spent the last 2 nights working on
    the software selectable mini bankswitch cart and I'm pleased to announce:

    SUCCESS !!!

    Hardware wise is really easy, just wire the PB6 line (pin 35) to the
    high address line (A15) on the 64K EPROM.

    The software end was a little trickier, the 6522 info I have and the actual execution of the thing don't work quite the same ...

    Basically, if you set the PB6 line to INPUT, it seems to automatically go high. If you set it to OUTPUT, it goes low. You can send a high bit in the output mode, but it will only pulse once, then reset to low. This could be useful for larger carts, but I need the 2 banks to stay steady right now without
    re-writing all 8 programs. I'm not sure if my manual is wrong or the Vec does this, either way - it works. Now I just need to test it on some more machines before I implement it into the final package.

    The ROM uses this port a lot for the vector output and just overwrites your value. This is the reason that you see just a pulse, see the commented assembler listing of the Vectrex and search for "BPORT":

    http://oldies.malban.de/firstvectrex/vectrex/UPDATE/TODO/RUMCHIP.ASM

    And looks like some of the old 6522 chips have pullups on port B, but some not, see e.g. this article:

    http://www.westerndesigncenter.com/wdc/AN-004_W65C22S_Replacements.cfm

    So the safe method is to add a 10k pullup on PB6 in the cartridge, as Peter suggested. You never know if someone someday replaces a 6522 with a newer model.

    Another good idea when doing bank switching: I disassembled the code for the cool demo "where have all the pixels gone ?" ( http://www.pouet.net/prod.php?which=59227 ), which uses a 64 kB cartridge and bankswitching. The relevant code is this:

    58AD lda 0x02
    58AF eora #$40
    58B1 sta 0x02

    But they don't call it in ROM at the $58ad address. Instead it gets copied in the RAM somewhere at $c8xx when the cartridge ROM is started, and then later called in RAM. I think this is a very good idea, because you don't want any address or data glitch
    when switching the ROM bank.

    Note that the DP register is $d0 when the code is called, so the effective address is $d002 for the lda and sta commands above, because they are using the direct addressing mode and not the extended addressing mode.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)