Author Topic: BxbAsm  (Read 178777 times)

SteveA

  • Guest
Re: BxbAsm
« Reply #75 on: February 08, 2012, 07:45:33 AM »
  This is an FYI when compiling bxbasm with Pelles C.
Code: [Select]
Setting 32-bit environment for Pelles C...
Compiling "BCXBXBASM.c"..........

Yeh, those just reflect changes I've made along the way and have yet to clean up.
They're all local variables that I discontinued using as time went on.
They don't affect the outcome of the program.

Thanks for providing that list James. I'll clean those up asap.

SteveA

  • Guest
Re: BxbAsm
« Reply #76 on: February 10, 2012, 06:56:03 PM »
 ;)
Here's this weeks updated code (attached).
This zip file contains the executable and all the source files (zipped).
Not everything is included, as not everything has changed.
The .txt file lists the new things added to this version.
Additionally, there is an examples.zip containing some .bas examples.

James,
many of the things needing fixes, that you illustrated, have been corrected.
However, I did not make the C++ related changes.

« Last Edit: May 02, 2012, 03:26:53 PM by SteveA »

jcfuller

  • Guest
Re: BxbAsm
« Reply #77 on: February 11, 2012, 02:51:34 AM »
Steve,
  I can still compile with g++ if I use -fpermissive except for line 1133 of Input.c. You have no data type for ndx.

changing:
Code: [Select]
void var_types(ndx)                    /* tokenize variable types */
To
Code: [Select]
void var_types(int ndx)                    /* tokenize variable types */

fixes the problem.

I am surprised both LCWin32 and Pelles accepts this? Is this a "c" defult standard?

James

jcfuller

  • Guest
Re: BxbAsm
« Reply #78 on: February 11, 2012, 04:06:26 AM »
Steve,
  I know this is still alpha but I report all I find that is not quite what I expect.

In Epilog() AInput.c remove.

Code: [Select]
  writeln("  invoke StdIn, addr BffrInput, BUFFR_SIZ   ; pause");

The pause should be in the basic source if you want/need it for display.

It also appears your PAUSE only responds to Enter Key. Needs to be changed to any key in my opinion

James

Edit:

Steve,
  I use _getch() for both Windows and Linux with ubx.
In Output.c I changed
Code: [Select]
writeln("invoke gets, addr BffrInput");
To:
Code: [Select]
writeln("invoke _getch");
and it appears to work fine.
Contrary to some info I found _getch() is avaiable everywhere I tried it?



« Last Edit: February 11, 2012, 06:06:27 AM by jcfuller »

jcfuller

  • Guest
Re: BxbAsm
« Reply #79 on: February 11, 2012, 06:09:32 AM »
Steve,
  Sources for bxblib.lib ???

James

SteveA

  • Guest
Re: BxbAsm
« Reply #80 on: February 11, 2012, 03:42:43 PM »
I can still compile with g++ if I use -fpermissive except for line 1133 of Input.c. You have no data type for ndx.

Actually, it's prototyped as:     void var_types(int);
I think that's why its accepted.

My bad tho'.  ???
Your fix is correct.  ;)

As I looked at the code, I noticed that I'm not using that function, ( var_types() ),  anyway.
But, I'm not ready to delete it, just yet.
Thanks for the heads up.

SteveA

  • Guest
Re: BxbAsm
« Reply #81 on: February 11, 2012, 03:55:23 PM »
Code: [Select]
  writeln("  invoke StdIn, addr BffrInput, BUFFR_SIZ   ; pause");
The pause should be in the basic source if you want/need it for display.
It also appears your PAUSE only responds to Enter Key. Needs to be changed to any key in my opinion

Yes, I did it that way only because I was using QEditor as my IDE.
QEditor pops open a console window, on top of the GUI screen, during execution.
I needed to suspend the console in place after execution, since I didn't yet have a PAUSE command in place.

Quote
  I use _getch() for both Windows and Linux with ubx.

