Basic in line assebler
Basic in line assebler
is there going to be, or could there be, an in line assebler in basic similar to that of the bbc computers bbc basic? It's a great tool for experimenting and learning
Basic in line assebler
While that would be cool, I think it's not likely at this point. The team IS building a ROM based assembler IDE, which will be much more powerful than BBC BASIC's assembly. You should be able to drop in and out of the assembly editor at any time, so you would just need to use SYS statements to run assembly subroutines from BASIC.
With the planned BASIC editor, which will not require line numbers, the CX16's code editing will be more advanced than any 80s micro.
-
- Posts: 511
- Joined: Sat Apr 25, 2020 4:53 pm
-
- Posts: 94
- Joined: Mon May 18, 2020 7:25 pm
Basic in line assebler
Yeah, assembly in-line with a BASIC program is a great concept, but I agree with @TomXP411 that this overlaps significantly with the other assembly IDE in the system. Then again, maybe the core code there could be reused and called from BASIC?
Basic in line assebler
8 hours ago, Michael Steil said:
Yeah, assembly in-line with a BASIC program is a great concept, but I agree with @TomXP411 that this overlaps significantly with the other assembly IDE in the system. Then again, maybe the core code there could be reused and called from BASIC?
The more I think about it, the more it seems possible... you could do it a couple of different ways, but I like this syntax:
so something like....
100 PRINT "HELLO ASSEMBLY"
110 ASM BEGIN
120 do assembly stuff
150 ASM END
When the program is RUN, the parser would iterate through the program, look for any ASM blocks, and pass them in to the assembler IDE. That would allocate a chunk of RAM in upper memory and run the assembly code up there.
However, I'm still at the "I'm not sure there's a benefit" stage, when I could just as easily hit F4 (or whaetever), write my assembly code there, and just run it from the main program with BANK, LOAD, and then SYS.
Maybe this would be a good "2.0" project, once the basic machine is working, and you're looking for incremental enhancements.
Basic in line assebler
On 7/2/2020 at 7:11 AM, TomXP411 said:
While that would be cool, I think it's not likely at this point. The team IS building a ROM based assembler IDE, which will be much more powerful than BBC BASIC's assembly. You should be able to drop in and out of the assembly editor at any time, so you would just need to use SYS statements to run assembly subroutines from BASIC.
What would be nice is a SYSLOAD keyword to move the top of basic down to just below the top of the address of the PRG file specified in the LOAD, so you could work on the Assembly routine in the Assembler IDE, save it as a PRG, and then SYSLOAD it from Basic and you are ready to do SYS calls into that assembled code.
Basic in line assebler
19 hours ago, BruceMcF said:
What would be nice is a SYSLOAD keyword to move the top of basic down to just below the top of the address of the PRG file specified in the LOAD, so you could work on the Assembly routine in the Assembler IDE, save it as a PRG, and then SYSLOAD it from Basic and you are ready to do SYS calls into that assembled code.
Actually, the Tandy 100 uses the CLEAR command to do allocate memory for ML routines. And that's legit Microsoft BASIC - it was the last project Bill Gates personally developed.
CLEAR with no arguments simply erases variable
CLEAR address sets the top of BASIC so that address is available. So if you set CLEAR 32768, the space between 32768 and the top of low RAM would be available for ML co-routines. (So to be clear..... CLEAR 32768 actually sets the top of BASIC pointer to 32767).
While SYSLOAD seems like a nice keyword to use, CLEAR makes it abundantly clear that this resets all variables.....
Basic in line assebler
My idea there is that you don't need the address, but OTOH, you need to know the address to do the syscall.
I guess to be completely " implied address", it should be USRLOAD"file"[,dev] and put the start address of the binary in the USR locale.
Basic in line assebler
On 7/2/2020 at 12:11 AM, TomXP411 said:
While that would be cool, I think it's not likely at this point. The team IS building a ROM based assembler IDE, which will be much more powerful than BBC BASIC's assembly. You should be able to drop in and out of the assembly editor at any time, so you would just need to use SYS statements to run assembly subroutines from BASIC.
With the planned BASIC editor, which will not require line numbers, the CX16's code editing will be more advanced than any 80s micro.
The reason I would want it is for playing with assembler rather than it being a serious app dev option.