BTW, I might suggest a target memory segment a little further out under memory-hungry DOS 5.0. When I ran DEBUG the CS was already 145D, so that didn't end well. Maybe make it 3000 just to be safe!
I see 3 jumpers on the card. What do they do?
Could this be a similar sort of situation to the jumpers which would restrict larger IDE drives to ~8gb?
A 20mb "compatibility mode" of sorts
I see 3 jumpers on the card. What do they do?
Could this be a similar sort of situation to the jumpers which would restrict larger IDE drives to ~8gb?
A 20mb "compatibility mode" of sorts
I was so hopeful with this trip to the garage! I tried a typoless version (I think!?) of weeedeewee's suggestion, but the computer freezes after the M command.
I tried 640k's debug command, which seemed to work! But... produced another file full of FF (huh!?)
I'm also distracted by work atm so I'll do some more trial and error. At least we got to a point where the ROM was read, now just to get debug to write it properly (I'll also try one from freedos and DOS 6 fwiw)
I was so hopeful with this trip to the garage! I tried a typoless version (I think!?) of weeedeewee's suggestion, but the computer freezes after the M command.
I tried 640k's debug command, which seemed to work! But... produced another file full of FF (huh!?)
I'm also distracted by work atm so I'll do some more trial and error. At least we got to a point where the ROM was read, now just to get debug to write it properly (I'll also try one from freedos and DOS 6 fwiw)
yeah the freezing is likely due to the 1000:0
Change it to 3000:0 like 640KB said.
It is pretty weird though, displaying it works, yet writing to file doesn't. I admit I don't know too much about the workings of debug.
I guess doing a display dump of the bios at c800 would also be usable 😀 [code]D C800:0 2000[/code] nevermind that will require a little more command redirection to get it into a usable file for upload.
1copy con dump.txt 2D C800:0 2000 3Q 4^Z <- this means press Control & Z 5 6debug <dump.txt >dump.bin
1copy con dump.txt 2D C800:0 2000 3Q 4^Z <- this means press Control & Z 5 6debug <dump.txt >dump.bin
That didn't quite work, it seemed to have also copied the debug commands into the file and generated a 40k file (perhaps a loop?)
Anyway! I tried your original suggestion on FreeDOS, and it just worked first time! So perhaps there's some bug on DOS 5's debug.com command? Troubleshooting that is an adventure for another day, for now, here's the ROM!
It does seem to be aware of some 40MB disks (perhaps it can only detect miniscribe capacities, haven't looked to closely into it) and it seems to contain a whole low level format utility!
highvoltagewrote on 2024-04-26, 10:05:That didn't quite work, it seemed to have also copied the debug commands into the file and generated a 40k file (perhaps a loop? […] Show full quote
1copy con dump.txt 2D C800:0 2000 3Q 4^Z <- this means press Control & Z 5 6debug <dump.txt >dump.bin
That didn't quite work, it seemed to have also copied the debug commands into the file and generated a 40k file (perhaps a loop?)
Anyway! I tried your original suggestion on FreeDOS, and it just worked first time! So perhaps there's some bug on DOS 5's debug.com command? Troubleshooting that is an adventure for another day, for now, here's the ROM!
It does seem to be aware of some 40MB disks (perhaps it can only detect miniscribe capacities, haven't looked to closely into it) and it seems to contain a whole low level format utility!
No that is actually a text file hexdump of the bios.
you verify it by doing
1type dump.bin
Given some copy/paste block selection magic it would've been easy enough to enter into a hexeditor and create the actual file.
I doubt you want to try a low level format, but if you want to see it I guess you could
1debug 2g c800:5
It's so tempting, although from what I understand from other docs, once I format a disk in XTA mode it can't be read on an ATA host (which might be useful for this disk). This disks were extremely cheap (and extremely common) in my country in the early 90's, so I'm going to try to get some more of these and then I can low level format one of them (because I am very curious to see what this low level format tool looks like in action!)
The controller appears to determine the drive type from this table by reading I/O port 322, which on XTA would be determined by settings on the drive so probably a combination of the drive id and the capacity jumpers. Regardless your drive is selecting type 0 the way it is set now.
Here's the ROM modded as above, with updated checksum: PX-HDC40.BIN
Of course, usual disclaimer - this is totally untested so no promises it will work or not corrupt data. 😀
640KBwrote on 2024-04-26, 15:16:If you look in the ROM at file offset 025B you can see what would appear to be drive type tables with five built in drive types. […] Show full quote
If you look in the ROM at file offset 025B you can see what would appear to be drive type tables with five built in drive types.
The controller appears to determine the drive type from this table by reading I/O port 322, which on XTA would be determined by settings on the drive so probably a combination of the drive id and the capacity jumpers. Regardless your drive is selecting type 0 the way it is set now.
Here's the ROM modded as above, with updated checksum: PX-HDC40.BIN
Of course, usual disclaimer - this is totally untested so no promises it will work or not corrupt data. 😀
Good luck!
Wow, amazing, thanks! I was reading this and thinking I have to hack this and there's already a whole BIOS extention already to download and burn!
Not sure if it would make a difference, but the ST351A/X is an RLL drive though?
highvoltagewrote on 2024-04-26, 15:29:Wow, amazing, thanks! I was reading this and thinking I have to hack this and there's already a whole BIOS extention already to […] Show full quote
It's so tempting, although from what I understand from other docs, once I format a disk in XTA mode it can't be read on an ATA host (which might be useful for this disk). This disks were extremely cheap (and extremely common) in my country in the early 90's, so I'm going to try to get some more of these and then I can low level format one of them (because I am very curious to see what this low level format tool looks like in action!)
I'm not really familar with this drive, but the docs say that once you low-level format it on an XTA controller it can never ever be used again on an ATA controller? If so, that's concerning.
Being optimistic, the fact that it read the partition table from the drive when the wrong type was set implies there's at least a chance that the drive will work with the existing format and partition if the drive parameters match the previous format. Otherwise, as LLF'ing an IDE drive is generally considered to be perilous, if the modified ROM doesn't work I'm not sure I'd try the XTA ROM formatter. You've already got a different drive than the Miniscribes that this controller was intended to support, and so no guarantees that it wouldn't be somehow destructive.
640KB
Last edited by 640KB on 2024-04-26, 22:24. Edited 2 times in total.
it's an early IDE drive. does it matter if it uses mfm or rll encoding in this case since it's connected as an XTA drive and not via an old MFM or RLL controller.
I'm wondering if changing the drive geometry after booting could work, though that would likely mean the drive itself is no longer bootable due to CHS differences in pre boot vs post boot
Would the XT-IDE bios work for XTA drives ?
Do these old drives even have some sort of Device Identify command that could be implemented and used in the current bios ?
I'm wondering if changing the drive geometry after booting could work, though that would likely mean the drive itself is no longer bootable due to CHS differences in pre boot vs post boot
Would the XT-IDE bios work for XTA drives ?
I came across this post that touched on that, and also other compatibility issues with these drive types. It was from 2010, so no idea if XT-IDE has since added support or not.
Do these old drives even have some sort of Device Identify command that could be implemented and used in the current bios ?
Yeah, see my earlier post. I found this post that clued me in that reading IO port 322 gives a simple (and somewhat model/vendor dependent) drive type. That's what this code at C800:0622 is doing:
1 DRIVE_TYPE_OFFSET: ; drive type to HDP offset table (8 bytes) 2C800:0616 DB 20h, 20h, 10h, 00h ; if bit 4 is 0 3 DB 00h, 00h, 00h, 00h ; if bit 4 is 1 4... 5C800:0622 BA 0322 MOV DX, 0322h ; XTA "drive size bits" port 6C800:0625 A0 0077 MOV AL, [0077h] ; get port offset to current fixed disk adapter 7C800:0628 02 D0 ADD DL, AL ; DX = current port 8C800:062A EC IN AL, DX ; read drive size bits 9C800:062B 80 E2 FC AND DL, 11111100b ; reset to base I/O port 10C800:062E 8A E0 MOV AH, AL ; save result 11C800:0630 24 03 AND AL, 0011b ; isolate disk type bits 12C800:0632 F6 C4 10 TEST AH, 00010000b ; flag in bit 4 set? 13C800:0635 74 02 JZ NO_BIT_4 ; jump if not 14C800:0637 0C 04 OR AL, 0100b ; add 4 to drive type 15 NO_BIT_4: 16C800:0639 32 E4 XOR AH, AH ; zero extend drive type to AX 17C800:063B 8B F8 MOV DI, AX ; move to index 18C800:063D 2E 8A 85 0616 MOV AL, BYTE PTR CS:DRIVE_TYPE_OFFSET[DI] ; get drive type/HDP offset from table 19C800:0642 26 C4 3E 0104 LES DI, WORD PTR ES:[0104h] ; ES:DI = current Hard Disk Parameter table (INT 41h) 20C800:0647 03 C7 ADD AX, DI ; add type offset for new HDP
Haven't really looked for any docs about the other bits, but assume they represent the jumpers on the drive in one way or another. Bit 4 changes the drive type maps, though if it's on then they all just map to the default 20MB. Also, with this table it seems it will never use drive types 3 or 4 so who knows. More study would be required here!
Sorry for being a bit vague with the drive identifier.
I was more alluding to the command in the newer drives that reports the drive geometry and or amount of sectors as for LBA, and is not some lookup from a BIOS table.
Without such a command XT-IDE would need a preconfigured CHS value.
But Yes, more documentation would easily satisfy that inquiry.
weedeeweewrote on 2024-04-26, 17:24:Sorry for being a bit vague with the drive identifier.
I was more alluding to the command in the newer drives that reports the d […] Show full quote
Sorry for being a bit vague with the drive identifier.
I was more alluding to the command in the newer drives that reports the drive geometry and or amount of sectors as for LBA, and is not some lookup from a BIOS table.
Without such a command XT-IDE would need a preconfigured CHS value.
But Yes, more documentation would easily satisfy that inquiry.
Yeah, based on that quick peek at the source I'd guess the identify drive command is not available on XTA, or they'd have used it. Would imagine quality documentation would be a bit harder to come by too, and it sounded like there were non-trivial differences between manufacturers too.
Who can say how many working original XTA drives are in existence today, but I'd think you're very lucky to have one @highvoltage!
weedeeweewrote on 2024-04-26, 17:24:Sorry for being a bit vague with the drive identifier.
I was more alluding to the command in the newer drives that reports the d […] Show full quote
Sorry for being a bit vague with the drive identifier.
I was more alluding to the command in the newer drives that reports the drive geometry and or amount of sectors as for LBA, and is not some lookup from a BIOS table.
Without such a command XT-IDE would need a preconfigured CHS value.
But Yes, more documentation would easily satisfy that inquiry.
Yeah, based on that quick peek at the source I'd guess the identify drive command is not available on XTA, or they'd have used it. Would imagine quality documentation would be a bit harder to come by too, and it sounded like there were non-trivial differences between manufacturers too.
Who can say how many working original XTA drives are in existence today, but I'd think you're very lucky to have one @highvoltage!
Agreed, very lucky to have one, and looking for more of the same.
I have four different machines which could use an XTA drive but I have no XTA drives and never had one.
A simple emulator would be great. Wouldn't be surprised if a pi pico could be turned into one. likely already overkill.
@640K and @weedeewee: I'll look out for drives for you. The ST351A/X was really popular in low end 386's in my country, so there's likely more of them popping up soon.
Cards seem a little more rare, but I have a sharp eye for things that look weird so I'll keep an eye out for those too. Will flash the new rom tomorrow, I'm very curious to try it out!
FYI, off the top of my head, the computers that I have which support an XTA drive are...
ie they have a 40 pin connector where a hard drive normally would get connected eventhough many of these machines were shipped with an MFM or RLL drive&controller
- Commodore PC10-III
- Philips NMS 9100
- Amstrad PC-1640
- ? can't remember, maybe it was only three.
weedeeweewrote on 2024-04-26, 20:51:FYI, off the top of my head, the computers that I have which support an XTA drive are...
ie they have a 40 pin connector where […] Show full quote
FYI, off the top of my head, the computers that I have which support an XTA drive are...
ie they have a 40 pin connector where a hard drive normally would get connected eventhough many of these machines were shipped with an MFM or RLL drive&controller
- Commodore PC10-III
- Philips NMS 9100
- Amstrad PC-1640
- ? can't remember, maybe it was only three.