Jump to content

moulinaie

Members
  • Content Count

    348
  • Joined

  • Last visited

Community Reputation

46 Excellent

About moulinaie

  • Rank
    Moonsweeper
  • Birthday 03/23/1966

Contact / Social Media

Profile Information

  • Gender
    Male
  • Location
    France, Burgundy
  • Interests
    Programming, Retrocomputing, Guitar, Singing

Recent Profile Visitors

4,915 profile views
  1. I started with a TI-57, very good machine in spite of the limited amount of memory. Then a TI-58C... and then a TI-66 (very disappointed with the low speed of this last...) Then a TI-59 ! I wrote a compiler for the TI-59, it uses a high level language and compiles everything in TI opcodes. You can find it here: https://gtello.pagesperso-orange.fr/ti58_e.htm Guillaume.
  2. Hi Matthew, You told me that very few people were interested in it. So you can make it simplier. Imagine a 2-bytes counter that is incremented every 1/64 sec. This is enough for the TI I think, and you can go up to 1024 sec (close to 17 minutes). For the programmer, it's very easy to use as it fits into a word and that you can shift right 6 bits to get the seconds with no intensive operations. If the counter can be read and written, the programmer can reset it to zero whenever he needs to, so you don't have to manage a complicated programmable timer with start, stop, reset functions. Guillaume.
  3. That's impressive ! Is it a difficult modification of the console? Have you got some pictures? Guillaume.
  4. I think that most of you know this page, but in case... This is how to add the 32k on the 16 bits bus. http://www.mainbyte.com/ti99/32K16/32k16.html How did you proceed? Guillaume.
  5. Hello, I worked again on the MLC program with assembler. By default, MLC uses >A000 as its Workspace Pointer for registers R0-R15. The program modifies temporary this to use >83E0 as the workspace pointer (the zone used by GPL!). This is much faster now ! I run once the program (to get my "SEVEN" subprogram in memory), and then (on real hardware) FOR I=1 TO 30::CALL LINK("SEVEN",N,A$)::NEXT I With the old assembler version it took 60 seconds, so one calculation* was only 60/30 = 2 seconds. With the new version, it takes 42 seconds, so one calculation* is only 42/30 = 1,4 seconds. Waow! Sure, there is no display, but N (=power) and A$ (=result string) are correctly filled. Guillaume. (*) one calculation means to compute every power of seven until 175 to find the correct answer PROGRAM to paste into CLASSIC99 (if you already have MLC on your disk) : 100 CALL CLEAR 110 DIM IO(3) 120 CALL INIT::PRINT "Loading MLC Compiler..."::CALL LOAD("DSK1.NEWFLO")::CALL LINK("NEWFLO") 130 IO(1)=3000::CALL LINK("COMPIL",IO(),S$(),C$())::If IO(1) THEN PRINT "Error ";IO(1)::END 140 PRINT "Compilation OK!" 300 CALL LINK("SEVEN",N,A$) 310 PRINT "7 TO THE POWER OF ";N; " IS" 320 PRINT A$ 330 END 3000 DATA P 3010 DATA SEVEN 3020 DATA "TRF256 TRG256 TRH22 _A BA T< TH10.00070401080502090603 TH10.00000102020304040506 TE LA T>E =P1 TPF0.7 TM-31776.22H TT736" 3030 DATA "TT-31776 TT518 TT1 TT1224 TT522 TT2560 TT514 TT1792 TT-16288 TT-24536 TT1223 TT1221 TT-15802 TT-16352 TT-24534 TT1219 TT-12080" 3040 DATA "TT1731 TT-24383 TT-12013 TT-20219 TT-11933 TT10 TT-28028 TT4355 TT28938 TT549 TT256 TT-9212 TT-28414 TT5638 TT1415 TT647 TT6" 3050 DATA "TT5635 TT1416 TT4097 TT1223 TT1545 TT5863 TT645 TT0 TT4866 TT1414 TT-11259 TT1440 TT-24514 TT648 TT0 TT5080 TT-14330 TT-24494" 3060 DATA "TT-16352 TT-24534 TT-16288 TT-24532 TT514 TT12288 TT-24506 TT-12048 TT-20286 TT1537 TT-11197 TT1542 TT5882 TT736 TT-24576" 3070 DATA "TMH22-31776 =U2 TPU0G P1P" 3080 DATA "" 3090 DATA "" Source program: ; this program searches for the first power of 7 ; that contains six consecutive "7" 100 CALL CLEAR $MLC F 110 10 3000 300 CALL LINK("SEVEN",N,A$) 310 PRINT "7 TO THE POWER OF ";N; " IS" 320 PRINT A$ 330 END $EQU \gplreg PADE0 ; >83E0 \mlcreg &HA000 $$ $SEVEN DIMTABLE F 256 ; F points to a 256 bytes buffer DIMTABLE G 256 ; G points to 256 bytes (for returning string) DIMTABLE H 22 ; to save GPL registers R0-R10 (11*2) STARTDATA BYTES 0,7,4,1,8,5,2,9,6,3 BYTES 0,0,1,2,2,3,4,4,5,6 ENDDATA E ; E points to this multiplication table LET P 1 ; current power = 1 PUTTABLE F(0) 7 ; current value is 7 at first byte ; R0 = pointer on F table ; R1 = pointer to E table ; R2 = 7 ; R3 = one digit and pointer into E ; R4 = one digit after multiplication ; R5 = carry ; R6 = number of digits-1 into F table ; R7 = number of consecutive "7" currently found ; R8 = flag for FOUND ; R9 = loop counter on digits while mul*7 ; R10 = 10 BMOVE \gplreg 22 H ; save GPL registers R0-R10 into H $[ LWPI \glpreg ; use fast registers ! LI R6,1 ; current LEN in digits in F table CLR R8 ; flag for "found" LI R10,>A00 ; R10 = byte 10 LI R2,>700 ; R2 = byte 7 MOV @E,R1 ; mutliplication table E MAIN_LOOP: CLR R7 CLR R5 MOV R6,R9 MOV @F,R0 MULTIPLY_LOOP: CLR R3 ; for byte operation MOVB *R0,R3 ; new digit SWPB R3 ; to word A R1,R3 ; E+digit -> points to the units of table*7 MOVB *R3,R4 ; get units AB R5,R4 ; plus carry MOVB @10(R3),R5 ; E+digit+10 -> points to tenths of table*7, new carry CB R4,R10 ; more than a digit? JLT AA: SB R10,R4 ; if so, reports ten... AI R5,>100 ; ...on the carry (byte) AA: MOVB R4,*R0+ ; store new digit CB R2,R4 ; is it a "7" ? JNE BB: INC R7 ; if so, one more found CI R7,6 ; six "7" ? JNE CC: INC R8 ; yes!!! end of search ! JMP CC: BB: CLR R7 ; not a "7"... reset counter CC: DEC R9 ; loop counter JNE MULTIPLY_LOoP: ; no, return to DEBUT CI R5,0 ; a carry remains? JEQ DD: INC R6 ; yes! One more digit MOVB R5,*R0 ; and store it DD: INC @P ; power+1 CI R8,0 ; flag for found JEQ MAIN_LOOP: ; still zero... back to MAIN MOV R6,@Z ; else, update number of digits MOV @F,R0 ; source F ascending MOV @G,R1 ; dest G descending LI R2,&H3000 ; "0" in high byte A R6,R1 ; R1 points to the end of STRING G EE: MOVB *R0+,R3 ; one digit from F AB R2,R3 ; to ASCII DEC R1 MOVB R3,*R1 ; character in G string DEC R6 JNE EE: lwpi \mlcreg ; back to my registers $] BMOVE H 22 \gplreg ; restore GPL values LET U 2 PUTTABLE U 0 G ; set A$ to G string with Z characters PUTPARAM 1 P ; set N to the current power $$ $END seven_mlc.zip
  6. Hi, cool version! I like your "SEVENS?" procedure with the AND. Compared to the assembler, sure that this FORTH version is time consuming, for example in the use of ]A1 and ]A2, for every access to the table, the index is added to the base address. If there was something like a pointer to parse the table sequentially, it would be faster. Another idea, is it possible to write two procedures, the one to compute A1*7 into A2 and the second te compute A2*7 into A1. Then you won't have to CMOVE the table at each iteration. Guillaume.
  7. Argh SORRY ! I didn't read the /2 in TI-99/2... I though you were talking about the /4A... Still, this project is interesting ! Guillaume.
  8. Hi, What about the DSK emulation? How does it work. And the Joysticks? And the Speech? En eventually the F18A..?? 😉😉 Guillaume.
  9. Hi Matthew, Do you remember that in an earlier version of your firmware, the F18A included a programmable timer? My compiler MLC still supports this even if this feature disappeared. Do you plan to put it back into the MK2 or should I remove everything from MLC ? Guillaume.
  10. Thanks a lot, I like this solution for my flag. Gonna modify the source... Guillaume.
  11. I tested it, now it works ! (what a reactivity!) Thanks a lot, Guillaume.
  12. Yes, that's what I try to do most of the time. But in my current program, a flag was turned to zero (eventually) inside a loop. And I had to test it after the loop was finished. Guillaume.
  13. Hi! This is very interesting. Those instructions, such as CSZ and friends, look very powerfull and certainly not used as they should be. I like your example with the "multiple of 8", that's clever ! When I am working with MLC, I do not touch to the 256 fast ram block as most of it is reserved for XB use. Guillaume.
  14. Hi Tursi, The file is opened with FLAGS sequential, internal, fixed, input and lenght of 240 bytes. This is correct : the program reads five records of 240 bytes each and then restore the postition to the beginning of the file. And so on. It runs well on a CF7+ (I do not have a real floppy unit). Guillaume.
  15. Thanks a lot Matthew ! I didn't think of looking at the LOG in the debugger...! Well, we'are approaching the solution. Guillaume.
×
×
  • Create New...