JonnyBritish Posted October 13, 2010 Share Posted October 13, 2010 An introduction to TurboForth on the TI-99/4A, what Forth 'is', and the current status of the project. http://www.youtube.com/view_play_list?p=E79188BBF51038BC Quote Link to comment Share on other sites More sharing options...
+retroclouds Posted October 13, 2010 Share Posted October 13, 2010 Even though I wasn't interested in Forth in the early days, I must say that Willsy is doing some impressive work here. I also start to like how dense Forth code is. It seems you can really reach a lot with only a few lines of code. Looking forward playing with the final product Quote Link to comment Share on other sites More sharing options...
Willsy Posted October 13, 2010 Share Posted October 13, 2010 Hi JohnnyBritish, Thanks very much for the heads up on that! I had meant to post something here on Atariage but I forgot all about it! TurboForth is nearly finished (though I admit I have been saying that for ages!) Here's the final to-do list: Interrupt driven speech Interrupt driven music Interrupt driven path-based sprite movement 80 column (V9938) text mode support After that, I will crack on with the book, which I really want to get finished (first 100 pages are done) and the support web site. Some people have stepped up to the plate in the USA to distribute ROMS/Cartridges. I'll need European volunteers too. It's unlikely I'll be in Europe for the next 3 years or so... Mark Quote Link to comment Share on other sites More sharing options...
Willsy Posted October 13, 2010 Share Posted October 13, 2010 Even though I wasn't interested in Forth in the early days, I must say that Willsy is doing some impressive work here. I also start to like how dense Forth code is. It seems you can really reach a lot with only a few lines of code. Looking forward playing with the final product Yes indeed. Forth words are about as dense as you can get on the 9900. Each *reference* to a forth word takes 2 bytes: DUP SWAP NIP TUCK 1+ 2* 3 / . The following code occupies 18 bytes. If the above was written in assembly as a sequence of BL calls to subroutines, you would need 36 bytes. Forth code is simply references to other Forth words. Moreover, you are encouraged to 'factor' your code so that code is re-used as much as possible. So if you suddenly find that the following phrase is used a lot in your code: NIP DROP SWAP - Then you 'factor out' those phrases, into a single Forth word, and replace the phrases with a call to the word you create, saving 6 bytes each time you do so. Forth (and TurboForth) is also a powerful script language. When TurboForth loads code from blocks, it 'thinks' it is being typed in by the keyboard (really fast) thus you can put script in blocks and TurboForth will actually execute it right then and there, as it loads it, just like it was typed in in immediate mode from the keyboard. This is a powerful technique that can be used to save LOTS of memory. For example, consider user-defined graphics in Assembly language, or XB, or TIB. They are *terribly* in-efficient. Why? Because they exist in two places: 10 CALL CHAR(42,"ABCDEF1234567890") The above character definition exists in two places: It exists in CPU memory as part of the source code, and at run-time, it exists in VDP memory. It occupies exactly twice the memory space that it should. In TurboForth, you can place the above code in a block, and when TurboForth reads that line, it will execute it in immediate mode and copy the definition to VDP memory, taking up no space in at all in CPU ram. Nothing. TurboForth is quite efficient and turning into a nice powerful language. I'm quite proud of it! Mark Quote Link to comment Share on other sites More sharing options...
JonnyBritish Posted October 13, 2010 Author Share Posted October 13, 2010 Even though I wasn't interested in Forth in the early days, I must say that Willsy is doing some impressive work here. I also start to like how dense Forth code is. It seems you can really reach a lot with only a few lines of code. Looking forward playing with the final product Yes indeed. Forth words are about as dense as you can get on the 9900. Each *reference* to a forth word takes 2 bytes: DUP SWAP NIP TUCK 1+ 2* 3 / . The following code occupies 18 bytes. If the above was written in assembly as a sequence of BL calls to subroutines, you would need 36 bytes. Forth code is simply references to other Forth words. Moreover, you are encouraged to 'factor' your code so that code is re-used as much as possible. So if you suddenly find that the following phrase is used a lot in your code: NIP DROP SWAP - Then you 'factor out' those phrases, into a single Forth word, and replace the phrases with a call to the word you create, saving 6 bytes each time you do so. Forth (and TurboForth) is also a powerful script language. When TurboForth loads code from blocks, it 'thinks' it is being typed in by the keyboard (really fast) thus you can put script in blocks and TurboForth will actually execute it right then and there, as it loads it, just like it was typed in in immediate mode from the keyboard. This is a powerful technique that can be used to save LOTS of memory. For example, consider user-defined graphics in Assembly language, or XB, or TIB. They are *terribly* in-efficient. Why? Because they exist in two places: 10 CALL CHAR(42,"ABCDEF1234567890") The above character definition exists in two places: It exists in CPU memory as part of the source code, and at run-time, it exists in VDP memory. It occupies exactly twice the memory space that it should. In TurboForth, you can place the above code in a block, and when TurboForth reads that line, it will execute it in immediate mode and copy the definition to VDP memory, taking up no space in at all in CPU ram. Nothing. TurboForth is quite efficient and turning into a nice powerful language. I'm quite proud of it! Mark Any plans to create an Atari version? Quote Link to comment Share on other sites More sharing options...
Willsy Posted October 14, 2010 Share Posted October 14, 2010 Any plans to create an Atari version? He he! Well, i'd quite like to do an Atari ST version in 68000 assembly. 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.