Omnimaga

Calculator Community => TI Calculators => Axe => Topic started by: ACagliano on October 05, 2010, 01:18:31 am

Title: Running External Programs
Post by: ACagliano on October 05, 2010, 01:18:31 am
Is it possible to, in a compiled Axe executable, transfer control to another asm program or compiled Axe program and then return, like you can in TI-Basic?
Title: Re: Running External Programs
Post by: Ikkerens on October 05, 2010, 01:22:42 am
Not as far as I know.
I tried using the following to do so, but I failed.
Code: [Select]
.MYTEST
1->{25+L4
prgmCOMPPRG
Output(0,1,{25+L4}>Dec)
This program would multiply {25+L4} by 2, but axe gives me a bad program error.
(COMPPRG ofc was already compiled by axe itself, but I don't think that matters much.)
Title: Re: Running External Programs
Post by: calcdude84se on October 05, 2010, 07:58:22 am
You can only include source files, not compiled programs. It does matter :P
Try it again, see if it does anything. If you really need to include a binary file, you need to use Asm(
Title: Re: Running External Programs
Post by: LordConiupiter on October 05, 2010, 10:16:58 am
is it really a posibility to do this:?
Code: [Select]
Asm(prgmWHATEVER)

It would be very handy in case it isn't possible jet!
Title: Re: Running External Programs
Post by: ACagliano on October 05, 2010, 10:23:40 am
Asm( is already used to run hex within a program. There would need to be a different command for it.
Title: Re: Running External Programs
Post by: Runer112 on October 05, 2010, 10:29:37 am
Asm( is already used to run hex within a program. There would need to be a different command for it.

If you need a different token, how about AsmPrgm? Although you could always use Asm() for this too, and just check if a program name or hex is inside the parentheses and parse it accordingly.
Title: Re: Running External Programs
Post by: LordConiupiter on October 05, 2010, 10:36:54 am
yes, when you do a normal Asm( command, the hex will never start with prgm or appv or whatever. perhaps it would be a better idea to use Asm(HEX) or Asm({PTR}r)? since otherwise the Asm routine would be much larger, cuz it would have to get the starting of the prgm on the calc, and this way it is much more flexible.