Jump to content
IGNORED

TI disk controller DSR


Recommended Posts

5 hours ago, Gary from OPA said:

Reviewing the schematic of the ti fdc the best way I think to disable it is to add a switch to the PCBenable line going to the PAL that does all the decode logic.

 

That would be pin 9 on the u18 custom logic chip. Normally it is always HIGH so bringing that pin LOW to ground should make the card 100% invisible to the system.

 

Now, on the P-CODE card they have the switch going thru some caps/resistors and a double OC buffer to de-couple the switch to remove any bounce and to make sure there is no temporarily connection between 5volts and ground incase the user toggles the switch while the system is on.

 

But, you should be safe enough on the FDC if you just make sure only to use it when power is off or install a "break before make" switch or 3 position switch so there is a middle do totally nothing position between the on and off sides to separate signals fully  when switching between the PCBEN high and pulled to low ground.

 

I'm going to give it a try. Easy enough (famous last words).

Link to comment
Share on other sites

I'd say you are approaching the problem from the wrong side, completely.

The p-system does scout for a device with the ability to do disk sector read/write at boot time. When one is found, and that's normally the standard disk controller, it will create a PCB (Peripheral Control Block) for that device. The PCB is a PAB (Peripheral Access Block) as we know it from the standard system augmented with the CRU base address of the card and the entry address of the desired program, which in this case is the sector read/write, with code 10H.

It will also populate the PAB part of the PCB with the correct values.

 

On all further accesses to that device it will fill in the current numbers for the drive and sector to access in the PAB part, grab the CRU base address from the PCB and branch to the address also stored in the PCB.

The same PCB is used by all disks, which is why the system normally can have only one disk controller. The p-system can have up to six disks, although no normal disk controller for the TI supports more than four. The p-system has a table for the units 0-32, where units #4, #5 and #9 are preset to point to the disk BIOS routines. The disk unit pointer points to another set of four pointers, corresponding to BIOS entries for the four Pascal statements unitclear, unitwrite, unitread and unitstatus for that particular type of device. The BIOS routines are on the p-code card, but eventually they branch to a part loaded into the 8 K RAM, since they must turn off the p-code card itself to access another card. The code in the 8 K RAM will then use the PCB to actually call the disk controller's sector read/write routine.

To add a fourth disk drive, if you have a CorComp controller or similar, you simply enter the same pointer into the IO unit table corresponding to unit #10. Done.

 

Now if you want to replace the standard disk controller with another one, which supports disks in the same way, you can simply patch new values into the PCB for CRU and subprogram entry addresses. If you want to add a different type of controller, like a RAMdisk, which is used in parallel with the floppy disk controller, you have to create a different PCB, since it will have a differnt CRU address. To avoid the issue with encroaching on VDP RAM so you can't start the editor properly, I create that PCB in the sprite table or far down in the character definition table.

  • Like 2
Link to comment
Share on other sites

4 hours ago, apersson850 said:

I'd say you are approaching the problem from the wrong side, completely.

The p-system does scout for a device with the ability to do disk sector read/write at boot time. When one is found, and that's normally the standard disk controller, it will create a PCB (Peripheral Control Block) for that device. The PCB is a PAB (Peripheral Access Block) as we know it from the standard system augmented with the CRU base address of the card and the entry address of the desired program, which in this case is the sector read/write, with code 10H.

It will also populate the PAB part of the PCB with the correct values.

 

On all further accesses to that device it will fill in the current numbers for the drive and sector to access in the PAB part, grab the CRU base address from the PCB and branch to the address also stored in the PCB.

The same PCB is used by all disks, which is why the system normally can have only one disk controller. The p-system can have up to six disks, although no normal disk controller for the TI supports more than four. The p-system has a table for the units 0-32, where units #4, #5 and #9 are preset to point to the disk BIOS routines. The disk unit pointer points to another set of four pointers, corresponding to BIOS entries for the four Pascal statements unitclear, unitwrite, unitread and unitstatus for that particular type of device. The BIOS routines are on the p-code card, but eventually they branch to a part loaded into the 8 K RAM, since they must turn off the p-code card itself to access another card. The code in the 8 K RAM will then use the PCB to actually call the disk controller's sector read/write routine.

To add a fourth disk drive, if you have a CorComp controller or similar, you simply enter the same pointer into the IO unit table corresponding to unit #10. Done.

 

Now if you want to replace the standard disk controller with another one, which supports disks in the same way, you can simply patch new values into the PCB for CRU and subprogram entry addresses. If you want to add a different type of controller, like a RAMdisk, which is used in parallel with the floppy disk controller, you have to create a different PCB, since it will have a differnt CRU address. To avoid the issue with encroaching on VDP RAM so you can't start the editor properly, I create that PCB in the sprite table or far down in the character definition table.

Yes, that was the original idea. However I don't know where in VDP RAM the PCB's are. And I'll have to write a VDP RAM viewer/editor to be able to see what's going when the TIPI is connected and test things out. PATCH only deals with expansion RAM...That said, it's a lot simpler to just have a switch on the controller to instanly swap between TIPI and physical drives.

  • Like 1
Link to comment
Share on other sites

It worked! I pulled out pin 9 of U18 and connected it to the center pole of a tri-pole switch, with the other 2 poles connected to ground and the pin 9's pad respectively, so when the controller is switched off, the pcode card will access the TIPI drives and the Editor will work without a stack overflow, but only if TIPI is at CRU >1100. If TIPI is at >1000, then the card will recognize it and boot up but the Editor will crash, and if it is above >1100 then the pcode card will not boot. So it seems that the pcode card is hardcoded in ROM to expect a controller at >1100.

So I ended up wiring a 2-slot dip switch connected to CRU >1100 and >1800 on the TIPI CRU selector. When both are off then TIPI is at >1000. 

 

TIPI at >0000: TI controller on. pcode card off. Can access both TIPI and physical drives

TIPI at >1100: TI controller off. pcode card on and will boot from the TIPI drives

TIPI at >1800: TI controller on. pcode card on and will boot from the physical drives

 

A software solution would have been more elegant, but it would come with its own set of problems such as having a separate boot disk for the pcode card depending on whether we want to use the TIPI drives or the physical drives.

  • Like 4
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...