RayeR wrote on 2022-12-13, 15:39:
Hi,
I succeed to make a simple IOCS16# decoder using 2 log. gates IOs 7432 and 7403 (simple grounding of IOCS16# is no go as only data register requires 16-bit access and other regs. needs 8-bit). Now the SSD is identified properly and works fine on that ancient 386 with XTIDE BIOS. I plan to make some compact PCB with SMD parts that could be “glued” to backside of old IDE controller 40-pin header. Thanks to rasz_pl for valued posts helping to solve this puzzle.
Here are some photo and schematic diagram of decoder:
I know I'm a few years late to the conversation, but I've spent too much time thinking about it to not share. This solution seems fine, but I kept wondering if it there was a more "elegant" way to do it, with a single IC. I spent a lot of time trying to arrange individual logic gates to accomplish it similarly to RayeR's idea, but later I realized that the signal names correspond almost perfectly to the inputs of a 74x138 address decoder. It makes me wonder if maybe the earliest IDE drives were designed with this chip (or the similar 74x139).
So I think a design like this would work well:
The attachment iocs16 gen.jpg is no longer available
The diode is necessary to prevent the line from being pulled high while other devices are using it, since 74x138 doesn't have open collector outputs. I think a schottky would be a good choice. The specific 74x138 variant is important, because of supply voltage and drive current. ATA-2 specifies a minimum 12ma sink current, but I've seen mentions of 300 ohm IOCS16 pull-ups on some ISA boards, so sinking 17ma might be required in rare cases. The 74AC138 or 74ACT138 might be good choices.
I haven't actually tested this, since I don't currently own an ISA bus PC. I only researched the idea because I was thinking of designing it into another project, but for various reasons I probably won't.