GDMike Posted August 10, 2020 Author Share Posted August 10, 2020 (edited) I couldn't find any assembler code that pulls the date/clock from the TIpi. I threw everything I could into this code and I don't know what everything is, but I got my results. Feel free to chime in with a better way to pull the date and clock seperately. Lol, I'm just thrilled to get this far in my own, so plz don't laugh...hey, you there! I heard something!! VID_20200810_082517539.mp4 Edited August 10, 2020 by GDMike Spell chk 1 Quote Link to comment Share on other sites More sharing options...
+9640News Posted August 10, 2020 Share Posted August 10, 2020 18 minutes ago, GDMike said: I couldn't find any assembler code that pulls the date/clock from the TIpi. I threw everything I could into this code and I don't know what everything is, but I got my results. Feel free to chime in with a better way to pull the date and clock seperately. Lol, I'm just thrilled to get this far in my own, so plz don't laugh...hey, you there! I heard something!! VID_20200810_082517539.mp4 10.34 MB · 1 download If you look in the AfterHours BBS topic area, and then download one of the zip files, I have assembly source code for pulling the time/date from the TIPI. Basically, you need to setup up PAB, open it, read it, and then close it. The calling routine is found in BBSSETUP in the source directory, and I think BBSCLOCK has the code where it does the actual opening, reading, and closing. You should be able to pull up the earliest source files so you do not need the huge zip files that also include the download library. After you get the time, you will want to periodically update the time if you choose to display the time. The source also has in the BBSCLOCK routine the code for the interrupt driven timer. It too is called up from BBSSETUP. Beery 2 Quote Link to comment Share on other sites More sharing options...
+9640News Posted August 10, 2020 Share Posted August 10, 2020 Please note the interrupt close is also setting some other BBS flags for the BBS program to deal with hang ups or timeout issues you would not need. Beery 1 Quote Link to comment Share on other sites More sharing options...
+9640News Posted August 10, 2020 Share Posted August 10, 2020 I should also add Matt’s description of how to access the clock is spot on, however if you do not have a ton of assembly experience, first time writing the assembly routine to open, read, close, display, etc. could pose a challenge. Beery 1 Quote Link to comment Share on other sites More sharing options...
GDMike Posted August 10, 2020 Author Share Posted August 10, 2020 (edited) I figured it out after a few minutes. But yup, I'm finally reading the data seperately now. VID_20200810_085958116.mp4 Edited August 10, 2020 by GDMike 2 Quote Link to comment Share on other sites More sharing options...
+Lee Stewart Posted August 10, 2020 Share Posted August 10, 2020 50 minutes ago, GDMike said: I couldn't find any assembler code that pulls the date/clock from the TIpi. I threw everything I could into this code and I don't know what everything is, but I got my results. Feel free to chime in with a better way to pull the date and clock seperately. Lol, I'm just thrilled to get this far in my own, so plz don't laugh...hey, you there! I heard something!! ■ ■ ■ Perhaps I am being a bit harsh here, but it is very frustrating to try to help you with your code when you post it this way. Normal text posts are so much more useful and easier to read if someone wishes to assist you. Cutting and pasting code is considerably faster and safer than error-prone re-typing of code. I thoroughly enjoy troubleshooting your code with you, but not with these code screen graphics. ...lee 1 Quote Link to comment Share on other sites More sharing options...
GDMike Posted August 10, 2020 Author Share Posted August 10, 2020 (edited) But I'm on real hw. Sorry for the inconvenience. But I do have a phone. Lol But the photos are in order. This was just informational anyway, since I already got the code working. Edited August 10, 2020 by GDMike Typo 1 Quote Link to comment Share on other sites More sharing options...
+TheBF Posted August 11, 2020 Share Posted August 11, 2020 7 hours ago, GDMike said: But I'm on real hw. Sorry for the inconvenience. But I do have a phone. Lol But the photos are in order. This was just informational anyway, since I already got the code working. I am wondering if you have an RS232 card in your TI-99 GDMike? Then you can get a shareware/freeware terminal program for your PC and "print" your source code to the PC with the printer device as: "RS232.BA=9600". Then post that file here on Atariage. Would that work for you? 2 Quote Link to comment Share on other sites More sharing options...
GDMike Posted August 11, 2020 Author Share Posted August 11, 2020 (edited) No printer, Except my cannon wifi. But I could pull my source IF needed over on the TIpi side and load it up with classic99. it'sa hassle for something quick and dirty though since I get Atariage thru my password remembered phone, not using my laptop for anything related to internet anymore, I use my phone for everything. But, like I said, if needed I could tap into my file manager on my phone and pull a source file from my samba share on the raspberry pi and upload that to Atariage also. But.... pictures work for eyeballing code. But if the intention is to use it as paste code, naaa.. photos really sucks at that. I'm actually writing to you while watering my yard. Lol, meaning, I don't use a PC or laptop if I can help it. BUT I do use classic for compiling, again grabbing a shared file on the pi folder and running at max operation for compiling. ? Edited August 11, 2020 by GDMike Typos stupid spell check Quote Link to comment Share on other sites More sharing options...
+9640News Posted August 11, 2020 Share Posted August 11, 2020 Another simple way to paste code, etc. If the source code is on the TIPI already, use TIDIR on your PC to open up the source code file and do a copy/paste to Atariage of the segment in question. The nice thing about pasting code, versus photos, is that others can paste the segments into either their code or test your code out trying to help you through an issue. Beery 1 Quote Link to comment Share on other sites More sharing options...
GDMike Posted August 11, 2020 Author Share Posted August 11, 2020 of course when it's code to troubleshoot I'll try better to get the code in a text format. These days, when people say, let's see the code, pictures are just out there and are simple to produce. Lol Quote Link to comment Share on other sites More sharing options...
GDMike Posted September 4, 2020 Author Share Posted September 4, 2020 I saw this on SNP comments.. DATA operands are words (2 bytes), so you need to double the selection number to get the proper index into the table. Also, your BL will try to execute that word. You need to load that word into a register: SUBTAB DATA SUB0,SUB1,SUB2,SUB3,SUB4,SUB5,SUB6 LI R1,3 * select sub-routine 3 SLA R1,1 * double R1 to get proper index MOV SUBTAB@(R1),R1 * load the sub-routine address BL *R1 * branch to it ...lee Quote Link to comment Share on other sites More sharing options...
GDMike Posted September 4, 2020 Author Share Posted September 4, 2020 (edited) I saw this on supernotes comments.. DATA operands are words (2 bytes), so you need to double the selection number to get the proper index into the table. Also, your BL will try to execute that word. You need to load that word into a register: SUBTAB DATA SUB0,SUB1,SUB2,SUB3,SUB4,SUB5,SUB6 LI R1,3 * select sub-routine 3 SLA R1,1 * double R1 to get proper index MOV SUBTAB@(R1),R1 * load the sub-routine address BL *R1 * branch to it ...lee Edited September 4, 2020 by GDMike Quote Link to comment Share on other sites More sharing options...
apersson850 Posted September 4, 2020 Share Posted September 4, 2020 (edited) So in this particular case, you write it like this, since the index into the table is fixed, and you already know both the index and that it needs to be mulitplied by two. Hence there's no reason to let the CPU calculate that each time. The assembler can do it at assembly time instead. It's different if the SUBTAB index can vary, and is calculated by some other code before this snippet, of course. SUBTAB DATA SUB0,SUB1,SUB2,SUB3,SUB4,SUB5,SUB6 MOV @SUBTAB+(3*2),R1 * load the sub-routine address BL *R1 * branch to it Edited September 4, 2020 by apersson850 2 1 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.