Omnimaga

Calculator Community => TI Calculators => Axe => Topic started by: souvik1997 on June 20, 2010, 10:07:27 am

Title: Axe and OFFSCRPT
Post by: souvik1997 on June 20, 2010, 10:07:27 am
I have two questions

How does OFFSCRPT work?

How would I use Axe to modify OFFSCRPT?
Title: Re: Axe and OFFSCRPT
Post by: DJ Omnimaga on June 20, 2010, 11:22:18 am
What is OFFSCRPT? Could you elaborate?
Title: Re: Axe and OFFSCRPT
Post by: Silver Shadow on June 20, 2010, 01:40:35 pm
OFFSCRPT is an appvar used by the OS to launch a program/app at startup. DCS uses it too. I have no idea about how it works though.
Title: Re: Axe and OFFSCRPT
Post by: DJ Omnimaga on June 20, 2010, 02:49:34 pm
Aaah ok. I never heard of it. I never saw it on my calc before.
Title: Re: Axe and OFFSCRPT
Post by: Galandros on June 20, 2010, 04:47:10 pm
I have two questions

How does OFFSCRPT work?

How would I use Axe to modify OFFSCRPT?
I do not know where you can find documentation of OFFSCRPT but unless someone already knows and tells you, you will have to disassemble some code.
Also try a search on UnitedTI forum because I think I read a topic about it but I don't think it had details of the appvar content.
I don't know exactly how it works but it can have vectors (address that directs to code of the TIOS) or some assembly code (doubt it).

Axe has or will have commands to modify appsvars so yes, you can use Axe Parser to edit it if it is in RAM. Or if it is archived, try to unarchive with some other command. (check Axe documentation)
Make sure you know what you are doing because it may crash your calculator on startup.

Aaah ok. I never heard of it. I never saw it on my calc before.
I think I had it on my calc because I used a APPS from TI that could edit your startup.
Title: Re: Axe and OFFSCRPT
Post by: souvik1997 on June 20, 2010, 07:19:27 pm
Ok. I will check out the exisring OFFSCRPT I have on my calculator.
Title: Re: Axe and OFFSCRPT
Post by: ACagliano on June 20, 2010, 11:53:24 pm
if only the calc could be hacked so that the OS could run OFFSCRPT from archive (cuz, if you archive it, the calc does not run the specified prgm on startup) and if OFFSCRPT could be made to check if the specified prgm is archived and if it is, unarchive it. Thats what i hate: progs set to run on startup must be in RAM, and if you crash, OFFSCRPT is reset.
Title: Re: Axe and OFFSCRPT
Post by: DJ Omnimaga on June 20, 2010, 11:54:31 pm
Btw I don't really remember having that on my calc before, even when I was using Startup. Was it added in later versions of Startup (after 2002)?
Title: Re: Axe and OFFSCRPT
Post by: Builderboy on June 21, 2010, 01:17:16 am
Hmmm so the OS runs ONSTRPT and OFFSCRPT just like programs?  Interesting...  It wouldd be an interesting task to modify OFFSCRPT to do whatever you want...  i shall run some tests...
Title: Re: Axe and OFFSCRPT
Post by: souvik1997 on June 21, 2010, 09:24:50 am
Archiving OFFSCRPT would be a very bad thing. People could make virus programs to shut off your calculator when you turn it on, and it would be very hard to delete OFFSCRPT.
Title: Re: Axe and OFFSCRPT
Post by: FinaleTI on June 21, 2010, 10:08:17 am
if only the calc could be hacked so that the OS could run OFFSCRPT from archive (cuz, if you archive it, the calc does not run the specified prgm on startup) and if OFFSCRPT could be made to check if the specified prgm is archived and if it is, unarchive it. Thats what i hate: progs set to run on startup must be in RAM, and if you crash, OFFSCRPT is reset.

But if you use CalcUtil, even the start program can be run if it's archived.
Title: Re: Axe and OFFSCRPT
Post by: souvik1997 on June 21, 2010, 11:04:43 am
In case anyone wants to know, I have found out how OFFSCRPT works with the help of KermMartian, Calcsys's disassembler, DoorsCS7, and TI's Startup App.
The original post was at http://www.cemetech.net/forum/viewtopic.php?t=4636&highlight=
ASM code:
Code: [Select]
OffScrptCode:
.relocate $8001
  bit 4,(IY+apdFlags)
  ret nz
  ld hl,MyAppName
  rst 20h
  bcall(_FindApp)
  ret c
  dec a      ;this is on page 2
  ld hl,MyGetKeyHook
  bcall(_EnablegetKeyHook)
  ;set 0,(iy+34h)
  ret
MyAppName:
  .db AppObj,"DoorsCS7"
  ret
.endrelocate
OffScrptCodeEnd:
Basically it installs a getkey hook when the calculator turns off. The hook causes the calculator to launch the DCS7 app when the calculator is powering up. There is also an appvar called ONSCRPT, which does the same thing as OFFSCRPT except it is executed when powering up. Using ONSCRPT eliminates the need for a getkey hook, but it is unstable. ;D
Title: Re: Axe and OFFSCRPT
Post by: DJ Omnimaga on June 21, 2010, 12:27:36 pm
interesting
Title: Re: Axe and OFFSCRPT
Post by: Galandros on June 21, 2010, 12:53:36 pm
Btw I don't really remember having that on my calc before, even when I was using Startup. Was it added in later versions of Startup (after 2002)?
Maybe I am confusing with ONSCRPT or even some other APPS.

Nice to see some info about that. I think you should start a topic on WikiTI in the section of TIOS for TI-83+.
Title: Re: Axe and OFFSCRPT
Post by: souvik1997 on June 21, 2010, 01:50:06 pm
WikiTi article created:
http://wikiti.brandonw.net/index.php?title=Offscrpt
Title: Re: Axe and OFFSCRPT
Post by: DJ Omnimaga on June 21, 2010, 02:13:36 pm
Btw is that program visible in menus or hidden? I swear I never saw it before with Startup. Maybe it's my memory playing me tricks, though. I last tried Startup in 2002.
Title: Re: Axe and OFFSCRPT
Post by: ztrumpet on June 21, 2010, 02:14:26 pm
It's an AppVar. :)
Title: Re: Axe and OFFSCRPT
Post by: DJ Omnimaga on June 21, 2010, 02:16:01 pm
aaah ok. Strange, I don't remember it either x.x. I swear it was more a different name. Oh well.
Title: Re: Axe and OFFSCRPT
Post by: Galandros on June 25, 2010, 07:22:25 am
WikiTi article created:
http://wikiti.brandonw.net/index.php?title=Offscrpt
Good work. Thumbs up. ;)
Title: Re: Axe and OFFSCRPT
Post by: ACagliano on August 04, 2010, 06:49:02 pm
if only the calc could be hacked so that the OS could run OFFSCRPT from archive (cuz, if you archive it, the calc does not run the specified prgm on startup) and if OFFSCRPT could be made to check if the specified prgm is archived and if it is, unarchive it. Thats what i hate: progs set to run on startup must be in RAM, and if you crash, OFFSCRPT is reset.

But if you use CalcUtil, even the start program can be run if it's archived.

No, IIrc, you cannot. It never did for me.
Title: Re: Axe and OFFSCRPT
Post by: FinaleTI on August 09, 2010, 08:14:26 am
On my calc, I have prgmPROGLIST archived and prgmLOCK archived.
prgmPROGLIST calls prgmLOCK as the start-up program. Whenever I start up my calc, prgmLOCK is run.