Booting disks

19 posts / 0 new
Last post
tony359's picture
Offline
Last seen: 4 months 2 weeks ago
Joined: Jun 16 2020 - 16:58
Posts: 291
Booting disks

Hi all,

 

Can someone help me understanding how the Apple //e DOS/PRODOS works when it comes to booting something? 

I was tidying up my disk library today - I "certified" all my disks and I wanted to make a library from the DSK images on my Windows computer.

At some point I encountered "Lemonade stand" which would not work. I blamed a bad disk and spent some time until I realised the DSK file only contained the HELLO file and the LEMONADE.BAS file. 

 

What I did was to write a DOS 3.3 disk using ADTPro and then I copied those two files on it: now it automatically boots to Lemonade Stand.

So my understanding is that the HELLO file is a sort of Autoexec.bat file as it contains this:

 

 10  HOME  20  PRINT  CHR$ (4);"RUN LEMONADE" 

Is that a BASIC program which is automatically run at boot?

Could have I copied the DOS files instead? What files are required? And did it need to be DOS? Could it have been ProDOS?

 

Thanks for pointing me to the right direction!

macnoyd's picture
Offline
Last seen: 6 hours 30 min ago
Joined: Oct 15 2012 - 08:59
Posts: 856
Yes, with a simple fix...

Simply replace the line: 10  HOME  

                                 20  PRINT  CHR$ (4);"RUN LEMONADE" 

with: 10  HOME  

        20  PRINT  CHR$ (4);"CATALOG" 

 

and   SAVE HELLO

 

And your problem will be solved.  Enjoy!

tony359's picture
Offline
Last seen: 4 months 2 weeks ago
Joined: Jun 16 2020 - 16:58
Posts: 291
Hi That's good to know but

Hi

 

That's good to know but that was not my question. To be honest for now I am happy with Lemonade auto-starting. But I'd like to know more on how things work.

Thanks!

macnoyd's picture
Offline
Last seen: 6 hours 30 min ago
Joined: Oct 15 2012 - 08:59
Posts: 856
DOS is the original Apple II Standard ...

ProDOS came later.

 

To each their own, but I prefer the original DOS over ProDOS, but the old DOS has file limitations that ProDOS doesn't.

They are both very different in how they operate.

 

DOS will let you format a disk by simply saying "INIT HELLO", whereas ProDOS requires a utility to format disks.

I would suggest you get a copy of "Beneath Apple DOS" and "Beneath Apple ProDOS" which are avaiilable on the Asimov Web sit and other locations. (free)

It would be impossible to explain DOS in detail on the Forum, lest we make it a log running subject.

I hope this helps you get started...

tony359's picture
Offline
Last seen: 4 months 2 weeks ago
Joined: Jun 16 2020 - 16:58
Posts: 291
I understand. I was hoping to

I understand.

 

I was hoping to get some quick start tips on that but I appreciate it may be too complex for a short summary. If it helps, I started my computer life with MS-DOS 3.3 so I am proficient with that! :) 

In my case, did I have to use DOS with that Lemonade file? Are DOS and ProDOS basically compatible with each other - besides the file limitations you mentioned?

macnoyd's picture
Offline
Last seen: 6 hours 30 min ago
Joined: Oct 15 2012 - 08:59
Posts: 856
Dos and Prodos are not compatible, BUT

In many cases, the files they both hold are compatible.  After all, it's 6502 (or 65C02) code you're dealing with.

