Path: utzoo!attcan!uunet!lll-winken!lll-tis!helios.ee.lbl.gov!pasteur!ucbvax!decwrl!hplabs!hpl-opus!hpccc!hp-sde!hpcuhb!hpcllla!hpclisp!hpclkms!ken From: ken@hpclkms.HP.COM (Kenneth Sumrall) Newsgroups: comp.sys.atari.8bit Subject: Re: help Message-ID: <1270009@hpclkms.HP.COM> Date: 28 Oct 88 17:58:32 GMT References: <4304@bsu-cs.UUCP> Organization: HP NSG/ISD California Language Lab Lines: 44 / hpclkms:comp.sys.atari.8bit / ken@hpclkms.HP.COM (Kenneth Sumrall) / 1:07 pm Oct 20, 1988 / > >> Does anyone know an answer to these to questions? >> >>2. Is there a way to binary load a file from basic using like an XIO comand? >> >Yeah. In DOS 2.0 and 2.5, you can make a USR call to an undocumented address >in the File Management System. I don't remember the address right now, but >can mail (or post) the 1 line of Atari BASIC that is required. You can also >do binary saves with a similar one line routine. Of course, it isn't very >portable across different DOS's, so use it appropriately. > >I will probably post the USR calls tommorow after I find it. (I still don't >know where any of my software is after moving four months ago :-) ) > Ok, so it took me a week to post the USR call. Also, my memory didn't serve me very well in my last posting. I don't have a binary save routine because the resident DUP routines insist on calling the full DUP package once they have saved the file. They DON'T execute a simple RTS. It would be possible to POKE an RTS in the appropriate spot before the USR call and POKE it back after the call, but it is really a hack. If you really need such a routine, I will post it, so ask if you need it. However, here's the routine to binary load in Atari DOS 2.0 (I didn't try 2.5, but there is a good chance it will work.) 10 DIM A$(4):A$="hLH_":POKE 736,71:POKE 737,22:OPEN #1,4,0,"D:FILENAME.EXT": X=USR(ADR(A$)):CLOSE #1 The characters shown above in A$ are only approximations. The real values are: ASCII VALUE(HEX) DESCRIPTION ---------------- ----------- 68 lower case 'h' 4C upper case 'L' C8 inverse upper case 'H' 15 control 'U' (it looks like a fat underscore) Hope this helps. BTW, this will execute any init or run vectors, so if there is a run vector, it may not return to the BASIC program that loaded it. Kenneth Sumrall ken%hpclkms@hplabs.hp.com ...!hplabs!hpclkms!ken