claculator wrote:
I would like to create something like ez80 studio, but I am not sure how to use appvars, and there is not much documentation on how to use them online. If I could do it using a BASIC library that would be even better, but C would be fine. Can anyone help me?

same i would also like to learn c
I know a decent amount of C, but not enough to use appvars. Have you looked at my Csym project?
claculator wrote:
I know a decent amount of C, but not enough to use appvars. Have you looked at my Csym project?

nope what does it do
also i dont see in on your profile
It's not finished, but here is the forum post: https://www.cemetech.net/forum/viewtopic.php?t=20761
claculator wrote:
Finally, what would the "ez" in Radishez stand for?

It's a play on words. Basically, it's the plural but cooler. 🙂

claculator wrote:
I know a decent amount of C, but not enough to use appvars. Have you looked at my Csym project?

Well, utilizing Appvars is possible with Celtic CE, but it'd 100% break compatability with the old monochrome models. Not that you'd care though, they're at least 20 years old now tbh.
Here's the 1.1 release. The language itself has not changed, but the interpreter has been revamped a lot and line spacing has been fixed.

Code:

0->E
" "->Str4
" "->Str3
If length(Str1)=0
Then
   Disp "NO PROGRAM FOUND IN STR1"
   Pause
   ClrHome
End
length(Str1)->L
0->A
0->I
0->C
1->P
1->L
Lbl MA
C+1->C
If C>L and E=1
Goto ER
If C>L
Stop
sub(Str1,C,1)->Str2
If Str2=" "
Goto MA
If Str2="R"
Goto R
If Str2="A"
Goto A
If Str2="D"
Goto D
If Str2="I"
Goto I
If Str2="S"
Goto S
If Str2="H"
Then
   Goto H