There are applications, such as Copy ][ v8.1 (and others) that can transfer files between the two DOS Types, but they don't live in the same command space.

You have to decide which DOS you need to use, or want to use.  ProDOS allows multiple volumes, but DOS 3.3 is it's own volume. (so to speak)

Also, the command structure of ProDOS is different from regular DOS.  "CAT" will catalog a disk in ProDOS, but not DOS.  You have to spell it out in DOS.

ProDOS will recognise upper / lower case letters, whereas DOS only understands the uppercase commands.  Stuff like that.

I hope this makes sense.

tony359's picture
Offline
Last seen: 4 months 2 weeks ago
Joined: Jun 16 2020 - 16:58
Posts: 291
It does thanks! I am slowly

It does thanks!

 

I am slowly making progress here - I am getting more familiar with how it works. I'll definitely take a look at the documentation you pointed out!

Thanks

mmphosis's picture
Offline
Last seen: 1 month 2 days ago
Joined: Aug 18 2005 - 16:26
Posts: 442
booting

Can someone help me understanding how the Apple //e DOS/PRODOS works when it comes to booting something? 

 

The actual "booting" is lower level than Apple DOS 3.3 and ProDOS.  When booting from a DISK ][ drive, a short program (256 bytes) in the disk controller ROM moves the head to track 0 and attempts to read sectors (not files) from track 0.  To run the ROM bootloader, you might type PR#6 which runs a program from slot 6 of the card in the Apple II.

If Track 0 sector 0 is found, this sector (256 bytes) and possibly up to 16 sectors are read into RAM.  (The earlier DISK ][ controller had a slightly different sector format, and only 13 sectors per track.)   In the next stage of booting, the data from track zero is another low level program that is run. At this point, Apple DOS 3.3, ProDOS, Pascal, and many other variations of simpler or more complex programs (or Disk Operating Systems) may be loaded into  RAM.  Many games have simple low level loaders than load the game from tracks and sectors on the disk without needing files.  ProDOS has files, directories, and more complex features than DOS 3.3.

I tend to favor DOS 3.3 over ProDOS, simply because of my familiarity with it and it does everything I need.  DOS 3.3 is stored in the first three tracks and sectors of the disk - it is not a file.  Within those three tracks are the name of the Applesoft BASIC program or Integer BASIC program that the disk was initialized with.  To initialize (erase the disk, format it with the bootloader and DOS 3.3), you might type INIT HELLO but becareful as this will erase what was on the disk without any warning!

If you wanted to from DOS 3.3, you could LOAD LEMONADE to load the lemonade BASIC program, and then INIT LEMONADE to erase the disk with DOS 3.3 and make LEMONADE the program that is run when the disk is booted.  Type PR#6 to boot your lemonade disk which, to recap, runs he ROM boot loader, then runs track 0 boot loader, then runs DOS 3.3 loaded from the first 3 tracks which then runs LEMONADE as the startup program.

tony359's picture
Offline
Last seen: 4 months 2 weeks ago
Joined: Jun 16 2020 - 16:58
Posts: 291
Thank you very much for

Thank you very much for taking the time to write that, appreciated!

 

In fact I gave "beneath Apple DOS" a read and it really goes too deep for my needs. I just wanted to know how to initialise a disk, what happens when you initialise it etc. So I moved to the Apple DOS manual and so far I found all I needed - which is what you kindly summarised for me, mmphosis. I think I read on "beneath Apple DOS" the track zero thing which is very interesting to know.

 

One thing I still don't have very clear is the difference between a SLAVE DOS disk and a MASTER DOS disk. I know how to create both but I am not sure I understand the difference and the pro and cons. Does the Master disk require more space for DOS?

 

Also, I am not sure I understand how FP and INT work - is Integer Basic integrated in the ROMs of an Apple //e? I feel some of the confusion comes to the fact that the //e is a bit more advanced than an Apple // and sometimes books assume you are using an Apple // - the DOS manual I am reading for example mentions that to boot a disk I have to type a command while the //e boots automatically when the system is reset.

macnoyd's picture
Offline
Last seen: 6 hours 30 min ago
Joined: Oct 15 2012 - 08:59
Posts: 856
I'll give this a shot ...

The difference between a Master DOS Disk and a slave DOS Disk is:

A Master DOS Disk is a DOS formatted Disk that contains the Disk Operating System within the boot tracks.  This boots up DOS into memory and allows you to read a formatted disk with -or without DOS boot tracks.

A Slave DOS Disk is formatted the same as a Master DOS Disk, only the boot tracks are used for storing files rather being wasted with the Disk Operating System. (DOS)

 

Generally, I initialize disks and leave DOS on there so I don't have to swap for one that has it when starting up the Apple ][.

 

FP is for Floating Point Basic, or Applesoft Basic.

INT is for Integer Basic, which is generally loaded into the 16K memory card.  Integer was the first operating system of the Apple ][, when it was first released.

It's still considered "Basic" per se, though it is a somewhat scaled down version of Applesoft Basic.  Several commands and functions were added to Applesoft Basic that were not contained with Integer Basic.

Apple worked with Microsoft to develop Applesoft Basic around the time they were releasing the Apple ][ Plus.  I think it was out before the release, but the Plus model had it included as standard.

 

The Apple ][e came a bit later.  The ][e was designed to address more banks of memory, would output upper and lower case letters as a standard feature, had more stable video, used fewer IC's to perform relative functions, had a larger ROM space which would handle more internal routines, etc. etc.  -It was a basic hardware upgrade to the Apple ][ Plus.  Different computer really, though they kept backward compatibility as a part of their overall business plan.  Smart at the time for sure.  The Apple ][GS took it even further by including the 65C816 Microprocessor, which would act as an 8-bit or 16-bit computer. (8-bits being 6502 compatible, sort of)  Still, for the most, held backward compatibility but also offering even more enhancements to grow capabilities.

tony359's picture
Offline
Last seen: 4 months 2 weeks ago
Joined: Jun 16 2020 - 16:58
Posts: 291
  A Master DOS Disk is a DOS
 

 

A Master DOS Disk is a DOS formatted Disk that contains the Disk Operating System within the boot tracks.  This boots up DOS into memory and allows you to read a formatted disk with -or without DOS boot tracks.

A Slave DOS Disk is formatted the same as a Master DOS Disk, only the boot tracks are used for storing files rather being wasted with the Disk Operating System. (DOS)

 

Thanks for the explanation! I have a few questions if you allow me. 

I am not sure I understand this fully I'm afraid - it must be my MS-DOS background! I can boot up a Slave disk (created with INIT HELLO) and it boots up and takes me to a prompt where I can run CATALOG and so. 

In other words, what is it that I CANNOT do using a SLAVE disk? The manual also mentions some dynamic memory allocation which is exclusive for the MASTER disk.

 

FP and INT: so the Apple //e comes with FP as standard I guess. And "]" is the prompt for FP and it is loaded from the ROM. So when I boot the Apple //e WITHOUT a disk and press CTRL-RESET to drop to the ] prompt, that is Applesoft Basic (FP)? Does that mean that the older Apple ]['s had INTeger Basic in ROMS so if you wanted FP Basic you had to load it from a disk?

And what do you mean with "16K memory card" means? On an Apple //e all the standard memory is on the motherboard - I see this on manuals too and it confuses me, along with "language card" :) 

 

Sorry for the many questions and thanks!

macnoyd's picture
Offline
Last seen: 6 hours 30 min ago
Joined: Oct 15 2012 - 08:59
Posts: 856
I guess that is supject to interpretation

I guess that is subject to interpretation. (i.e.; Slave Disk)  Some programs consider the "Slave disk" a Data disk of sorts, regardless if they are Initialized with the boot tracks.  My interpretation is in regard to DOS by itself.

Think of it like using an old MS-DOS disk that's bootable, (master) or one that's simply formatted, but with no boot tracks, therefore un-bootable. (slave)

 

Re: FP and INT: so the Apple //e comes with FP as standard I guess. And "]" is the prompt for FP and it is loaded from the ROM. So when I boot the Apple //e WITHOUT a disk and press CTRL-RESET to drop to the ] prompt, that is Applesoft Basic (FP)? Does that mean that the older Apple ]['s had INTeger Basic in ROMS so if you wanted FP Basic you had to load it from a disk?

 

Correct on all points.  You could even swap the ROMS from an old Integer Language Card to the Motherboard if you want.  But not with the Apple ][e and later. (!)  You would have to load that into memory.

 

The Apple][e has a different archetecture.  It can perform like a ][ or ][ Plus, but it has addressing to more RAM by default, whereas the older ]['s didn't.  Remember, the old Apple ][ was sold with 16K of RAM that you could add to, in 16K increments.  RAM was expensive back then.  Certainly a different story today.

tony359's picture
Offline
Last seen: 4 months 2 weeks ago
Joined: Jun 16 2020 - 16:58
Posts: 291
Think of it like using an old

Think of it like using an old MS-DOS disk that's bootable, (master) or one that's simply formatted, but with no boot tracks, therefore un-bootable. (slave)

This is what puzzles me. If I "INIT HELLO" a disk, it still boots and takes me to the ] prompt and I can execute stuff. If I make a master disk, it does the same and I do not see any difference when I run CATALOG. 

 

