Path: utzoo!attcan!uunet!mcsun!unido!sbsvax!roeder From: roeder@robin.cs.uni-sb.de (Edgar &) Newsgroups: comp.sys.atari.st Subject: Re: How can I find current DTA address w/o using TRAP #1? Message-ID: Date: 1 Oct 90 14:33:14 GMT References: <5429@bdt.UUCP> Sender: news@sbsvax.cs.uni-sb.de Organization: Universitaet des Saarlandes, Saarbruecken (W-Germany) Lines: 20 In-reply-to: ADAM_TILGHMAN@bdt.UUCP's message of 29 Sep 90 20:59:53 GMT In article <5429@bdt.UUCP> ADAM_TILGHMAN@bdt.UUCP writes: > I can't find the current DTA address; is there any way that I can > do this while processing a TRAP #1? The current process' DTA address is recorded in the basepage which can be derived from the act_pd system variable (this in turn is recorded in the sys_base (the first few bytes after the ROM-start) for TOS versions >= 1.2). BTW.: You should be able to call trap #1 recursively if you do it inline (for example in assembler) and avoid library routines that save the return address in a static memory location. The shell that i am using (Master) calls trap #1 very often in this way (even from inside a bios-trap --- but that's another story). Hope this helps! - Edgar