π
<-

## ICE Compiler

Langages Assembleur, Axe, BBC Basic...

### Re: ICE Compiler

Cool update !
It will be more fun !
Mes projets :

-TILIB
-AGAME :
feature en cours :
gestion des maps (lecture / création)
Avancement estimé :
13%

sautaxProg.

Niveau 10: GR (Guide de Référence)
Prochain niv.: 99.4%

Messages: 44
Inscription: 21 Sep 2016, 15:31
Localisation: Quelque part dans le sud
Genre:
Calculatrice(s):
Classe: seconde

### Re: ICE Compiler

In Case of Emergency (ICE..), you can join #icedev for (almost) instant help
Join this channel as well for discussion about ICE, features, updates etc
Age of CEmpires I:
20%

PT_Prog.

Niveau 12: CP (Calculatrice sur Pattes)
Prochain niv.: 92.2%

Messages: 185
Inscription: 10 Fév 2016, 00:06
Genre:
Calculatrice(s):

### Re: ICE Compiler

We are more than happy to announce that the online TI-BASIC editor and IDE SourceCoder 3 gets an upgrade again. You have now the possibility to compile ICE programs online, rather than doing it on-calc! The syntax is basically the same as TI-BASIC, but you don't need a "Then" for indentation. While the highlighting is exactly the same, except the commands of course, we are still working on a nice styling system for ICE, to make it even easier to write programs! But, you say, why can't we use the TI-BASIC section of SourceCoder 3? That is very simple: ICE has a lot of graphic commands, imported from the C libraries, and replaced them with det(XX..). From now on, you don't need to remember this anymore, you can just directly type "FillScreen(255)" for example!

In the sidebar you can see some groups, which are the same groups as listed in commands file of ICE Compiler, to make it even easier! Also, you can easily add comments as well, in order to explain variables or routines to yourself. You can do this by placing "//" in front of the line, the same as in with BASIC.

As far as we know, there is only 1 thing to mention:
• There is a graphic command "End", but BASIC itself also has an "End". Therefore, I removed the graphic command "End", so typing in "End", gives you the token End, not det(1).

Launch Tool:

SourceCoder 3 Online TI-BASIC, ASM, and C Editor and IDE

Many thanks to KermMartian for helping me in this process, correcting me when needed, and moving it to the real website!

Source:
https://www.cemetech.net/forum/viewtopic.php?t=13679
Age of CEmpires I:
20%

PT_Prog.

Niveau 12: CP (Calculatrice sur Pattes)
Prochain niv.: 92.2%

Messages: 185
Inscription: 10 Fév 2016, 00:06
Genre:
Calculatrice(s):

### Re: ICE Compiler

