Porting a C4 casette program to C4PMF
-
- Posts: 214
- Joined: Sun Mar 08, 2015 3:42 pm
- Location: New York State
Porting a C4 casette program to C4PMF
Is there a way to load a program written in 6502 assembler for the C4P into a C4PMF? via the RS-232 using the monitor? Are there any differences between the 502 and 505B that might cause the code to trip up?
C8PDF w. 48K, 2x 520 24K RAM boards and Glitchworks 64K board
OSI 567 Telephony board
Spare 8" drives
Klyball D-13
OSI 567 Telephony board
Spare 8" drives
Klyball D-13
-
- Site Admin
- Posts: 717
- Joined: Tue Sep 09, 2008 5:24 am
Re: Porting a C4 casette program to C4PMF
If the program fits between $0200 and $22FF (i.e., if it is supposed to run in 8K, which would be most cassette programs), then you should be able to load and run it just fine. If the program stomps on zero page, then you might have to reboot after running it, though.
-
- Posts: 214
- Joined: Sun Mar 08, 2015 3:42 pm
- Location: New York State
Re: Porting a C4 casette program to C4PMF
It’s 16K long
C8PDF w. 48K, 2x 520 24K RAM boards and Glitchworks 64K board
OSI 567 Telephony board
Spare 8" drives
Klyball D-13
OSI 567 Telephony board
Spare 8" drives
Klyball D-13
-
- Posts: 307
- Joined: Tue Sep 16, 2008 6:04 am
- Location: Madison, WI
- Contact:
Re: Porting a C4 casette program to C4PMF
The main difference between the C4P and the C4PMF is the lack of BASIC ROM, which means there is no built-in screen output handler. If the assembler program makes no use of the video display routines, everything should work. However the C4 monitor ROM only knows how to load file in 65V monitor load format natively.
Most cassette based machine language programs used the 65V monitor load format to load a checksum loader which loaded the remainder of the program with error detection -- many times in MOS/OSI Checksum loader format, but not always. The simple checksum loader could rely on the BASIC screen driver to display characters.
Attached is an OSI/MOS checksum loader program with source that has it's own screen handler built-in. It should work on any video based OSI system. It's not smart enough to handle 64x16 C1E screens though it's easy to change. This loader is currently assembled to start at $4000 to handle a 16K program loading somewhere below $3FFF, so it requires a machine with 18K or more RAM. Feel free to grab the code and use pieces as you see fit. Hope it helps.
I've been using a modified A65 assembler to assemble OSI programs. It can generate loadable object file formats in 65V, 65A, MOS/OSI Checksum, and Intel hex object format as well as binary blobs. It was used to generate the attached program.
When I moved to a C4PMF from a C2P my solution was to build an off-board serial/cassette interface, modify the ROM page select jumpers on the 505 with a switch to toggle between C/W/M? and H/D/M? and put a BASIC ROM at $A000 to fully support my old cassette based programs!
-Mark
Most cassette based machine language programs used the 65V monitor load format to load a checksum loader which loaded the remainder of the program with error detection -- many times in MOS/OSI Checksum loader format, but not always. The simple checksum loader could rely on the BASIC screen driver to display characters.
Attached is an OSI/MOS checksum loader program with source that has it's own screen handler built-in. It should work on any video based OSI system. It's not smart enough to handle 64x16 C1E screens though it's easy to change. This loader is currently assembled to start at $4000 to handle a 16K program loading somewhere below $3FFF, so it requires a machine with 18K or more RAM. Feel free to grab the code and use pieces as you see fit. Hope it helps.
I've been using a modified A65 assembler to assemble OSI programs. It can generate loadable object file formats in 65V, 65A, MOS/OSI Checksum, and Intel hex object format as well as binary blobs. It was used to generate the attached program.
When I moved to a C4PMF from a C2P my solution was to build an off-board serial/cassette interface, modify the ROM page select jumpers on the 505 with a switch to toggle between C/W/M? and H/D/M? and put a BASIC ROM at $A000 to fully support my old cassette based programs!
-Mark
- Attachments
-
- OSI_ChkLod.zip
- OSI Checksum loader with source & build tools
- (30.69 KiB) Downloaded 439 times