"Roger"..., I'll make that change.
Thanks.

SteveA

  • Guest
Re: BxbAsm
« Reply #82 on: February 11, 2012, 04:11:00 PM »
« Last Edit: May 02, 2012, 03:27:32 PM by SteveA »

SteveA

  • Guest
Re: BxbAsm
« Reply #83 on: February 14, 2012, 04:58:43 PM »
 ???
I was working on adding some more math functionality and hit a snag with fabs().
At first, jwasm gave me a missing prototype error like:
Quote
INVOKE requires prototype for procedure

so, I went into math.inc and saw that the proto line for fabs was commented out.
I un-commented it and now get this error:
Quote
math.inc(81) : Error A2082: Must be in segment block
 math.inc(81): Included by
   Test2.asm(15): Main line code
Test2.asm(117) : Error A2159: INVOKE requires prototype for procedure

I've no idea what that should mean.
Any ideas ?   :-\

jcfuller

  • Guest
Re: BxbAsm
« Reply #84 on: February 15, 2012, 03:03:16 AM »
Steve,
  I ran h2incx against MinGW and TCC math.h and both spit out fabs_ ?
While waiting on a reply at sourceforge try creating your own proto.

James

SteveA

  • Guest
Re: BxbAsm
« Reply #85 on: February 15, 2012, 06:59:47 AM »
I ran h2incx against MinGW and TCC math.h and both spit out fabs_ ?

Hmm.
I noticed that Japheth uses inc and lib files from Visual Studio 6.
I was planning on trying VS 2008 and Mingw, to see if they work.
Also, I searched math.inc for anything with *fabs*.
There are several, but, none are "fabs_".

Quote
While waiting on a reply at sourceforge try creating your own proto.

Yeh, that was one of the first things I did. It didn't have any affect.
I think it's a bug of some sort in the lib file, having nothing to do with the proto.
I think that's why Japheth commented-out the original proto in math.inc.
He must have encountered the bug, previously.

SteveA

  • Guest
Re: BxbAsm
« Reply #86 on: February 20, 2012, 05:07:33 PM »
Here's the past weeks updated code (attached).
This zip file contains the executable and all the source files (zipped).

Again, not everything is included, as not everything has changed.
The .txt file lists the new functionality added to this version.
The examples.zip contains a few .bas examples.

There are numerous math routines added, but, the most significant addition is SUBs.
SUBs are available only in a limited way.
The example Sub1.bas shows the limited extent of the testing.

Steve
« Last Edit: May 02, 2012, 03:28:05 PM by SteveA »

SteveA

  • Guest
Re: BxbAsm
« Reply #87 on: February 21, 2012, 01:48:26 PM »
I'll be working on further development of SUBs.
So don't be discouraged that they are still in a primitive state.

So far, (as can be seen by the examples), SUBs can be declared and be passed simple variables.
Next I need to be able to declare and assign local variables.

Steve

SteveA

  • Guest
Re: BxbAsm
« Reply #88 on: February 24, 2012, 07:47:18 AM »
Okay, attached is this weeks update.
I've done more work on SUBs and am now able to DIM local variables.
Only the files affected are included in the zip.

Additionally, a couple of bugs were fixed that involve While/Wend.

For anyone new to this forum, and reading this for the first time, go back and first download the prior zip files from earlier posts.
Since this is not an official release of bxbasm, no setup or installation info is included.
I can only assume that you already have Jwasm installed, (off the root directory of the C drive).

James,
let me know if you get this running on Linux and any problems or issues.

If anyone else has been able to get bxbasm installed and working, on either platform, please let me know.

Thanks,
Steve
« Last Edit: May 02, 2012, 03:28:46 PM by SteveA »

SteveA

  • Guest
Re: BxbAsm
« Reply #89 on: April 09, 2012, 07:51:16 AM »
James,
haven't heard from you in a while.
Are you still working with Bxbasm ?

If so, I wanted to touch base on a few things.
If not, no biggy.