So well, yeah, time for some updates, or whatever you call it. As you might already know, I'm recreating ICE in C to make development faster, and easy add new features. This is coming along very well, I need to say. Currently numbers, variables, operators and parenthesis are supported (still need code for every operator), and more are coming soon. However, I'm running into a huge problem, and that are C functions. They are not like 'normal functions', such as not( and remainder( and so on. For the last type of tokens, I just add code for every possible argument type(s), rather than using the stack, like C functions need. However, this method simply doesn't apply to C functions, as they are supposed to take the input (arguments) from the stack, not registers etc. Thus, with the Shunting Yard Algorithm I'm doing, it is VERY hard to add C functions, and I'm not sure yet how to solve this. Let's take a look at some example:
Code: Tout sélectionner
det(2,det(15,X+2->X                 2 15 X 2 + det( det( X ->det(2,det(15,X)+2->X                2 15 X det( 2 + det( X ->det(2,det(15),X+2->X                2 15 det( X 2 + det( X ->det(2,X+det(15),2->X                2 X 15 det( + 2 det( X ->det(2,X,2*det(15))+3->X             2 X 2 15 det( * det( 3 + X ->2*det(15,X)+3->X                    2 15 X det( * 3 + X ->det(2,X+2,1,2,3                     2 X 2 + 1 2 3 det(

Left is the input, right is the input in infix notation.

Now let's take my last example. If I just parse them as normal, first the "+" is parsed, so X+2, but since the output isn't used in the next 2 elements (as an operator or function), the output is pushed to the stack, and that is where problems arise,
it should not even parse the +
. First 3, then 2, then 1 should be pushed, afterwards X+2 parsed and pushed, then the det( function will be called.

Again, I've no idea how to solve this, and I'm open for any ideas!

Progress: I've added icon and description support:
Age of CEmpires I:
20%

PT_Prog.

Niveau 12: CP (Calculatrice sur Pattes)
Prochain niv.: 92.2%

Messages: 185
Inscription: 10 Fév 2016, 00:06
Genre:
Calculatrice(s):

### Re: ICE Compiler

PT_ a écrit:Left is the input, right is the input in infix notation.

You meant "postfix" notation, I think.

I do not know anything about ICE, but I assume that you use "det(num, args" to call a special function whose number is "num" and "args" are the arguments.
If so, the problem you are exposing will appear each time you call such a function.

You can easily rewrite the beginning of theses functions to reverse the list of the arguments, no ?
You can even write a private reversing list function to do that.

But maybe I didn't understand well the problem...
In fact, it is not clear if your problem is getting from the input to the RPN or from the RPN to the final output ?

Niveau 15: CC (Chevalier des Calculatrices)
Prochain niv.: 39.7%

Messages: 5188
Inscription: 11 Mar 2008, 01:00
Localisation: Lyon
Genre:
Calculatrice(s):
Classe: Prof de Math en Maths Spé PSI

### Re: ICE Compiler

I've added SetBASICVar( which... sets a BASIC variable!

Age of CEmpires I:
20%

PT_Prog.

Niveau 12: CP (Calculatrice sur Pattes)
Prochain niv.: 92.2%

Messages: 185
Inscription: 10 Fév 2016, 00:06
Genre:
Calculatrice(s):

### Re: ICE Compiler

I'm SUUUUUPPEERRRRR excited to announce this very great news:

It redirects you to a page at Cemetech Learn, where I will put all the needed information, and Tips and Tricks!
Age of CEmpires I:
20%

PT_Prog.

Niveau 12: CP (Calculatrice sur Pattes)
Prochain niv.: 92.2%

Messages: 185
Inscription: 10 Fév 2016, 00:06
Genre:
Calculatrice(s):

### Re: ICE Compiler

Time for some quick updates about my C version: I've implemented all the operators, and added code for functions, which work fine, I only need to add them Chaining things also work, so the only thing I need to do is doing weird stuff with C functions and get that working
Age of CEmpires I:
20%

PT_Prog.

Niveau 12: CP (Calculatrice sur Pattes)
Prochain niv.: 92.2%

Messages: 185
Inscription: 10 Fév 2016, 00:06
Genre:
Calculatrice(s):

### Re: ICE Compiler

Cool, well done!
Bonjour
Anonymous
! Une question, une demande, un problème ? Envoie-moi un MP, je réponds rapidement

Envie de
programmer en C
sur ta calculatrice
TI83PCE/84+CE
? Suis le guide en cliquant ici!

>> Groupe Facebook BAC 2017 & ECE
(entraide, partage & astuces)
: cliquez-ici <<

Mon site

WistaroModo.G

Niveau 15: CC (Chevalier des Calculatrices)
Prochain niv.: 12.8%

Messages: 2135
Images: 22
Inscription: 25 Fév 2013, 17:21
Localisation: Toulouse
Genre:
Calculatrice(s):
Classe: Etudiant en électronique (Ex TS - SI)

Précédente

Retourner vers Programmation alternative

### Qui est en ligne

Utilisateurs parcourant ce forum: Aucun utilisateur enregistré et 0 invités

-
Rechercher
-
Sujets à la une
1234
-
Pour plus de concours, de lots, de tests, nous aider à payer le serveur et les domaines...

Découvrez les avantages d'un compte donateur !

-
Sélections fichiers
Partenaires et pub

-
Stats.
375 utilisateurs:
>301 invités
>69 membres
>5 robots
Record simultané (sur 6 mois):
6892 utilisateurs (le 07/06/2017)
-
Autres sites intéressants
Texas Instruments Education
Global | France
(English / Français)
Banque de programmes TI
ticalc.org
(English)
La communauté TI-82
tout82.free.fr
(Français)