RUN BASIC FILE

ZXNet echo conference «code.zx»

From Aleksandr Majorov To Vyacheslav Kalinin 3 April 2000

Khayushki, Vyacheslav! Somehow on 03/24/00 at approximately 21:44:00 someone Vyacheslav Kalinin reported (a/o) for All that "RUN BASIC FILE" [ ] VK> I need a program for launching BASIC files as soon as possible, I have it VK> its own but it works strangely, that is, when I launch it VK> after assembling from the storm, it launches the file for me if VK> launch it from a real commander or from a bestviewer, then I’ll launch it too Be specific. What kind of program is it, what principle does it work on, etc... VK> downloads files, but if you run from BASIC or TR-DOS, then it will VK> seems to start loading something, and then abandons it. Some kind of glitch with the stack, BASIC system variables, and the like. I do it like this: LD A,#C9: LD (#5CC2),A ;SELECT CURRENT DISK DRIVE ;in principle, you don’t have to worry about it, ;but in MMD I can destroy these variables. LD A,(#5D16): AND 3: PUSH AF OR #3C: LD (#5D16),A: POP AF LD (23800),A: LD (23801),A LD (23833),A ;attention!!! Be careful in this place! ;here I’m just restoring some ;system variables that are active ;I use it “for myself”. ;obviously when activating the system in the addresses ; PROG_49+1, PROG_ST+1, PROG_2+1 ;original values are written ;of these variables.PROG_49 LD HL,#2121: LD (#5C09),HL PROG_ST LD HL,#2121 LD (IY+1),L: LD (IY+48),H PROG_2 LD HL,#2121: LD (#5C38),HL LD (IY+14),#38 ;I don’t remember where I got this from, ;but this option works quite well. ;Actually I'm doing CLEAR 65367, something ;more to install BASIC, and after that ;executing RAND USR 15619: REM: RUN "???" LD HL,#15AF: LD DE,(#5C4F) LD B,0: LD C,H: LDIR LD DE,(#5C53) LD DE,23867 LD HL,RUN_COM LD C,17: LDI: LD (#5C5D),DE LDIR LD HL,#5FFF: LD (#5CB2),HL LD H,L: LD (#5CB4),HL LD HL,#FF57: LD (#5CB2),HL INC HL: LD SP,HL LD (IY+0),H LD HL,#3E00: PUSH HL LD HL,#1303: PUSH HL LD (#5C3D),SP LD HL,#1B76: PUSH HL LD HL,#2758: EXX EI: JP #3D03 ; :REM:RUN"??"ENT RUN_COM DB #80,58,234,58,247,34 TESTSP DB " ",34,32,13,#80 ;and here we write ^^^^^^^^^ ;name of the program to run. ;And we write all 8 characters, i.e. ;if the name is shorter, then all others ; We make characters with spaces. Well that's it *MAS* with a sledgehammer