Tursi Posted January 23, 2018 Share Posted January 23, 2018 I'd argue there actually are tricks with VDP addressing, but that they are very rarely useful. However, I have used setting a write address and then reading to save code space in the past. You just have to remember that all VDP data passes through an intermediate register. Setting >4000 in an address means "don't prefetch this address" and nothing more. In very rare instances that's been useful for me to save space, for instance, when it was smaller to read a dummy byte to get to the right address and force a prefetch than to OR in >4000. Also remember that writes do not cause a prefetch, so the first read after a write is essentially garbage data, but still increments the address. For the VDP data move, your loop has a requirement that length must be a multiple of 8. If you change your JNE to JGT you can get around that (as long as you don't mind it will still COPY a multiple of 8, but it won't crash otherwise). 1 Quote Link to comment Share on other sites More sharing options...
Count9929A Posted January 25, 2018 Share Posted January 25, 2018 I am just starting t learn ASM TI programming, and even though I could use E/A even on a real TI, thanks to the nano-PEB, the mini memory fascinate me more! I hope to be able to participate to future editions of this wonderful contest! 2 Quote Link to comment Share on other sites More sharing options...
+mizapf Posted January 25, 2018 Share Posted January 25, 2018 I am just starting t learn ASM TI programming, and even though I could use E/A even on a real TI, thanks to the nano-PEB, the mini memory fascinate me more! You may consider talking to someone about your dark desires ... (just kidding!) Quote Link to comment Share on other sites More sharing options...
+Vorticon Posted January 25, 2018 Share Posted January 25, 2018 I am just starting t learn ASM TI programming, and even though I could use E/A even on a real TI, thanks to the nano-PEB, the mini memory fascinate me more! I hope to be able to participate to future editions of this wonderful contest! Ah, a fellow masochist Welcome! Quote Link to comment Share on other sites More sharing options...
+Vorticon Posted January 28, 2018 Share Posted January 28, 2018 I am sad to announce that after much effort I could not fit my program within the 780 bytes limit of the LBLA , at least to get what I wanted from it. So it's time to regroup: either I forge on using the EA and the full 4K available to me (that seems like such a luxury!!!) or come up with a simpler idea. All the game elements are in place, and I probably just needed an additional 2-3 hundred bytes to finish it. Bummer... 1 Quote Link to comment Share on other sites More sharing options...
Tursi Posted January 29, 2018 Share Posted January 29, 2018 A couple hundred bytes starts to feel like a luxury very quickly, yes. I've got my title done with lots of time to fiddle with it till the release thread opens up - even have 26 bytes free . Unfortunately, I wanted it to work with the MiniMemory, and the MM's "load and run" option needs your program to start at >7118, meaning you only get 4k - 280 bytes if you want to use that option. What's it take to make a Playground assembly loader? 1 Quote Link to comment Share on other sites More sharing options...
Asmusr Posted January 29, 2018 Author Share Posted January 29, 2018 What's it take to make a Playground assembly loader? Or perhaps you could load a loader as an object file? Quote Link to comment Share on other sites More sharing options...
Tursi Posted January 29, 2018 Share Posted January 29, 2018 Or perhaps you could load a loader as an object file? Hehe, that would work! It'd be nice to avoid a double-load though... Maybe a self-extracting archive though... that would work. Quote Link to comment Share on other sites More sharing options...
senior_falcon Posted January 30, 2018 Share Posted January 30, 2018 What's it take to make a Playground assembly loader? Here's a question about the rules: Lets say you have an assembly program that is exactly 4K long and embed that in a TI BASIC loader. Now the loader program is going to take some number of bytes; as an educated guess let's say 200 more bytes. With 4K of embedded code the length of the TI BASIC program is 4.2K long but it puts only 4K program into the minimemory. Is this acceptable under the rules? Quote Link to comment Share on other sites More sharing options...
Tursi Posted January 30, 2018 Share Posted January 30, 2018 Here's a question about the rules: Lets say you have an assembly program that is exactly 4K long and embed that in a TI BASIC loader. Now the loader program is going to take some number of bytes; as an educated guess let's say 200 more bytes. With 4K of embedded code the length of the TI BASIC program is 4.2K long but it puts only 4K program into the minimemory. Is this acceptable under the rules? Yep, that's exactly right. I was suspecting that it might be possible to store the full copy loop in the exploit code (ie: no paging), but after spending a little time reading the documentation I was still not quite clear how to create the BASIC program. I guess there'd be one more caveat that I hadn't thought about -- since the exploit messes up scratchpad, we'd need to restore a default scratchpad (E/A environment would suffice) to ensure that the ISR keeps working correctly (unless, of course, the ISR isn't affected by the exploit code). But that could just be another 256 bytes copied from VDP at worst. I don't mean to set you off to work on it! It was just a thought I had. Quote Link to comment Share on other sites More sharing options...
senior_falcon Posted January 30, 2018 Share Posted January 30, 2018 It's an easy enough thing to copy 4K of code from the minimemory (>7000 to >7FFF) and embed it into a TI BASIC program. After loading the TI BASIC program the embedded code can be copied back into the minimemory. But the resulting BASIC program will be more than 4K long. If the rules permit this I could put together a loader. If it is not permitted then that's OK too. Don't worry about the ISR. A few things are modified but they are easy to undo. 1 Quote Link to comment Share on other sites More sharing options...
Asmusr Posted January 30, 2018 Author Share Posted January 30, 2018 It's an easy enough thing to copy 4K of code from the minimemory (>7000 to >7FFF) and embed it into a TI BASIC program. After loading the TI BASIC program the embedded code can be copied back into the minimemory. But the resulting BASIC program will be more than 4K long. If the rules permit this I could put together a loader. If it is not permitted then that's OK too. Don't worry about the ISR. A few things are modified but they are easy to undo. I have no problems with allowing that, and I would even use it myself. My game is slightly bigger than what you can load into the Minimem as an object file. 2 Quote Link to comment Share on other sites More sharing options...
Opry99er Posted January 30, 2018 Share Posted January 30, 2018 I just don't even know what to say anymore. This level of 'cool' is beyond calculation. 2 Quote Link to comment Share on other sites More sharing options...
+Vorticon Posted January 30, 2018 Share Posted January 30, 2018 A couple hundred bytes starts to feel like a luxury very quickly, yes. I've got my title done with lots of time to fiddle with it till the release thread opens up - even have 26 bytes free . Unfortunately, I wanted it to work with the MiniMemory, and the MM's "load and run" option needs your program to start at >7118, meaning you only get 4k - 280 bytes if you want to use that option. What's it take to make a Playground assembly loader? I think I'm just going to expand my game using the EA, and it will likely fit in the MM with room to spare although I will have to ward off feature creep . I want the game to load from tape into the MM without any other support. Currently standing at 874 bytes 1 Quote Link to comment Share on other sites More sharing options...
senior_falcon Posted January 30, 2018 Share Posted January 30, 2018 I think I'm just going to expand my game using the EA, and it will likely fit in the MM with room to spare although I will have to ward off feature creep . I want the game to load from tape into the MM without any other support. This makes a TI BASIC program with embedded code. As with any BASIC program, it can be loaded via disk or cassette. Quote Link to comment Share on other sites More sharing options...
+Vorticon Posted January 30, 2018 Share Posted January 30, 2018 This makes a TI BASIC program with embedded code. As with any BASIC program, it can be loaded via disk or cassette. Neat trick Quote Link to comment Share on other sites More sharing options...
Tursi Posted January 30, 2018 Share Posted January 30, 2018 It's an easy enough thing to copy 4K of code from the minimemory (>7000 to >7FFF) and embed it into a TI BASIC program. After loading the TI BASIC program the embedded code can be copied back into the minimemory. But the resulting BASIC program will be more than 4K long. If the rules permit this I could put together a loader. If it is not permitted then that's OK too. Don't worry about the ISR. A few things are modified but they are easy to undo. oooh, yeah, I wasn't even considering it as my main entry, but just as a distribution method so cassette MiniMem users could load it easily. But that would be awesome! (I was going to provide Cart, EA#5, and MiniMem versions -- the latter cause I got hung up on that requirement from the first post and liked that idea. ) 1 Quote Link to comment Share on other sites More sharing options...
Opry99er Posted January 30, 2018 Share Posted January 30, 2018 ^^cassette minimem users^^... the purest form of TI99er alive. Too cool. 1 Quote Link to comment Share on other sites More sharing options...
Tursi Posted February 2, 2018 Share Posted February 2, 2018 (edited) This help anyone? unlz4.zip Edited February 2, 2018 by Tursi 3 Quote Link to comment Share on other sites More sharing options...
sometimes99er Posted February 2, 2018 Share Posted February 2, 2018 (edited) This help anyone? unlz4.zip Excellent. Of course I'll have to try it out (IRL), - but are there any recommended, small, quick and dirty Windows or Java LZ4 programs to use when compressing ? - Just to quickly see how well my present 4K ROM binaries will compress. Edited February 2, 2018 by sometimes99er Quote Link to comment Share on other sites More sharing options...
Asmusr Posted February 2, 2018 Author Share Posted February 2, 2018 Excellent. Of course I'll have to try it out (IRL), - but are there any recommended, small, quick and dirty Windows or Java LZ4 programs to use when compressing ? - Just to quickly see how well my present 4K ROM binaries will compress. Here are some binaries: https://github.com/lz4/lz4/releases/tag/v1.8.1.2 1 Quote Link to comment Share on other sites More sharing options...
Asmusr Posted February 2, 2018 Author Share Posted February 2, 2018 This help anyone? unlz4.zip Whoa, this can compress my game from 4K to around 3.5K. Since my game is almost done I'm not sure I'm going to use it now, but it will be very handy for future projects. Quote Link to comment Share on other sites More sharing options...
Tursi Posted February 2, 2018 Share Posted February 2, 2018 Excellent. Of course I'll have to try it out (IRL), - but are there any recommended, small, quick and dirty Windows or Java LZ4 programs to use when compressing ? - Just to quickly see how well my present 4K ROM binaries will compress. I put links to all the information and homepage in the readme... I just used the default (Windows) tool from the main page. They've got a number of ready-to-go ports. 1 Quote Link to comment Share on other sites More sharing options...
senior_falcon Posted February 3, 2018 Share Posted February 3, 2018 I have come up with a TI BASIC loader that can load up to a full 4096 bytes into the MiniMemory cartridge. It copies the program from >7000 and embeds it in a TI BASIC program. When you load and run the program it copies the program back into the cartridge ram at >7000 and then does a B @>7000, pretty much the way an EA5 program runs. I tried to duplicate the environment you get when running an EA5 program, but there is not enough room to do it all. Right now it copies the character definitions from V0400 to V0900 and sets two vdp registers so that they match the EA values when an EA5 program starts. There is no room to change the color table at V0380 to the EA5 values. The screen is not cleared, although a CALL HCHAR(1,1,192,768) in the loader program will do that. Is that close enough to be useful? Is clearing the screen and setting the color table more useful than having the characters defined? Once there is a consensus I will post the loader. 2 Quote Link to comment Share on other sites More sharing options...
Tursi Posted February 3, 2018 Share Posted February 3, 2018 Character definitions are the most useful to me, anyway. I clear the screen and set the VDP regs myself. So that would work here! 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.