Re: TIB: TI-92+ BASIC questions & GraphLink comments


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

Re: TIB: TI-92+ BASIC questions & GraphLink comments




On 8/14/98 2:12 PM Doug Burkett from dburkett@infinet.com wrote:

>I posted these questions to the TI discussion group & didn't get an =
>answer. I'm hoping someone here can help me out.
>
>As a warm-up project for programming on the TI92 with the Plus module, =
>I'm writing a user shell for the regression functions built into the the =
>92. I have these questions that I haven't been able to answer from =
>reading the manual or news search. I'm using the GraphLink+ & it's beta =
>software.
>
>1. Are 'true' and 'false' built-in system variables? They aren't listed =
>in the manual, but they act like it.

No, they are boolean values. On an TI-81:
:If 1
:Disp 5

The calc would display 5. However on a 92 it would need to be:
:If true
:Disp 5

Meaning true and false are values like 5 or 6. They are just reserved 
names like RclPic. If you view the var-link screen showing system 
variables you'll notice they are not there.

>2. Is there a way to directly store to a data variable element? e.g., if =
>the variable name is 'cdesc', and it has 3 rows and 10 columns. I can =
>read any element with (cdesc[column])[row], but this syntax doesn't work =
>to store an element. I've had to decompose the data variable to lists, =
>store to a list element, and rebuild the data variable. This seems a =
>kludge.

The Blessed Lords of TI (tm) made data variables to annoy with quick 
access and annoying access routines. Avoid the accursed structures when 
ever possible and use matrixes or lists that hold strings that contain 
lists.

>3. Is there any way to send program results to the home screen 'ans' =
>area?

Haven't found a way yet, try a Func if possible.

>4. How can I programmatically develop a list of variables in a folder?

The only way I know. Not optimized at all.

director(f)
Prgm
local a1,a2,a3,a4,a5,a6,a7,a8,c
f&"\"->f
{}->lis
for a1,97,255
char(a1)->c
try
if gettype(#c)‚"NONE"
augment(lis,{c})->lis
else
clrerr
endtry
for a2,49,255
char(a1)&char(a2)->c
try
if gettype(#c)‚"NONE"
augment(lis,{c})->lis
else
clrerr
endtry
for a3,49,255
char(a1)&char(a2)&char(a3)->c
try
if gettype(#c)‚"NONE"
augment(lis,{c})->lis
else
clrerr
endtry
for a4,49,255
char(a1)&char(a2)&char(a3)&char(a4)->c
try
if gettype(#c)‚"NONE"
augment(lis,{c})->lis
else
clrerr
endtry
for a5,49,255
char(a1)&char(a2)&char(a3)&char(a4)&char(a5)->c
try
if gettype(#c)‚"NONE"
augment(lis,{c})->lis
else
clrerr
endtry
for a6,49,255
char(a1)&char(a2)&char(a3)&char(a4)&char(a5)&char(a6)->c
try
if gettype(#c)‚"NONE"
augment(lis,{c})->lis
else
clrerr
endtry
for a7,49,255
char(a1)&char(a2)&char(a3)&char(a4)&char(a5)&char(a6)&char(a7)->c
try
if gettype(#c)‚"NONE"
augment(lis,{c})->lis
else
clrerr
endtry
for a8,49,255
char(a1)&char(a2)&char(a3)&char(a4)&char(a5)&char(a6)&char(a7)&char(a8)->c
try
if gettype(#c)‚"NONE"
augment(lis,{c})->lis
else
clrerr
endtry
endfor
endfor
endfor
endfor
endfor
endfor
endfor
endfor
endprgm

Note that the program will take a long time to execute. To call the 
function use director("foldname") When the program is done lis will 
contain all variables in the folder you wanted.

The inner loop takes about 13 secs so 206*206*206*206*206*206*206*206 -> 
3242931408352297216 iterations * 13  -> 42150108308579863808 seconds to 
execute or ~1.33594 * 10^12 years to finish.

If you remove the uppercase characters and others that are not allowed in 
a name you could cut down the running time. Of course you might prefer to 
scan only a single depth or 2 if you can wait ~45 minutes.
>5. How can I programmatically change the folder?
Look at setFold(var) and getFold().
>6. I can graph results from my program, but the graph screen menu tabs =
>aren't active. I would like to let the user zoom, find data point =
>coordinates, etc, from within my program. Is this possible?

Try Trace and the Zoom commands (Look them up in the manual or catalog) 
Just use ToolBar to let the user choose what commands to use. (16*16 pics 
can be used instead of the string for name of an item or title)
>I have these comments/suggestions on the GraphLink+ software so far:
[snip]

I don't know what the Windoze's interface will be like. However, on the 
Mac side, the people I've talked from TI said the interface will be 
similar to the TI-86's.

>I will eventually be programming in 68K assembler, and I am puzzled by =
>all this shell jazz. Why can't I just 1) edit the assembly program in my =
>favorite editor, 2) cross-compile on the PC, and 3) link it to the 92+ =
>as an assembly program? And, to program in assembler at all, I need to =
>know the internal data structure formats, addresses of internal =
>functions, format of the LCD buffer RAM, etc. Where do I find all this? =
>I am experienced in Mot assembler programming, but that's only part of =
>the puzzle.

TI has not released info on the 92+ yet. Try looking at www.ticalc.org in 
the texts section under the 92 and join the 92 Assembly mailing list.

Michael Van Der Kolk
mikev@iserv.net
http://www.iserv.net/~mikev