Convert basic files to com files

Page 1/4
| 2 | 3 | 4

Par edoz

Paragon (1521)

Portrait de edoz

12-01-2012, 14:50

Hi There,

Is there a utill to convert basic files to COM files (for dos2.x) ?
So that you can start your basic program directly from dos ?
Also when you stop the program you end in dos (not in basic)

Is there something like that ?

!login ou Inscrivez-vous pour poster

Par MsxKun

Paladin (718)

Portrait de MsxKun

12-01-2012, 16:56

Well, for the first part, you only need to type "BASIC program.bas"
If you lazy to type so much, make a .bat file with that line and name it "program.bat".
For the second part, for exit you can put a key/menu/option that jumps to a line with "CALL SYSTEM". Won't work if you press CTRL+STOP but you can avoid that too... (ON STOP GOSUB... blahblah..)

Par Josb

Resident (64)

Portrait de Josb

12-01-2012, 19:20

Hi

there are some programs that can convert basic files to COM, but I don't know which versión Sad

one of them is mozart that was create by someone from Brasil (I think). This program is able to make that a file basic runs as .com file under DOS (even it is so slow that the original basic file).

another one is VBC, a MSX-BASIC (from MSX2) compiler (It is a bit different)

and finally you can use BASCOM (only text)

If I am not in a mistake, they will make that you want, although I don't know where you can find them.

bye

Par PingPong

Prophet (2629)

Portrait de PingPong

13-01-2012, 23:33

another one is VBC, a MSX-BASIC (from MSX2) compiler (It is a bit different)

What about VBC ?  can you post some other info? never heard about it.
thx

Par SLotman

Paragon (1133)

Portrait de SLotman

14-01-2012, 03:24

There were 2 brazilian programs that could do it on 2 stages.

First one was BASBIN, which as the name says, convert .BAS to .BIN
Then there was BIN2COM (or BINCOM, too long ago I don't remember very well), which - duh - converted .BIN to .COM.

I remember it worked really well... but unfortunately I have no idea where you can find those files Sad

Par Josb

Resident (64)

Portrait de Josb

14-01-2012, 12:16

hi PingPong,

the information I have  got about VBC is this, (from its readme.txt file)

SOLiD VBasic, version 2.7
=========================

Here it goes, a BASIC compiler for MSXDOS.
This version must be considered a wide public beta,
and it contains some bugs that are listed below.

RUNNING
--------------------------------------
To use the compiler you must have:
  a) compiler itself;
  b) library files: bk.rel, basend.rel and ilib.irl
  c) AS assembler and LD linker
All the stuff can be downloaded from SOLiD home page
at http://www.glasnet.ru/~msxegor/msx.html

To compile your program, save it in ASCII format
as a <filename>.BAS (note BAS extension) and then
type the following command:

	BAS <filename>

(note NO extension)
If no errors occur, you will get <filename>.COM
MSDOS executive.


LANGUAGE
--------------------------------------
Supported features:
+  MSX-2 BASIC, file in ASCII format.
+  Some of MSX-2+ BASIC features like set scroll
+  WHILE/WEND extension
+  LOOP WHILE/UNTIL extension

Unsupported features:
+  LOAD/SAVE,CLOAD/CSAVE,MERGE and BLOAD/BSAVE (except for BLOAD,S) commands
+  ERASE not supported  and causes error
+  Arrays must be defined once, with constant length.
+  CLEAR works differently; only string variables cleared
+  X commands of play and draw macro languages not supported
+  Maximum two-dimensioned arrays supported (sorry for this one)
+  RESUSME without parametres may cause errors (or may not, this depends)
+  Vaiables of same names and different types not supported

Other differences
+  RUN executes DOS COM file
+  DEFINT A-Z by default!
+  Lines may NOT be numbered
+  (maybe something else, I don't remember)


KNOWN BUGS
---------------------------------
This version of compiler and libraries was written for a very
tignt configuration. This is not portable, I know, but it was
written in the times when the very single MSX architecture in
Russia (USSR back then) was Yamaha MSX.
The programs are written to be fast, using direct hardware
access where possible. This mapy cause troubles when running
on systems much different from Yamaha. In opposite, most
Philips MSX users will probably NOT face any troubles at all.

Bug list follows:
+  RST30 used to call BIOS in libraries. May cause troubles
   on MSXes with RAM in extended slot 0 (Daewoo)
+  Direct slot switching in float point routines. May cause
   problems on computers with SUB-ROM in extended slot 0
+  Some library routines may occasionaly cause trouble with
   DOS 2.


DISCLAIMER
----------------------------------
This program is PUBLIC DOMAIN BETA.
Feel free to report bugs and suggestions to Egor VOZNESSENSKI,
the autor, at msxegor@glasnet.ru
If I get enough responce, I shall produce a new, enhanced
version, as well as good documentation in english.

Home page:
	http://www.glasnet.ru/~msxegor

____________________________________________________________________________

My notes:


HOW TO USE 'GOTO' INSTRUCCIONS

If you want to use label for goto instruction, you must use a number of line
for example, look next code:

	defint i
	cls
	10
	print i
	if i=100 then end else i=i+1:goto 10


HOW TO USE 'DO ... LOOP UNTIL/WHILE' LOOPS

	DO
		PRINT I
		I=I+1
	LOOP UNTIL ... 
__________________________________________________________________

In spite of my short programs like this

cls
screen 0
width80
print "Este programa es simplemente un ejemplo con VBC"
for p=1 to 1000
r=(2^p-2)/2
if r=int(r) then print p
next p
end

or this one

COLOR 2,1,1
SCREEN5

FOR A=1	TO 80
	FOR I=0	TO A
		LINE(0,A)-(A,A),2
	NEXT I	      
NEXT A
END

which work perfectly I didn't got any information about this compiler

I think it will be a good idea getting informatión about it but I don't have a clue about how to do it

By the way, you can see that to compile a program you have to use "bas <filename>", however there is a vbc.com file that does the same work, this is why I said VBC.

Big smile

Par ARTRAG

Enlighted (4790)

Portrait de ARTRAG

14-01-2012, 13:34

where are the files on the net?

Par Josb

Resident (64)

Portrait de Josb

14-01-2012, 17:36

good question Smile

I'm afraid I don't know where they can be found. A few years ago I downloaded from funnet

it will be reliable to contact his author by e-mail, maybe he is alive too (I mean as MSX user, of course) .

Anyway I'm vey surprised that nobody around knows this compiler

Par ARTRAG

Enlighted (4790)

Portrait de ARTRAG

14-01-2012, 18:46

why not putting them on mrc?

Par Josb

Resident (64)

Portrait de Josb

14-01-2012, 20:06

let me know how to do it

please

Par snout

Ambassador (14874)

Portrait de snout

14-01-2012, 20:23

in order to be able to distribute the utility on MRC, we do need permission from the author. does anyone know whether or not this util was declared freeware at some point in time?

Page 1/4
| 2 | 3 | 4
My MSX profile