Forums Casio - Projets de programmation

Index du Forum > Projets de programmation > C.Basic Projets
Sentaro21
Hors ligne
Membre
Points: 154
Défis: 0
Message
Posté le 30/04/2017 11:08

C.Basic Projets :

Hello, everyone.

I am Sentaro21, and I am developing C.Basic, a Basic interpreter that allows high-speed execution of Basic programs while maintaining compatibility with genuine Casio Basic.

Here is an English site, by Krtyski, about the C.Basic project (I helped him with the translation, but it's still unfinished) :
https://egadget2.web.fc2.com/CBasic/Interpreter/CBasic_interpreter.html

The articles and various programs from this site served as a reference to evaluate the compatibility level of C.Basic. Results were not good every time I tested them, but compatibility increased over time.

These programs have been ported experimentally. Many thanks to their authors.

Block Tower (C.Basic version)
https://pm.matrix.jp/CB/CB_BlockTower.zip

Sudoku (C.Basic version)
https://pm.matrix.jp/CB/CB_Sudoku.zip

Maze Generator (C.Basic version)
https://pm.matrix.jp/CB/CB_Mazegene.zip

Graph 3D (C.Basic version)
https://pm.matrix.jp/CB/CB_Graph3D.zip

Ice slider (C.Basic version 25/11/2018)
https://pm.matrix.jp/CB/CB_IceSlider.zip
(added Save/Load feature)

Clonelab (C.Basic version 25/11/2018)
https://pm.matrix.jp/CB/CB_Clonlab.zip
(added Save/Load feature)

Arkenstone (C.Basic version 25/11/2018)
https://pm.matrix.jp/CB/CB_Arkenstone.zip
(added Save/Load feature)

Aventura (C.Basic version 25/11/2018)
https://pm.matrix.jp/CB/CB_Aventura.zip
(added Save/Load feature)


Here are examples of programs that reach near-C performance :

BallGame (C.Basic version)
https://pm.matrix.jp/CB/CB_BallGame.zip

Asprin (C.Basic version)
https://pm.matrix.jp/CB/CB_Aspirin.zip


The C.Basic project is still yet to be completed, thus I would like to get your feedback.

This is the latest beta version of C.Basic 1.89beta for Graph 35+USB/75/85/95 (SD) : https://pm.matrix.jp/CB/CBASIC189beta.zip (updated 11/12/2018)

This is the latest alpha version of C.Basic for Graph90+E/fx-CG10/20/50:
https://pm.matrix.jp/CB/CBASICCG062.zip (updated 11/12/2018)

Currently C.Basic exists thanks to this site.
Thank you very much.



Sentaro21
Hors ligne
Membre
Points: 154
Défis: 0
Message
Dernier message de la page précédente :Posté le 21/06/2018 08:51 |
Thanks very much for trying

The FX version is near to the last for the interpreter version.
However,
If the Prizm version is developing still more,
I would appreciate it very much if you could point out anything to me.


Here is new updated. (re-uploaded 21/6/2018)
http://pm.matrix.jp/CB/CBASIC180beta.zip
http://pm.matrix.jp/CB/CBASICCG054.zip



Pages: Précédente | 1, 2, 3, 4, 5 | Suivante

Drak
Hors ligne
Rédacteur
Points: 1918
Défis: 38
Message
Citer : Posté le 24/06/2018 15:27 | #
Hi there!

I wanted to congratulate you for you work. I just tried your C:Basic engine and it is really impressive !
I am glad you came here to share what you've been working on. I tried Tower Block, but there was a problem : the command "BG-Pict 14" didn't seem to work. Pict14 is the picture Ninestars used to show the score in the game. How does it work, exactly? Dose the Picture have to be stored in the Main memory ?

And, here's an another question for you. What if I want to try my own game in your Basic interpreter? Do I have to import each files individually and rewrite each "Prog" functions I used in the game? And how does it work with the Pictures?

I hope you understand me!
----------------------------------
Eon the Dragon : version 1.2
Let's have a look!
Marre de ces RPGs qui t'imposent des classes, des compétences et des sorts ? Crée tes propres capacités sur Eon the Dragon ! Des monstres, des dragons et des combats aussi épiques que difficiles t'attendent !
Un RPG unique et immense t'attend ! Joue dès maintenant à Aventura, le Royaume Poudingue !
Vous aussi, soyez swag et rejoignez Planète Casio !
Ninestars
Hors ligne
Membre
Points: 2129
Défis: 22
Message
Citer : Posté le 24/06/2018 20:28 | #
Hey ! I tried Block Tower with this version of C.Basic !
This is incredibly fast ! Hoppefully I am the author of this programme, so I changed some parameters to make it playable
The next time I have to use Basic, I will use your editor, it it very useful. I saw few details like the scrolling mark. I also saw you made some changes to editor's functions.
I have to see it details
very good job !

Is it possible to open fill from main memory instead of storage memory ?
----------------------------------
Sentaro21
Hors ligne
Membre
Points: 154
Défis: 0
Message
Citer : Posté le 25/06/2018 04:32 | #
Hi Lephenixnoir,
Hi Drak,
Thanks very much for the introduction article of C.Basic.
French is helped as ever by google translation.
It's all thanks to you, I understand it well relatively.


Drak a écrit :
Hi there!

I wanted to congratulate you for you work. I just tried your C:Basic engine and it is really impressive !
I am glad you came here to share what you've been working on. I tried Tower Block, but there was a problem : the command "BG-Pict 14" didn't seem to work. Pict14 is the picture Ninestars used to show the score in the game. How does it work, exactly? Dose the Picture have to be stored in the Main memory ?

Thanks very much for trying.

About Pict14,
Please put Pict14.g1m in the current folder same as program file or Pict folder of storage memory.


Drak a écrit :

And, here's an another question for you. What if I want to try my own game in your Basic interpreter? Do I have to import each files individually and rewrite each "Prog" functions I used in the game? And how does it work with the Pictures?

I hope you understand me!

In the current version,
Pict file of the main memory is used with the main memory mode of [PictMode].
Pict file of the storage memory is used other than the main memory mode of [PictMode].

In generally,
if they are working in Genuine Basic,
C.Basic setting is
[PictMode:Main mem] (support Pict1024)
[Storage Mode:Main mem]
[RefreshCtl DD:off]
[Execute mode:CPLX]
It is not necessary to change the original file name.
I think that just work if the program is only for commands/functions supporting in C.Basic.

Furthermore,
[PictMode:Heap] (do not support Pict1024)
[RefreshCtl DD:(init) Graph 3/128]
[Execute mode:DBL# (not use complex number)]
Heap of PictMode is necessary to put Pict file in storage memory.
I think that they works fastest.

When you put the file to the storage memory,
[Storage Mode:S.Mem]
It may be necessary to change the original file name to the file name to be usable in storage memory.



Ninestars a écrit :
Hey ! I tried Block Tower with this version of C.Basic !
This is incredibly fast ! Hoppefully I am the author of this programme, so I changed some parameters to make it playable
The next time I have to use Basic, I will use your editor, it it very useful. I saw few details like the scrolling mark. I also saw you made some changes to editor's functions.
I have to see it details
very good job !

Hi Ninestars,
Thanks very much for trying C.Basic again.

I still play Block Tower well.
It is very splendid Basic application.

It work as the original source of main memory mode in the current version 1.80beta.
c1 or c2 of the variable are secured automatically without the error.

For the speed adjustment of the program in C.Basic.
There is TicksWait that the command suitable for speed adjustment.

(example)
TicksWait -10

Regardless of the speed of the calculator,
It wait until time of 10/128 seconds comes from the last time.
The timing in the loop is possible only by this command.

To input the command,
[VARS]-[F3](extd)-[F1](Ticks)-[F2](Wait)


Ninestars a écrit :
Is it possible to open fill from main memory instead of storage memory ?

It is only the difference of the saving point of the program file with main memory mode and the storage memory mode basically.
Because the program execution area becomes smaller than genuine Basic when memory is the heap, I recommend use of the hidden RAM.


I'm sorry if I have misunderstood.
Please ask me a question again.
Lightmare
Hors ligne
Membre de CreativeCalc
Points: 319
Défis: 0
Message
Citer : Posté le 25/06/2018 09:45 | #
Hi Sentaro !
I have one question for you :
Do you have an easy way to make a Basic program compatible with C.Basic ?

...Also : do you heard about PRGM2 project ? His objective was to add new possibilities to Basic ( like multiplayer, or the possibility to add sprites to a game). Just take a look, this can inspire you !

Sorry for my ugly English
----------------------------------
While 1
WhileEnd

une boucle encore plus optimisée que celle de Kikoodx
Sentaro21
Hors ligne
Membre
Points: 154
Défis: 0
Message
Citer : Posté le 26/06/2018 02:45 | #
Lightmare a écrit :
Hi Sentaro !
I have one question for you :
Do you have an easy way to make a Basic program compatible with C.Basic ?

Hi Lightmare
C.Basic is compatible with genuine Casio Basic.
I think that BIDE is usable other than on calc programming.

C.Basic operate with the main memory mode.
[Storage Mode:Main mem]
You can operate a program same as genuine Casio Basic in C.Basic.

When your "Evolution" run in C.Basic, I think that it is more interesting.

Lightmare a écrit :

...Also : do you heard about PRGM2 project ? His objective was to add new possibilities to Basic ( like multiplayer, or the possibility to add sprites to a game). Just take a look, this can inspire you !

Yes, I know PRGM2.
I'm surprised that expansion of Casio Basic by the small program.

C.basic supports MonochromeLib like PRGM2, too, and the serial communication is possible, too.
Probably I think that most PRGM2 application can port to C.basic.

Lightmare a écrit :
Sorry for my ugly English

It's no problem.
I can understand what you said.
I'm sorry too that my English is not good same as usual.


Ajouté le 07/07/2018 à 13:17 :
Hi,
Here is new updated version.
http://pm.matrix.jp/CB/CBASIC181beta.zip
-Fixed label of List bug that do not worked less than 8 character.

-Added Det of Mat command.
-Added [ALPHA]+[alphabet key][Theta][r],[SHIFT]+[Ans],[X]key jump of Mat editor screen
-Added [F6](retry) search function of during execution search of editor.

-Fixed [SHIFT]+[EXIT](QUIT) of editor in debug mode that excute the program.
-Added setup of debug mode exit popup.
-Fixed not worked fuction key of debug mode after [EXIT].

-Added up/dwon allow character of command history/ command input popup.
-Added V-MEM access in V-Win setup.

-Fixed text converting bug that 0b0,0b1,0b2,0x1,0x2,0x3 are failed.
-Fixed setup bug that changed Fix/Sci/Norm setteing after [EXIT].


Here is new alpha version C.Basic for fx-CG10/2050/Graph90+E.
http://pm.matrix.jp/CB/CBASICCG055.zip
Drak
Hors ligne
Rédacteur
Points: 1918
Défis: 38
Message
Citer : Posté le 07/07/2018 13:56 | #
Excellent ! Good job, Sentaro21! I'm glad you're going on with that project!
----------------------------------
Eon the Dragon : version 1.2
Let's have a look!
Marre de ces RPGs qui t'imposent des classes, des compétences et des sorts ? Crée tes propres capacités sur Eon the Dragon ! Des monstres, des dragons et des combats aussi épiques que difficiles t'attendent !
Un RPG unique et immense t'attend ! Joue dès maintenant à Aventura, le Royaume Poudingue !
Vous aussi, soyez swag et rejoignez Planète Casio !
Sentaro21
Hors ligne
Membre
Points: 154
Défis: 0
Message
Citer : Posté le 07/07/2018 14:30 | #
Thanks very much.
If possible, I want to support all Casio-Basic application programs in the future.

Ajouté le 20/08/2018 à 14:26 :
Hi,
Here is new updated version.
This is the update that reflected the fixed bug of CG version.

http://pm.matrix.jp/CB/CBASIC182beta.zip
-Change specification of Graph Y= is not neccsesary "".

-Change to not display "Done" of text mode after Cls/ViewWindow.

-Fixed [F1][F6]function display left in the replace of editor.
-Fixed the replace mode of editor was finished by [AC] in [F4](ALL)/[F5](ALL+).
-Fixed not accepted by numerical value input of the 4 in element size of Mat.

-Change specification to become the absolute value when set a negative value in Xscale/Yscale of V-Win.

-Fixed [F4](A<>a) can not change at the 1 line input.
-Fixed that function menu was reset by the search / replace of the editor.

-Change specification of "" display same as genuine Casio Basic.
-Added option command that change "" display mode.
(format) '#58
fx-5800P mode
(format) '#98
fx-9860G/fx-CG mode

-Fixed screen recover error of 1 line input of C.Basic command input method.
([F3](CMD)->[OPTN]/[VARS]/[SHIFT]+[VARS] etc.)

-Fixed label of List bug that do not worked less than 8 character.

-Added Det of Mat command.
-Added [ALPHA]+[alphabet key][Theta][r],[SHIFT]+[Ans],[X]key jump of Mat editor screen
-Added [F6](retry) search function of during execution search of editor.

-Fixed [SHIFT]+[EXIT](QUIT) of editor in debug mode that excute the program.
-Added setup of debug mode exit popup.
-Fixed not worked fuction key of debug mode after [EXIT].
-Added up/dwon allow character of command history/ command input popup.
-Added V-MEM access in V-Win setup.

-Fixed not worked fuction key of debug mode after [EXIT].
-Fixed setup bug that changed Fix/Sci/Norm setteing after [EXIT].



for fx-CG10/20/50/Graph90+E.
http://pm.matrix.jp/CB/CBASICCG056.zip
Lightmare
Hors ligne
Membre de CreativeCalc
Points: 319
Défis: 0
Message
Citer : Posté le 26/08/2018 16:37 | #
I write this question in english beause it's an english topic, but everybody can answer

How can i make a serial communication between two calculators ? I mean : which functions must i use ?
----------------------------------
While 1
WhileEnd

une boucle encore plus optimisée que celle de Kikoodx
Kikoodx
Hors ligne
Membre
Points: 803
Défis: 7
Message
Citer : Posté le 26/08/2018 16:45 | #
C : https://www.planet-casio.com/Fr/forums/topic15170-1-Le-mutiJoueur-sur-Casio...c-est-possible-.html
Basic : I don't know.
----------------------------------
Lbl 1
Goto 1


Une boucle optimisée
Shadow15510
Hors ligne
Administrateur
Points: 2192
Défis: 15
Message
Citer : Posté le 26/08/2018 17:11 | #
In Basic this project is... impossible : the serial connexion isn't possible... But an Add-in allow to use this connexion for communicate with the 3 pin : https://www.planet-casio.com/Fr/forums/topic10140-1-PRGM2---Ajouter-des-fonctions-au-Basic-Casio.html
----------------------------------
"Ce n'est pas parce que les chose sont dures que nous ne les faisons pas, c'est parce que nous ne les faisons pas qu'elles sont dures." Sénèque

Moral
   85%
Lephenixnoir
Hors ligne
Administrateur
Points: 13150
Défis: 136
Message
Citer : Posté le 26/08/2018 17:15 | #
Shadow, have a look at this topic: we're talking about Sentaro's extended Basic interpreter. What we can do in vanilla Basic is not really relevant right now.

The documentation of the functions is here: https://egadget2.web.fc2.com/CBasic/Interpreter/Reference.html

Although, at a quick glance, I found nothing related to serial communication. You could call the appropriate syscalls with the SysCall() function from there, however.

https://egadget2.web.fc2.com/CBasic/Interpreter/MemAccsCom.html
----------------------------------
Rise.
Lightmare
Hors ligne
Membre de CreativeCalc
Points: 319
Défis: 0
Message
Citer : Posté le 26/08/2018 18:09 | #
thanks very much to you all !
now i know that i must use syscalls to make a multiplayer game with C.Basic !
----------------------------------
While 1
WhileEnd

une boucle encore plus optimisée que celle de Kikoodx
Sentaro21
Hors ligne
Membre
Points: 154
Défis: 0
Message
Citer : Posté le 01/09/2018 01:48 | #
Thanks everyone.
Sorry for the late reply.

The current version of C.Basic has some serial commands.
Please look at the 2106 line of the Manual_EN.txt
(sample program)
http://pm.matrix.jp/CB/SERIAL_sample.zip

I do not know whether these commands can become practical.
Maybe you should use the SysCall.
Please look at the 1533 line of the Manual_EN.txt
Lightmare
Hors ligne
Membre de CreativeCalc
Points: 319
Défis: 0
Message
Citer : Posté le 02/10/2018 20:27 | #
After a few tries, i made a little program using serial communication with Send and Receive commands and it works !
...But when i wanted to make a chat by sendind Str, it gives me an error :

sending program :
?->Str 1
Send(Str 1)
"OK"


receiving program :
"NULL"->Str1
While StrCmp("NULL",Str1)=0
Receive(Str 1)
WhileEnd
Locate 1,1,Str 1
----------------------------------
While 1
WhileEnd

une boucle encore plus optimisée que celle de Kikoodx
Drak
Hors ligne
Rédacteur
Points: 1918
Défis: 38
Message
Citer : Posté le 02/10/2018 21:44 | #
What kind of error does it raise?
----------------------------------
Eon the Dragon : version 1.2
Let's have a look!
Marre de ces RPGs qui t'imposent des classes, des compétences et des sorts ? Crée tes propres capacités sur Eon the Dragon ! Des monstres, des dragons et des combats aussi épiques que difficiles t'attendent !
Un RPG unique et immense t'attend ! Joue dès maintenant à Aventura, le Royaume Poudingue !
Vous aussi, soyez swag et rejoignez Planète Casio !
Sentaro21
Hors ligne
Membre
Points: 154
Défis: 0
Message
Citer : Posté le 03/10/2018 03:56 | #
Thanks for trying serial command.

Recieve( command wait for until data of Send(.
This is a simple chat program.
The receiving error sometimes happens.

While 1
?->Str 1
Send(Str 1)
Recive(Str 2)
Disp Str 2
WhileEnd

Disp command is new command of C.Basic.
[SHIFT]-[VARS](PRGM)-[F6]-[F2](DISP)-[F6](Disp)
Lightmare
Hors ligne
Membre de CreativeCalc
Points: 319
Défis: 0
Message
Citer : Posté le 03/10/2018 06:58 | #
thanks Sentaro ! so it's works but there is an error sometimes, isn't it ?
i will try !
----------------------------------
While 1
WhileEnd

une boucle encore plus optimisée que celle de Kikoodx
Sentaro21
Hors ligne
Membre
Points: 154
Défis: 0
Message
Citer : Posté le 03/10/2018 08:43 | #
Yes.
It is almost works well.
but there is the [Receive ERROR] sometimes.
Lephenixnoir
Hors ligne
Administrateur
Points: 13150
Défis: 136
Message
Citer : Posté le 03/10/2018 17:30 | #
Would you happen to know what kind of communication error produces this?
----------------------------------
Rise.
Sentaro21
Hors ligne
Membre
Points: 154
Défis: 0
Message
Citer : Posté le 04/10/2018 08:26 | #
It is an error by Serial_ReadOneByte of SysCall.
but its detail is not well known.
It may be a bit error on the cables, but my program may be wrong.
I'm not familiar with the serial communication.
If there is a solution, I want to know it.
Is there any information regarding this?

Pages: Précédente | 1, 2, 3, 4, 5 | Suivante

Index du Forum > Projets de programmation > C.Basic Projets

Planète Casio v42 © créé par Neuronix et Muelsaco 2004 - 2018 | Il y a 18 connectés | Nous contacter | Qui sommes-nous ? | Licences et remerciements

Planète Casio est un site communautaire indépendant, géré bénévolement et n'est donc pas affilié à Casio | Toute reproduction de Planète Casio, même partielle, est interdite
Les fichiers, programmes et autres publications présents sur Planète Casio restent la propriété de leurs auteurs respectifs et peuvent être soumis à des licences ou des copyrights.
CASIO est une marque déposée par CASIO Computer Co., Ltd