Correct on all points.  You could even swap the ROMS from an old Integer Language Card to the Motherboard if you want.  But not with the Apple ][e and later. (!)  You would have to load that into memory.

Can you clarify what "language card" means please? Is/Was that an actual card?

 

Thanks again!

mmphosis's picture
Offline
Last seen: 1 month 2 days ago
Joined: Aug 18 2005 - 16:26
Posts: 442
Initializing New Diskettes

This is what puzzles me. If I "INIT HELLO" a disk, it still boots and takes me to the ] prompt and I can execute stuff. If I make a master disk, it does the same and I do not see any difference when I run CATALOG. 

 

The terminology is definitely puzzling.

I agree with macnoyd for MS-DOS about slave vs. master.  The terms SLAVE and MASTER mean many things.  I prefer the terms Data disk (non-bootable), and Boot Disk (bootable.)

 

DOS 3.3 and DOS 3.3

MS-DOS 3.3 (Microsoft DOS for 8086 PC) has little to do with Apple DOS 3.3 for 6502 Apple II. 

 

Initializing New Diskettes

 

In Apple DOS 3.3, the SLAVE and MASTER terms mean different things! Slave and Master do not mean Data disk (non-bootable), and Boot Disk (bootable) in Apple DOS 3.3.  You are correct that both SLAVE and MASTER disks in Apple DOS 3.3 are both bootable!

 

Master diskette (bootable)