Else
   1->E
   ClrHome
   Str3+toString(C)+" "->Str3
   Str4+Str2->Str4
   Disp "ERROR:INVALID CHARACTER","FOUND AT LINE"
   Output(2,15,C)
   Disp "THE CHARACTER"
   Output(3,15,Str2
   Disp "IS INVALID"
   Pause
End
Lbl R
0->I
Goto MA
Return
Lbl A
A+1->A
Goto MA
Return
Lbl D
I-1->I
Goto MA
Return
Lbl I
I+1->I
Goto MA
Return
Lbl S
I*A->I
0->A
Goto MA
Return
Lbl H
If I=0
L+1->L
If I=~10
Output(L,P,0
If I<0 and I>~10
Output(L,P,~I
If I>0 and I<31
Output(L,P,sub("ABCDEFGHIJKLMNOPQRSTUVWXYZ.,?Ï€",I,1)
Goto MA
Return
Lbl ER
ClrHome
Disp "REVIEW OF ERRORS."
Disp "THERE ARE"
Output(2,11,(length(Str4)-1)
Disp "ERRORS AT THESE LINES"
Disp Str3
Update: The 1.1 version has been accepted into the archives, and I am thinking of adding an input command in the 1.2 version. Anyone have ideas on what to call it? Maybe radish++?
Jeff calc 84 wrote:
claculator wrote:
Finally, what would the "ez" in Radishez stand for?

It's a play on words. Basically, it's the plural but cooler. 🙂

claculator wrote:
I know a decent amount of C, but not enough to use appvars. Have you looked at my Csym project?

Well, utilizing Appvars is possible with Celtic CE, but it'd 100% break compatability with the old monochrome models. Not that you'd care though, they're at least 20 years old now tbh.

How dare you. Many people are still maining the b/w models that are plenty powerfull and there are ways to have the same asm program run on the b/w models and the ce models (which I am working on right now).
I'm planning on keeping the normal RADISH interpreter mostly compatible with the B/W 83+/84+, and possibly creating a C rewrite for the CE.
A program that translates RADISH into ez80 ASM? I would not recommend doing it yet, since radish is not complete yet. It would be better once I write I/O and comparison functions. I am also possibly planning on adding a manupulatible memory stack. That would be a very cool thing, and I do not care if you do it 🙂
ok thx sorry for deletign the post

Should I add the radish language (0f course giving credit to you) to the esolang wiki?

Edit by Merth: Consolidated double post
I have one suggestion that for the characters immediately after 27 just make it asci 0x20-0x2F then 0x3A to 0x40 to make a c implementation a tiny bit nicer, easier, and faster.

0x20 to 0x2F
space ! quote # $ % & apostrophe ( ) * + , - .

0x3A to 0x40
: ; < = > ? @
Over the day, I have thought up a design for an extended radish version. Here are the commands I thought up:

Code:

UPDATES:
The counter will now be called the accumulator
There is now a 1 bit memory (called the flag)
Numbers 1-9 are labels. Labels can be jumped to using z, n, and j.
RCS (radish character set) update: the 30th character will not be π anymore, it will now be :
r: Reset mem
a: increment accumulator
d: decrement mem
i: increment mem
s: multiply accumulator by mem, store into mem, and reset the accumulator.
h: print RCS (radish character set) character stored in memory
c: copy memory into the accumulator
z: jumps to the program label stored in the accumulator if the flag = 0
n: jumps to the program label stored in the accumulator if the flag = 1
j: unconditional jump, jumps to program label stored in accumulator
f: if flag > memory, increment memory
/: swap memory and accumulator
<: Compares accumulator and memory, sets flag to 1 if A less than or equal to memory, sets flag to 0 if not.
>: Compares accumulator and memory, sets flag to 1 if A greater than or equal to memory, sets flag to 0 if not.
0: reset accumulator

I will get around to writing a interpreter in TI-Basic sometime
I am confused on the line jumping. (Assuming it starts from 1) would in this code where the accumulator is 3 jump to (1) or (2)? In other words would \n characters matter or not?

Code:

rd(1)h
rih
(2)riih
I edited my post. Now, jumps go to a label. Labels are defined using 1-9. For clarification, radish is supposed to purely use single line commands. No for(a,b), no disp(n). All commands are only one character. Jumping to an invalid line will just return an error. Here is an example of an infinite loop that prints the "A" character.
Code:

ia 1 hj

This has made me think, is radish actually practical? You can do complex stuff (infinite loop with prints) in only 5 characters? That would look like the following in TI-BASIC

Code:
While 1
Disp "A"
End

As for your code, it would not work, and makes no sense to me. What is rd(1)h supposed to do?
I have created a python interpreter for the latest version of radish.
Here's the code:

Code:

#predefining things
rcs = " ABCDEFGHIJKLMNOPQRSTUVWXYZ.,?:"
cursor = 0
memory = 0
accumulator = 0
flag = False
#starting up
print("RADISH interpreter V1.1")
p = input("Program:")
labels = {}
for i, ch in enumerate(p):
    if ch.isdigit() and ch != "0":
        labels[int(ch)] = i
while cursor < len(p): #checks if cursor position is further than the program
    sub = p[cursor] #stores part of program to be evaluated
    if sub.isdigit() and sub != "0":
        cursor += 1
        continue
    if sub == "z":
        if not flag:
            cursor = labels.get(accumulator, cursor)
            continue
    if sub == "n":
        if flag:
            cursor = label.get(accumulator, cursor)
    if sub == "j":
        cursor = label.get(accumulator, cursor)
    if sub == "r":
        memory = 0
    if sub == "a":
        accumulator += 1
    if sub == "d":
        memory -= 1
    if sub == "i":
        memory += 1
    if sub == "s":
        memory *= accumulator
        accumulator = 0
    if sub == "c":
        accumulator = memory
    if sub == "f":
        if flag >= memory:
            memory += 1
    if sub == "/":
        previous = memory #temporary variable
        memory = accumulator
        accumulator = previous
        del previous
    if sub == "<":
        if accumulator <= memory:
            flag = True
        else:
            flag = False
    if sub == ">":
        if accumulator >= memory:
            flag = True
        else:
            flag = False
    if sub == "0":
        accumulator = 0
    if sub == "h":
        print(rcs[memory % len(rcs)], end="")
    cursor += 1
claculator wrote:
I edited my post. Now, jumps go to a label. Labels are defined using 1-9. For clarification, radish is supposed to purely use single line commands. No for(a,b), no disp(n). All commands are only one character. Jumping to an invalid line will just return an error. Here is an example of an infinite loop that prints the "A" character.
Code:

ia 1 hj

This has made me think, is radish actually practical? You can do complex stuff (infinite loop with prints) in only 5 characters? That would look like the following in TI-BASIC

Code:
While 1
Disp "A"
End

As for your code, it would not work, and makes no sense to me. What is rd(1)h supposed to do?

(1) and (2) would not be in the actual code , they were my 2 options on asking where the jump would go. Also your code dosent show a label definition or are labels just every line in the code instead of being defined?
I tried making a program that prints "HELLO"

Code:

iiiiaashriiiiihiiiaaaashhriiiiiaaashr

It returns HEAAO in the python interpreter. Can anyone help me?
ti_kid wrote:

How dare you. Many people are still maining the b/w models that are plenty powerfull and there are ways to have the same asm program run on the b/w models and the ce models (which I am working on right now).


no, uh, I actually program for the ti84+. I thought that it's nearly dead now...
  
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