Hi all.

I want to be able to run one app from another. I know this is possible with built in apps via syscalls such as as APP_FINANCE but what about other addins?
If there isn't a syscall for this would it be possible to directly load the program into memory?
Yes, there is! Use Syscall 0x1E5B: int OpenAddin(0, 0, index, 0), where index is the index of that app on the main menu. Have a read through my C equivalent if you want to try and figure out what the three zeroes mean: https://bible.planet-casio.com/drcarlos/Syscalls/OpenAddin.c

Also note that I've only tested it on OS 3.60, so if you want to run it on a newer OS I can't guarantee anything.
Nice. What other functions from https://bible.planet-casio.com/drcarlos/Syscalls/ do I need to include to get OpenAddin to compile?
Sorry, I didn't explain that very well.
You need to use Syscall 0x1E5B. Here is an example program which should open the 7th addin on the menu:

Code:

int OpenAddin(int zero1, int zero2, unsigned short index, int zero3);
__asm__(".text; .align 2; .global _OpenAddin; "
               "_OpenAddin: mov.l sc_addr, r2; mov.l OpenAddin_Number, r0; "
               "jmp @r2; nop; "
               "OpenAddin_Number: .long 0x1e5b; "
               "sc_addr: .long 0x80020070");

int main(void) {
  OpenAddin(0, 0, 6, 0); // Index starts at 0, so 7th item is 6
  return 0;
}


If you want to investigate the internal workings of this function, you can check out https://bible.planet-casio.com/drcarlos/Syscalls/OpenAddin.c
The referenced functions are all either located in https://bible.planet-casio.com/drcarlos/Syscalls/ or will require using a disassembler to investigate personally.

Let me know if you have any issues.
  
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.

» Go to Registration page
Page 1 of 1
» All times are UTC - 5 Hours
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

 

Advertisement