[Coco] strange nitros9 boot error code, very quickly after loading the boot track I get a tb*v, error 246 not ready

Robert Gault robert.gault at att.net
Wed Nov 24 08:48:09 EST 2010


gene heskett wrote:
><snip>
> Then run ded /dd@ and look at DD.BT at offset $15, which contains 1E F6 9B.
> No change needed.
>
> And that is indeed the 87cd of krn2 if I look at it with ded /sh@ and go to
> sector $0B
>
> Next?  What else can I show?  Here is the directory of that 128th disk as
> shown by dir -e /sh
>
>   Directory of /sh  23:19:19
>
> Owner Last modified Attributes Sector Bytecount Name
> ----- ------------- ---------- ------ --------- ----------
>     0  00/11/22 1948  ------wr       A      7F52 OS9Boot
>     0  00/02/24 1535  --e-rewr      8B       1FF sysgo
>     0  00/11/22 1948  d-ewrewr      8E        80 CMDS
>     0  00/11/22 1948  d-ewrewr      D7        60 SYS
>
> That sysgo is no doubt wrong, but if it stays on the hard drive its 100%
> who cares.

The only thing you need on the boot drive is OS9Boot. You could delete sysgo, 
cmds, and sys.

> Do I need to also update the size in /dd's DD.BSZ?

Well, you can definitely find OS9Boot from OS-9 even though it is on "drive128", 
now that you have told OS-9 where to look. Just make sure your Boot module tries 
to get this information from LSN0 in the normal fashion.

Also your Boot module needs to know how many sectors to read past $1EF69B to get 
the full OS9Boot file into memory. DD.BSZ in LSN0 has that info as the size in 
bytes of OS9Boot. It also sets an upper limit on the size of OS9Boot at $FFFF.
DD.BSZ is at $18-$19, just after DD.BT.

As long as your Boot module reads the hard drive rather than a floppy, you 
should be set. One last thing. If you want to use Cobbler or OS9gen to create a 
new OS9Boot file, you will need a method for correctly pointing DD.BT and DD.BSZ 
to the new OS9Boot file.
If you don't want to use Disk Basic at all, then you will need to make some choices.
1) Will the boot disk always reside in drive 128?
2) Do you want the option of alternate boots by having several drives carrying 
different OS9Boot files? If needed, you could have custom Init and Sysgo modules 
with different names (Init1, Init2, etc.) pointing to different directories on 
the main OS-9 drive.
3) How do you want to manipulate your OS-9 boot drive?
4) How do you want to change LSN0 to point correctly to your current OS9Boot file?

I would not advise using dEd to do this manually unless you intend never to 
change the boot drive number and rarely alter the contents of OS9Boot. If you 
rarely or never use Disk Basic, then you should write an OS-9 program to 
simplify the process of updating DD.BT and DD.BSZ.
The program should ask you for the boot drive number, calculate the LSN starting 
value of OS9Boot, determine the length in bytes of OS9Boot, and alter DD.BT and 
DD.BSZ. But there is a gotcha here!
You will have problems reading beyond the end of the OS-9 drive. dEd will not 
read beyond the last OS-9 sector on your drive nor will any other program that 
uses the default driver for the hard drive. You would need a special driver and 
descriptor that would enable setting a drive# with Dmode, and then correctly 
adding a sector offset to all LSN values while accessing the boot drive. Looks 
like you have done this with /sh.

On my systems, I chose to install a second driver with descriptors that held the 
drive number in stepping (stp); an option not used on a hard drive. Then I can 
Cobbler or OS9gen my /vh0 drive, or just normally read/write to it from OS-9. I 
can also use Dmode to change stp, the boot drive number. I do use LINK.BAS but 
could now easily use dEd because a dir -e /vh0 gives me the sector and byte 
count of OS9Boot on my boot drive.
Having direct access to the boot drive gets rid of the need to use a floppy and 
then back it up to the hard drive boot drivelette.



More information about the Coco mailing list