Started by zhulien, 20:11, 24 January 22
0 Members and 1 Guest are viewing this topic.
Quote from: Animalgril987 on 20:59, 24 January 22Hi zhulien.I don't think this will work. BASIC is a foreground ROM not background, and the OS will only initialise the first foreground ROM that finds, afaik.Alan
Quote from: zhulien on 20:11, 24 January 22and a good disassembly of the BASIC ROM here: http://cpctech.cpc-live.com/docs/basic.asm
Quote from: Bread80 on 13:04, 10 February 22I take it you've not seen my reversed assembled BASIC 1.1 at https://github.com/Bread80/Amstrad-CPC-BASIC-Source Run it through RASM and it'll assemble straight away.I'd like to modify it to be spread across two ROMs. Probably one for immediate mode and one for run mode. But that's a lot of work and I don't have time right now. Until then if you want to add stuff then you'll probably need to remove some stuff you don't use.As to your questions:Functions are prefixed with &ff. There's plenty of space to add more, but bear in mind they're in two blocks: one which takes a single numeric(?) parameter; another which takes any type of parameters. (Internally the single parameter ones are read by the interpreter and passed to the function. The other are read by the function itself).For statements, yes, there's very few slots available. My preference would be to use one of those slots as a prefix for a second block of extended tokens. Failing that you can always replace some tokens you never use.Re LINE INPUT: commands with multiple tokens are usually stored as multiple tokens. The LINE command will read the following token and process (or raise an error) as appropriate. Off the top of my head, SPEED INK/WRITE, GRAPHICS PEN/INK are two others that do the same.If you want to extend the language then I'd recommend starting with the source of a similar command/function. It's not too complex once you understand it but you'll need to know the routines to call to read tokens, raise errors etc.
Quote from: GUNHED on 17:04, 10 February 22To work with two BASIC ROMs you can install both of them and have one of them parked. To park a ROM you can use any good ROM management software (ROManager f.e.). Just keep only one of them active.BUT you MUST add the correct lower ROM = firmware to the corresponding BASIC ROM. This can be done with an external Lower ROM (using X-MEM, MegaFlash).
Page created in 0.139 seconds with 46 queries.