[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Auto-format RAMdisk on boot?
shack@pro-ict.cts.com (Randy Shackelford) writes:
> david@wraith.cs.uow.edu.au (David E A Wilson) writes:
>
> >gachenb@eis.calstate.edu (Greg R. Achenbach) writes:
> >>I would like to be able to boot from the RAMdisk in my IIc+ (Ram Express
> >>II with 1 meg). I know I need to format the RAMdisk first. when I do
> >>that, then load the thing, it works fine. My question is this. Is there
> >>some way that I can issue a format command to Prodos automatically upon
> >>boot and then have Prosel automatically load the RAMdisk? Would a small
> >>BASIC program at the front of the disk do this? If so, how?
> >
> >ProDOS does not know how to format a disk. Period.
> >
> >If the disk is a Disk ][ you have to do it all by hand (or get an application/
> >utility that does this).
> >
> >If the disk is a ProDOS block device or a smartport the low level format can
> >be done by calling the ProDOS entry point on the card with the correct command
> >number. This gives you a disk which now will accept read/write block commands.
> >
> >You then have to hand craft a root directory, bit map and (in your case) the
> >boot block.
>
> In every case except one - the 64K RAM disk driver is different in that a
> format call writes a volume directory and bit map too.
>
> >This could be done from BASIC with a little machine language subroutine to
> >do reads and writes.
>
> With the slinky-type memory card all that is necessary is to write the boot
> code to block zero - this can be done with a little assembly.
How do I do this? I need more details.
> >In your case, using ProSel, I amsure it comes with a utility to do exactly
> >what you want. Re-read the documentation on restoring files automatically.
> >When you power on the //c+ it will boot from the floppy and load the RAM disk.
> >>From then on you can boot from the RAM disk (unless it gets corrupted or the
> >power fails).
>
> Indeed, prosel lets you set up a file containing the stuff you want to
> restore to the RAM disk and lets you configure prosel to do it on startup.
I already know that and do it all the time. But in order for the RAMdisk
to be _bootable_ you need to format it first. How do I automagically
format the RAMdisk _before_ Prosel automatically loads it?
> --
> Randy Shackelford "That's right, keep dancing
> shack@pro-ict.cts.com on the minefield"
> -Al Bundy
--
-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-
Greg Achenbach gachenb@eis.calstate.edu
Los Angeles County Outdoor Science School
"Society is like a stew. If you don't keep it stirred up, you get a lot of
scum on top." Edward Abbey