Calculator Community > Casio Calculators |
Getting started in Casio-Basic? You can ask here. |
(1/25) > >> |
fxdev:
This is a thread where you can put your Casio-Basic related questions. Me and the other Casio guys will try to answer these. |
DJ Omnimaga:
-One question I have is can we omit quotes at the end of Locate? In TI-BASIC you can do things such as Output(1,1,"HELLO WORLD instead of Output(1,1,"HELLO WORLD") as long as the next code is on a different line, but I was wondering if it was the same on Casio? That usually saved us some bytes of RAM. -Also are there any assembly tools that allow us to run programs directly from the Storage memory or even just a program that works in a parser hook way and allows you to move/copy back and forth programs from the RAM to storage? That isn't really BASIC-related, although some 83+ BASIC games uses such programs to get around the 24 kilobytes of RAM limit. -Also how would we recall a picture from a program on the Prizm? I tried RecallPict 1 (after storing a pic with StorePict 1) and it does nothing... ??? On an unrelated note, somebody started writing a guide to help people porting TI-BASIC programs to Casio BASIC or vice-versa a while ago. I can't find the topic right now but I'll try to find it later. |
fxdev:
--- Quote ----One question I have is can we omit quotes at the end of Locate? In TI-BASIC you can do things such as Output(1,1,"HELLO WORLD instead of Output(1,1,"HELLO WORLD") as long as the next code is on a different line, but I was wondering if it was the same on Casio? That usually saved us some bytes of RAM. --- End quote --- "Locate" and "Text" seem to allow this, but it's bad practice and does not seem to work with the ":" command either. Actually, I have never used this. The few bytes you save get lost by using special characters. --- Quote ----Also are there any assembly tools that allow us to run programs directly from the Storage memory --- End quote --- Maybe this is what you are looking for? http://casiokingdom.org/modules.php?name=Downloads&d_op=viewdownloaddetails&cid=16&lid=542&ttitle=FX9860G_LOADER_2.00#dldetails --- Quote ----Also how would we recall a picture from a program on the Prizm? I tried RecallPict 1 (after storing a pic with StorePict 1) and it does nothing... ??? --- End quote --- You could try clearing the screen first using "cls" and you should disable any background image with "BG-None". Unfortunately, there is no way to test if a picture exists - causing a memory error sometimes. |
DJ Omnimaga:
--- Quote from: cfxm on January 18, 2011, 03:39:11 pm --- --- Quote ----One question I have is can we omit quotes at the end of Locate? In TI-BASIC you can do things such as Output(1,1,"HELLO WORLD instead of Output(1,1,"HELLO WORLD") as long as the next code is on a different line, but I was wondering if it was the same on Casio? That usually saved us some bytes of RAM. --- End quote --- "Locate" and "Text" seem to allow this, but it's bad practice and does not seem to work with the ":" command either. Actually, I have never used this. The few bytes you save get lost by using special characters. --- End quote --- Ah ok, I guess it is different between both brand of calcs. On TI, we try to save every possible byte by using such optimization. It is even considered a good practice among us. The only time it should be avoided is with For() when it only contains an IF instruction that is often False, due to a TI-OS glitch. Does special characters actually take more space than the regular ones? I remember something similar on TI with lowercase letters. --- Quote from: cfxm on January 18, 2011, 03:39:11 pm --- --- Quote ----Also are there any assembly tools that allow us to run programs directly from the Storage memory --- End quote --- Maybe this is what you are looking for? http://casiokingdom.org/modules.php?name=Downloads&d_op=viewdownloaddetails&cid=16&lid=542&ttitle=FX9860G_LOADER_2.00#dldetails --- End quote --- Does this allow copying individual programs to the RAM? Being forced to copy entire packages might not be something I want, especially when each program is 15 KB large. --- Quote from: cfxm on January 18, 2011, 03:39:11 pm --- --- Quote ----Also how would we recall a picture from a program on the Prizm? I tried RecallPict 1 (after storing a pic with StorePict 1) and it does nothing... ??? --- End quote --- You could try clearing the screen first using "cls" and you should disable any background image with "BG-None". Unfortunately, there is no way to test if a picture exists - causing a memory error sometimes. --- End quote --- Nope, no luck. Here's my code (Casio Prizm OS 01.01.0200): --- Code: ---Cls Vertical -3 StoPict 1 Cls BG-None RclPict 1 --- End code --- Basically I wanted to clear the screen, display a line at -3, Store the screen content in picture 1, clear the screen again, then re-display the picture 1 content again. Not an useful program, but it was for testing purpose since I'm experimenting with the language. |
fxdev:
--- Quote ---Does special characters actually take more space than the regular ones? --- End quote --- As long as they're non-ASCII. --- Quote ---Does this allow copying individual programs to the RAM? Being forced to copy entire packages might not be something I want, especially when each program is 15 KB large. --- End quote --- As far as I know, this copies any program within a *.g1m/*.g2m file into the user RAM. You may ask Simon to obtain the source code. --- Quote ---Nope, no luck. Here's my code (Casio Prizm OS 01.01.0200): --- Code: ---Cls Vertical -3 StoPict 1 Cls BG-None RclPict 1 --- End code --- --- End quote --- And if you go to RUN|MAT and enter "Cls:RclPict 1"? This will display the coordinate system with an additional vertical line on my fx-9750GII. Inside RUN|MAT you can press [Shift]+[F3] and reset the view window with [F1] - just in case the vertical line is not within the display area... |
Navigation |
Message Index |
Next page |