G35@DHDURZ1.BITNET (11/30/87)
Someone mentioned that the NoFastMem command doesn't work if the program you want to start has to be booted i.e. after a reset. This small assembler program shold solve these problems. Please note: it works only on 500 and 2000 machines, as it uses direct ROM-calls and you have to switch off/on to get your fastmem back, cntl-A-A would have no effect. I know that this is not the way to code programs on the Amiga, the program is just a hack, but works fine (for me). The program is very simple: the startup-code calls a routine which passes in a4 the length of the $c00000-mem attached. The program just sets a4 to NULL and jumps into the startup routine. ------------------------ cut here --------------------------- move.l 264(a2),a4 ; function = Output() moveq #12,d0 ; every cli-command does this, no idea why jsr (a5) ; call Dos-function move.l #txt,d2 ; address of text move.l #txtend-txt,d3 ; length of text move.l -24(a2),a4 ; function = Write() moveq #12,d0 ; ???? (as above, seems to be important) jsr (a5) ; call Dos-function wait btst #6,$bfe001 ; test left mouse button bne wait ; wait until pressed ; the next section is copied from the original reset routine ; (reset starts at $fc00d2) lea.l $040000,a7 ; stack-pointer lea.l $dff000,a4 ; startaddress of customchips move.w #$7fff,d0 move.w d0,154(a4) ; disable interrupts move.w d0,156(a4) ; disable interrupt request move.w d0,150(a4) ; disable DMA move.w #512,256(a4) ; bitplane control move.w #0,272(a4) ; ??? move.w #$444,384(a4) ; set color 0 (dark grey) ; some registers have to be set to a specified value: lea.l $400,a6 ; a6 = execbase suba.w #$fd8a,a6 move.l #0,a4 ; no fast mem move.l #$ffffffff,d6 ; d6 holds the error code, -1= no guru jmp $fc0208 ; reset and boot text dc.b 'Insert disk & press left mouse button',10 textend equ * ------------------------------------------------------------------- BTW I coudn't download this program to host, i had to type it in, so there might be a bug somewere, just tell me if doesn't work... -Werner Werner Guenther (g35@dhdurz1.bitnet)