From X-Basic to ROM?

Page 1/2
| 2

By Pineapple

Supporter (15)

Pineapple's picture

12-06-2020, 23:57

Hello, I just started using X-basic and need some help.
I'd like to know 2 things:
First, how do I save the compiled program?
And second, Is it possible to make a rom file from an X-basic program?

I have a simple little game I'm working on, and it'd be fun to submit it for the competition, but ASM is beyond me at this point and I couldn't find any info when I searched the forums.

Thanks!

Login or register to post comments

By Dolphin101546015

Champion (270)

Dolphin101546015's picture

13-06-2020, 02:18

It not possible in this way, coz compilling going in runtime.
You just able made ROM as for any basic code (search this here on the forum),
but it anyway only ROM with basic code inside,
and for starting this ROM, you need machine with integrated X-Basic ROM.

So, X-Basic - is not standalone compiler, just runtime.

By Jipe

Paragon (1386)

Jipe's picture

13-06-2020, 05:38

it's possible to make a game with X-Basic in ROM
see Penguin Café to MSX dev Wink
first 16k are X-Basic
last 16k is Game

By Dolphin101546015

Champion (270)

Dolphin101546015's picture

13-06-2020, 07:21

Jipe wrote:

it's possible to make a game with X-Basic in ROM
see Penguin Café to MSX dev Wink
first 16k are X-Basic
last 16k is Game

He asqing about compilled code.

By Daemos

Paragon (1718)

Daemos's picture

13-06-2020, 08:56

Ask kai magazine. I believe all his roms are xbasic. Although it could something else. Just ask.

By tfh

Prophet (2316)

tfh's picture

13-06-2020, 12:14

There is no size-limit anymore for MSXDev when it comes to the .ROM file. You can also just make a disk with all your normal files and use DSK2ROM.

By Manuel

Ascended (16692)

Manuel's picture

13-06-2020, 12:18

Dolphin101546015 wrote:
Jipe wrote:

it's possible to make a game with X-Basic in ROM
see Penguin Café to MSX dev Wink
first 16k are X-Basic
last 16k is Game

He asqing about compilled code.

Yeah, but what Jipe says is the solution then right? BASIC code and compiler in one ROM... although I'm not sure about the compiler's license permitting this...

By gdx

Prophet (3561)

gdx's picture

13-06-2020, 13:12

The X-Basic partially compiles when the Basic program is executed. The compiled code remains dependent on the Basic program so it is impossible to extract the compiled code. This is convenient but take up more space in RAM.

By Pineapple

Supporter (15)

Pineapple's picture

13-06-2020, 23:12

Thanks, I'll check out the Penguin Cafe thing.

By gdx

Prophet (3561)

gdx's picture

14-06-2020, 12:33

The procedure is simple. You have to create a Rom (8000h-BFFFh) with your Basic program, for example like as this:
https://www.msx.org/forum/msx-talk/development/convert-a-pro...
And then add the X-Basic Rom in front (4000h-7FFFh) by copy/past with a Hexa editor.

This will make you a 32K Rom with two headers. This should work without problems if you don't create too many variables and compiled code.

By Daemos

Paragon (1718)

Daemos's picture

14-06-2020, 13:02

Will incbinning the compiled code together with the xbasic rom not be easier. You can then add any ml to your rom too.

Page 1/2
| 2