Right now the shell only shows 8 programs and it's in VAT-order, but it's usable enough for another release:
https://merthsoft.com/tuga/Tuga.zip

Here's an image after changing some of the colors:


I don't really understand why the text sizing doesn't work the second time the shell is launched.

I also did a bunch of work around handling the program buffer and such, so it's a little more efficient and stable now. The readme also got some love. I'm trying to keep it somewhat updated as things are changing quickly. But making sure that's accurate for a release seems good.

EDIT: Also, I will be updating the header. The icon will use a double quote like the description. This is so that first-line labels function properly.
A frustrating thing I'm running into while working on this is that I could have a bunch of programs that coming before "TUGA" alphabetically. So I'm thinking maybe the interpreter program itself should be called "ATUGA", so it comes relatively early in the list.

Alternatively: Maybe the TUGA shell should be an app? What're the implications of doing that in how I do development? Anyone with app experience able to speak on that?

Edit: Could I make the interpreter launch the app and the app launch the interpreter? I would need a way to preserve the self-launching nature of the program files, because I think that's useful. Maybe even a small proram that invokes the app if need be.

Additional edit: I have the following proposal for function defintions:

Functions are defined with FUNC, a name, and a list of parameters, and end with RET:

Code:
FUNC FUNCTION(A,B,C
    " CODE
RET FUNCTION

And invoked with CALL: CALL FUNCTION(X,Y,Z. The function is re-writte as

Code:
LABEL FUNCTION
    " `SYSPUSH` pushes onto the system stack
    SYSPUSH {A,B,C
    " This is on the selected stack
    PEEK {A,B,C
    " CODE

" Happens for every RET in the function
" `SYSPOP` pops off the system stack
SYSPOP {A,B,C
RET


Code:
PUSH {X,Y,Z
GOSUB FUNCTION
POP {X,Y,Z


Alternatively, all push and pop commands could happen on the system stack or local stack, but I think this split makes sense.
Today I added PEER, which lets you look anywhere on the stack ("peer" into it, like a more advanced peek), with negative relative indexing as well. I will probably add third parameter that lets you pick the stack page as well, so you can override the existing page, making it more useful. It lets you specify how many numbers to read, and puts the results in Ans. I also added the ANSLIST, which puts ANS into the list of your choice.

However, I plan on overhauling STO so that it can handle lists, matrixes, strings, etc. This will change the syntax, so instead of `STO {A,10`, it'll be `STO A,10`, but that's better, in my opinion, anyway. That means then you'll be able to do STO L1,{1,B,3 or STO L2,And. Not sure how indexing will work yet. STO L2(2),5 probably?

Here's a really boring screenshot of me testing PEER, and the code for the test:


Code:
PUSH {100,100,900,900,900,900,900,900,900,900
PEER {0,3
ANSLIST L₁
MOVE L₁
  
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.

» Go to Registration page
Page 2 of 2
» All times are UTC - 5 Hours
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

 

Advertisement