Cross-compiler for MICROCOLOR BASIC 1.0 (MC10/Alice 4K)

Cette catégorie traite de développements récents destinés à nos vieilles machines, applications, jeux ou démos... Amis programmeurs, c'est ici que vous pourrez enfin devenir célèbres!

Modérateurs : Papy.G, fneck, Carl

Avatar de l’utilisateur
Carl
Modérateur
Messages : 13301
Inscription : 08 avr. 2007 13:21
Localisation : http://www.doledujura.fr
Contact :

Cross-compiler for MICROCOLOR BASIC 1.0 (MC10/Alice 4K)

Message par Carl »

A cross-compiler for MICROCOLOR BASIC 1.0 which runs on a stock TRS-80 MC-10 (preferably with the 16K adaptor or Darren Atkinson's MCX-32SD).

Requirements
A real "stock" TRS-80 MC-10 or an emulator like the "Virtual MC-10"
A text file containing a MICROCOLOR BASIC program.
The 16K Expansion is very helpful except for very small programs
https://github.com/gregdionne/mcbasic

Carl
Daniel
Messages : 17426
Inscription : 01 mai 2007 18:30
Localisation : Vaucluse
Contact :

Re: Cross-compiler for MICROCOLOR BASIC 1.0 (MC10/Alice 4K)

Message par Daniel »

C'est une très bonne base pour faire un compilateur BASIC pour Alice 32 et 90. Bravo pour cette trouvaille !
Daniel
L'obstacle augmente mon ardeur.
__sam__
Messages : 7989
Inscription : 18 sept. 2010 12:08
Localisation : Brest et parfois les Flandres

Re: Cross-compiler for MICROCOLOR BASIC 1.0 (MC10/Alice 4K)

Message par __sam__ »

Chose intéressante: Ce compilateur utilise des opérations non documentées.
Currently only the undocumented negate-with-carry instructions. The MC6801 and MC6809 both implement NGCA (opcode $42), NGCB (opcode $52), NGC <indexed> (opcode $62), and NGC <extended> (opcode $72). These permit negation of the "D" register in four cycles by issuing a NEGB (opcode $50) followed by NGCA (opcode $42). They can also negate multi-byte numbers in-place.² Use caution when using the ‑undoc switch, as many 6801 emulators fail to implement these instructions correctly.
Du coup ce basic avec des entiers sur 3 octets, des float convertis en fixed point 24:16 (24 bits pour la partie entière, 16 pour la fractionnaire), c'est vraiment pas mal. La dessus un bytecode compact ou directement du langage machine natif. C'est vraiment un beau programme.
Samuel.
A500 Vampire V2+ ^8^, A1200 (030@50mhz/fpu/64mb/cf 8go),
A500 GVP530(MMU/FPU) h.s., R-Pi, TO9, TO8D, TO8.Démos
Avatar de l’utilisateur
David.G
Messages : 301
Inscription : 16 janv. 2024 00:02

Re: Cross-compiler for MICROCOLOR BASIC 1.0 (MC10/Alice 4K)

Message par David.G »

Bravo Carl, bien joué ! C'est vraiment un beau programme effectivement !
Répondre