Kchula-Rrit Posted July 4, 2020 Share Posted July 4, 2020 In my ramblings with Level-2 and Level-3 I/O I found that, if a file is opened for Level-3 I/O, a Level-2 I/O call appears to fail. In a test program I open a DF128 file and read the contents. At EOF I close the file. The test program uses a copy of Tom Bentley's "TCIO" library that I disassembled and modified. I added two functions, 'tstat' and 'tstats' 'Tstat' uses the Level-3 STATUS (Op-code 9) command to get information about the test file. 'Tstats' uses the Level-2 Get-File-Info (0x14) command to get information. I was going to merge the two so I can get info to load a PAB for Level-3 access. Before and after each Level-3 TCIO call I use 'tstat' and 'tstats' to see how the information changes as the program performs the various library calls: Use 'tstat' to get file status (Level-3 Op-code 9). Print results and info. Use 'tstats' to get file information (Level-2 Op-code 0x14) Print results and info. Do a Level-3 operation. Get file status (Level-3 Op-code 9). Print results and info. [Repeat Step 1.] Get file status (Level-2 Op-code 0x14). Print results and info. [Repeat Step 2.] I found that Level-2 'Get File Info' command appears to fail with Error Code 7 (file error) if the file is opened for Level-3 access. After closing the file the Level-2 commands once again work. My merged file-info function will have to skip calling the Level-2 call if the file is open, but I do not see that being a problem. Also, I hate to say that my copy of Thierry Nouspikel's TI99-Pages has the 0x14 command returning the record-count at Result-pointer+8 as a byte value. Fred Kaal says this is a word value, and my experiments seem to indicate the record-count is a word. Both sites have been immensely useful for my experiments. K-R. 2 Quote Link to comment Share on other sites More sharing options...
+Lee Stewart Posted July 4, 2020 Share Posted July 4, 2020 6 hours ago, Kchula-Rrit said: Also, I hate to say that my copy of Thierry Nouspikel's TI99-Pages has the 0x14 command returning the record-count at Result-pointer+8 as a byte value. Fred Kaal says this is a word value, and my experiments seem to indicate the record-count is a word. Yeah—the TI document, GPL Interface Specifications for the 99/4 Disk Peripheral, indeed, has it as a word. As you say, Thierry’s site is a wealth of information for our TI-99/4A, but does have errors here and there. Others and I have pointed them out over the years. Most (all?) of my discoveries could be characterized as my tripping over them. ? Thierry has it wrong for subprogram >015, as well. He makes a similar error with every instance of the transfer block’s error-return location, >8350 (probably a copy/paste error), which is a byte, not a word as he indicates. ...lee 1 Quote Link to comment Share on other sites More sharing options...
Kchula-Rrit Posted July 7, 2020 Author Share Posted July 7, 2020 On 7/4/2020 at 6:29 AM, Lee Stewart said: Yeah—the TI document, GPL Interface Specifications for the 99/4 Disk Peripheral, indeed, has it as a word. As you say, Thierry’s site is a wealth of information for our TI-99/4A, but does have errors here and there. Others and I have pointed them out over the years. Most (all?) of my discoveries could be characterized as my tripping over them. ? ... ...lee Good to know I'm not the only one that 'trips' over these things... The GPL Interface Spec is probably the one document I haven't read until I'm bleary-eyed. I figured, I'm doing assembly, not GPL, so I never thought to look at it. K-R. 2 Quote Link to comment Share on other sites More sharing options...
RXB Posted July 7, 2020 Share Posted July 7, 2020 I have read every GPL form of Data so many times I can recite some on command. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
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.