I am reading page 13 of The DOS Manual. (Apple II.)  According to the manual, the System Master diskette is a very special diskette.  Put aside the System Master diskette supplied by Apple Computer. Put it where it won't be damaged by heat, physical stress (kids?, dogs?) or magnetic objects. And where it won't get lost. It should be treated especially carefully, since it contains useful programs.

 

Slave diskette (bootable if you have enough RAM, and you do.)

The INIT command can be used to INITialize a "slave" diskette.  Slave diskettes are memory-size dependent: the size of the system which initializes the diskette determines the size of the system which can use the diskette.  If a slave diskette is created on 32K system, then it can only be used on a system with 32K or more memory. On larger system, only 32K of memory will be used. After initializing a slave diskette, you can use the MASTER CREATE program (see Chapter 5) to transform your slave diskette into a "master" diskette whose DOS is self-relocating so that memory is used efficiently.

 

The slave vs. master diskette only matters if you have an Apple II with less than 48K of RAM.  So, don't worry about it.  Use INIT to create slave diskettes which will be bootable on an Apple II with 48K or more memory.

 

By the way, you can create Apple DOS 3.3 disks that are not bootable "data disks" as I like to call them, but this is getting into customization which is another puzzling topic altogether.

 

tony359's picture
Offline
Last seen: 4 months 2 weeks ago
Joined: Jun 16 2020 - 16:58
Posts: 291
Ok. So it makes sense that it

Ok. So it makes sense that it doesn't make sense! :D 

But it makes more sense now! :) 

Offline
Last seen: 4 days 5 hours ago
Joined: Nov 20 2004 - 00:26
Posts: 53
Master versus Slave disk

A Master DOS Disk is a DOS formatted Disk that contains the Disk Operating System within the boot tracks.  This boots up DOS into memory and allows you to read a formatted disk with -or without DOS boot tracks.

A Slave DOS Disk is formatted the same as a Master DOS Disk, only the boot tracks are used for storing files rather being wasted with the Disk Operating System. (DOS)

 

I would like to jump in here, I've been reading along and enjoying memories of my first Apple II.

I have a different understanding of a Master and a Slave diskette.  Both disks have DOS in the first 3 tracks.  A Master diskette boots into any memory size from 16K to 48K.  It checks memory size and relocates to highest RAM memory during boot.  So if you had a 16K  or 32K Apple II, DOS would end up residing in the highest part of the 16K or 32K leaving not much room for anything else.  (Later someone worked out how to relocate DOS even higher into the 16K memory card.)  Most people ended up with a 48K Apple II so a Master diskette would relocate DOS into the highest part of the 48K.

 

 On the other hand, a Slave diskette did not attempt to relocate DOS on boot.  So if you made (INIT HELLO) the Slave diskette on a 48K machine, then at boot, DOS was loaded into the highest part of that 48K.  However, if the Slave diskette was made on a 32K machine, then DOS was loaded into the highest part of the 32K RAM, even if you booted it on a 48K machine.  

 

There was a program on the DOS 3.3, 3.2 and 3.1 diskettes called MASTER CREATE that would change a Slave diskette into a Master diskette so that it would try and relocate to any size RAM greater than 8K.

 

With the Apple II going to 64K with the 16K RAM card or an Apple IIe with a built in 64K, and virtually all machines having 48 or 64K, then the idea of a Master and a Slave diskette faded from view.  

 

PS:  My first machine had a 4K rev 0 motherboard, purchased from Electronic Concepts in Sydney who later became Computerland.  I enlarged the RAM (at great expense I might add)   to 16K so I could boot DOS 3.1....diskettes that I still have here somewhere!!

 

Offline
Last seen: 4 days 5 hours ago
Joined: Nov 20 2004 - 00:26
Posts: 53
OOPS, sorry mmphosis, I seem

OOPS, sorry mmphosis, I seem to be saying what you are saying.

Your post was not there (or I did not see it) when I posted.

tony359's picture
Offline
Last seen: 4 months 2 weeks ago
Joined: Jun 16 2020 - 16:58
Posts: 291
I enjoyed the extra

I enjoyed the extra explanation, thanks!

mmphosis's picture
Offline
Last seen: 1 month 2 days ago
Joined: Aug 18 2005 - 16:26
Posts: 442
memory and DOS 3.1
laurieboshell2004 wrote:

OOPS, sorry mmphosis, I seem to be saying what you are saying.

Your post was not there (or I did not see it) when I posted.

 

I really liked your explanation, thank you for posting.

 

The 4K rev 0 motherboard expanded to 16K so you could boot DOS 3.1....diskettes.  That sounds intriguing.  I am not sure what rev my 48K Apple II plus was.  I've only seen a few DOS 3.1 diskettes, the main one being (I am guessing) the modified DOS 3.1 for Castle Wolfenstein.

Log in or register to post comments