Ron Kneusel wrote:
Ok, here's the assembly listing of the ROM. I copied it by hand after
a few attempts to dump it to disk from Applesoft using the old "monitor
command" trick and by calling the LIST monitor routine directly. Both
resulted in a partial listing and other garbage. Odd, works when not
writing to a file.
Anyway, here it is, card in slot 7:
PHA
TXA
PHA
TYA
PHA
PHP
SEI
JSR $FF58
TSX
LDA $0100,X
AND #$0F
PLP
TAY
TSX
PLA
PLA
PLA
AND #$7F
STA $0678,Y
TXS
TYA
TAX
ASL
ASL
ASL
ASL
TAY
STA $05F8,X
LDA #$FF
STA $C083,Y
LDA #$7F
STA $C082.Y
LDA #$CC
STA $C08C,Y
LDA #$00
STA $C08B,Y
STA $C08E,Y
TXA
TAY
LDA $0678,Y
CMP #$09
BNE HERE0
LDA #$55
STA $06F8,Y
LDA #$00
STA $07F8,Y
HERE1 PLA
TAY
PLA
TAX
PLA
RTS
HERE0 LDA $06F8,Y
CMP #$55
BEQ HERE2
LDX $05F8,Y
JSR $C800
CLC
BCC HERE1
HERE2 LDX $05F8,Y
JSR $C803
CLC
BCC HERE1
BRK
That's it. I imagine the $c08c addresses and there abouts are
registers for the 6522? I see a comparison to 9 which is the TAB
character. Is this a printer driver of some kind?
This is the $Csxx space, the slot entry point. It initializes the slot screen holes and the 6522 (for output on port A, and one input on port B). It also detects a CTL-I input, which signals a printer setup sequence. So I agree with you, this card was intended to drive a printer or plotter, or similar device. The one input on port B is no doubt a handshake line connected to the device's ACK line. This code really just sets up to call the actual firmware in the ROM expansion space at $C800..$CFFE. If you write some code to activate the slot (by, for example, referring to $Cs00), then move $C800..$CFFF (upward only, because the card will disable its ROM near the top of this range) to RAM at, say, $8800..$8FFF, then run it, the expansion ROM contents will be at the target location for saving to disk or disassembly. You can't use the monitor for this, because as it scans commands it sends characters to the console firmware, which will switch the expansion space back to the console firmware (slot 3). -michael Music synthesis for 8-bit Apple II's! Home page: http://members.aol.com/MJMahon/ "The wastebasket is our most important design tool--and it is seriously underused."