|
Post by Stretch on Jul 1, 2023 20:34:55 GMT
If I have two drives attached, 1541U as 8 and uIEC as 10, how can I use DS$ to read the error channel of both? By default it reads device 8 but I can't manage to read device 10. Any ideas? Thanks.
|
|
|
Post by virtualsky on Jul 2, 2023 19:09:00 GMT
I did some testing..... DS$ seems to read the error channel no matter what disk drive caused the error.
I put a floppy disk in drive 8 and not in drive 9. Then I did a DIRECTORY of 8, then a DIRECTORY U9 for drive 9. When I got the error light on drive 9, I then printed DS$ and it gave me the 74,DRIVE NOT READY error, even though it was drive 9's error, not drive 8.
I don't know if this helps or not.
|
|
|
Post by Stretch on Jul 3, 2023 19:32:52 GMT
Thanks for the reply. I tried your suggestion and it worked as you described. However after reading DS$ (for drive 9) as above, if you then try to load a non-existent file from drive 8 (LOAD"XXX",8), DS$ is "stuck" on device 9. You would expect FILE NOT FOUND but instead you get 00, OK, 00, 00. I'm looking into this a bit more as I suspect there is a way to do what I want but I just haven't found it.
EDIT: maybe I wasn't clear in my first post. I am wanting is to be able to read DS$ for one drive then if necessary read DS$ for the other drive. If both drives have errors, I want to pick one, read DS$ for that drive, then read DS$ for the other. What seems to happen is, whichever drive is read first, DS$ locks to that drive.
|
|
|
Post by virtualsky on Jul 3, 2023 23:23:31 GMT
Yes, that's what I noticed too. I could not figure out how to just read the error for each individual drive. I don't have enough knowledge about the 1541/1571 DOS functionality to even know if that's possible.
When I do a similar test, the error channel seems to read the last error that was communicated. So, I don't have a disk in drive 9, but on in drive 8. I do a DIRECTORY U9 and the drive's light flashes. Typically, if I did a ?DS$ now, it would report the drive not ready. But, rather I try to load a non existent file on drive 8 and, if I do the ?DS$ after that, I get the file not found error. So, drive 8 replaced drive 9's message. However, I cannot seem to get the error from drive 9 now, unless I try the directory command again.
|
|
|
Post by remark on Jul 4, 2023 17:44:46 GMT
If I have two drives attached, 1541U as 8 and uIEC as 10, how can I use DS$ to read the error channel of both? By default it reads device 8 but I can't manage to read device 10. Any ideas? Thanks. To switch drives you can use the dclose command first to close an unopened filenumber on the new drive.
Example:
Drive #8 is the current active drive. To switch to drive #10 you do:
DCLOSE #99,U10
Now drive #10 is the active drive. To switch back to drive #8:
DCLOSE #99,U8
|
|