Search Posts:

Saving Memory to Disk Commodore PET

SHARE

Return to Threads

  Saving Memory to Disk Commodore PET by Bill Degnan - 10/27/2009 22:11
Here are the directions for saving a block of memory (as in a program written to memory from a machine language program loaded from cassette) to disk.

1. format your disk. I have a 2040 attached to my Commodore PET 2001-16N

OPEN 1,8,15
PRINT#1,"N0:DISKNAME, 01"

2. Load the program you have, know where it's been loaded. For example, BREAKOUT is loaded by cassette into memory locations 033F to 1491

SYS 1024 - command to load TIM monitor from READY prompt of PET

.S "0:BREAKOUT",08,033F,1491

this means on drive 0, create a file called BREAKOUT on unit 8 that consists of what's in memory locations 033F through 1491. Drive 0 on unit 8 is the right hand drive of the model 2040.

The disk drive should activate and create the file. Reboot. Load the program

load "breakout",8,0 (assuming the disk is still in the right side drive)

Enjoy.

Reply
  Copy Machine Lang PET Cassette Programs by Bill Degnan - 07/22/2010 20:13
Let's say you want to copy a PET (or C64) cassette tape program. You load the program you want to save, try to LIST it, and than you realize it's a machine language program (there is no BASIC listing). Unlike BASIC programs, you can't simply load a program on the source cassette and then save it on a target cassette using BASIC commands.

Here is how to make a copy of a machine language program using the TIM monitor program. TIM is built into the PET ROMs

1. load program on source cassette

2. SYS 1024 (to enter TIM monitor)

3. at the . prompt type:

S S "FILENAME",01, 033F, 1491 [enter]

4. The computer should ask you to press play and record on the tape drive.

NOTE.
01 = tape unit 1.
033F = start location of machine lang program in memory
1491 - end location of machine lang program in memory.

If you're making a copy of a program on a PET with an internal drive and you want to copy to the external drive the tape unit would be 02.

Reply

Resources:


Buy a Commodore Computer Poster

Popular Topics and FAQs


Past Issues:


II plus n II e

This image was selected at random from the archive. Click image for more photos and files from this set.