News:

Printed Amstrad Addict magazine announced, check it out here!

Main Menu

Basic of the cpc 6128 is to begin with & 6000 ?

Started by cpcuser, 09:12, 27 October 16

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

cpcuser


Basic of the cpc 6128 is to begin with & 6000.


How is that ?




greeting

HAL6128

I don't understand your question. What do you mean with "begin with & 6000"?
...proudly supported Schnapps Demo, Pentomino and NQ-Music-Disc with GFX

cpcuser

> &5fff asm and ab &6000>  basic


greeting

arnoldemu

Quote from: cpcuser on 14:41, 27 October 16
> &5fff asm and ab &6000>  basic


greeting
impossible.

Basic always at @ &170.

Set HIMEM using MEMORY.

10 MEMORY &5fff
20 LOAD"myasm",&6000

? HEX$(HIMEM)
-> &5fff

BASIC<HIMEM

Your asm >HIMEM



My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

cpcuser

no...
Basic start & 6000 !!!


Thanks.
Greeting

andycadley

Technically I believe you can move the lower memory bound, but only from a background ROM during it's initialisation process. There's no way to do it from a program actually started by BASIC itself though.

cpcuser


HAL6128

I don't think it's possible with the actual operating system. At least you have to rewrite the ROM.
...proudly supported Schnapps Demo, Pentomino and NQ-Music-Disc with GFX

AMSDOS

I remember this being published in AA98, but have attached it here.
* Using the old Amstrad Languages :D   * with the Firmware :P
* I also like to problem solve code in BASIC :)   * And type-in Type-Ins! :D

Home Computing Weekly Programs
Popular Computing Weekly Programs
Your Computer Programs
Updated Other Program Links on Profile Page (Update April 16/15 phew!)
Programs for Turbo Pascal 3

cpcuser


HAL6128

Quote from: AMSDOS on 10:55, 28 October 16
I remember this being published in AA98, but have attached it here.
Very interesting, indeed. Thanks.
...proudly supported Schnapps Demo, Pentomino and NQ-Music-Disc with GFX

andycadley


Bear in mind you won't be able to poke those locations for within BASIC itself, nor will your program still be in memory after you do (well technically it is, but BASIC will no longer see it). I've no idea what will happen if you move your program manually before returning, I'd not be surprised if that caused a crash. So your assembler routine might need to do the equivalent of RUN "program" to load a new version into relocated BASIC.


You might also, if you want to be properly system friendly, want to check whether the current low boundary is what you expect and adjust your expectations based on any lower RAM that has been reserved by background ROMs (though I'm not sure any do)

arnoldemu

Ok it's not impossible  :D

I tried some pokes last night and it made basic hang.

Why do you want to move BASIC?

Why not move your asm code ;)

My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

AMSDOS

@cpcuser might have another reason that I cannot think of for moving BASIC.


Back in the day I tried this for cracking, but then I got onto Lara which changed all that.


These days with Emulators and all, inspecting a program is a simple matter of pausing the Emulator. Winape makes it easier to test Assembly code by plonking disassembled code into the Assembler (but you know all that)  8)


I guess if cpcuser had code situated at &0040 and had to use BASIC, cpcuser could use the approach above (disassemble the code & move to the Assembler), change it to org &6000 and assemble, that would work I guess. I'm unsure if there dealing with a 42k program and is trying to use BASIC for some of that program. I'm unsure if it's possible moving BASIC to the extra 64k, I do recall it not working for me because I was also trying to use POKE commands to move BASIC.
* Using the old Amstrad Languages :D   * with the Firmware :P
* I also like to problem solve code in BASIC :)   * And type-in Type-Ins! :D

Home Computing Weekly Programs
Popular Computing Weekly Programs
Your Computer Programs
Updated Other Program Links on Profile Page (Update April 16/15 phew!)
Programs for Turbo Pascal 3

Powered by SMFPacks Menu Editor Mod