A92: Re: Thanks for the help...now..... :-)


[Prev][Next][Index][Thread]

A92: Re: Thanks for the help...now..... :-)




>Great, I found soundlib (and felt stupid that I hadn't before :-)
>Now, how do I receive parameters passed to a program?  i.e. what do I do in
>the Fargo source to get x and y out of program(x,y)?  I'd think they'd be
>on the stack, but I'm not sure.
>--Cliff Biffle


This isn't easy, but can be done.  To get parameters, you need to change the
"TI-BASIC" portion of the Fargo Program.  In order for Fargo to work, David
simply put a dud BASIC program (Prgm:EndPrgm).  You need to modify it to
accept (in your case two) some parameters.  Then the TI-OS will create a
local folder and create the variables with the names specified.  Using the
folder and file handles, you can then get at the variables, verify the correct
data type and then use them.

I would greatly suggest that you look at the Fargo Program TESTFUNC.ASM.  It's
included with the Fargo II distribution.  This program takes a String and then
returns a string with two copies of the original string.  This program is the
starting point for really interacting with BASIC and ASM.

There is another way to "get parameters" and that involves writing a wrapper
program in BASIC.  The BASIC program gets the parameters and stores them as
variables in a particular folder (or whatever works).  Then your program looks
for those variables.  In either case, you will have to traverse the folder/file
structure of the TI-OS.

Read up on Files.TXT.  You will need extensive knowledge of files and formats
of expressions, programs, etc.

Have fun, :)

====
Aaron Hill (Redmond, WA)
E-Mail: SeracOhw24@msn.com
IRC-Nick: Serac (EF-Net) (was SeracOhw)




Follow-Ups: