Login [Register]
Don't have an account? Register now to chat, post, use our tools, and much more.
This is an archived, read-only copy of the United-TI subforum , including posts and topic from May 2003 to April 2012. If you would like to discuss any of the topics in this forum, you can visit Cemetech's z80 & ez80 Assembly subforum. Some of these topics may also be directly-linked to active Cemetech topics. If you are a Cemetech member with a linked United-TI account, you can link United-TI topics here with your current Cemetech topics.

This forum is locked: you cannot post, reply to, or edit topics. Z80 & 68k Assembly => z80 & ez80 Assembly
Author Message
The Dragon Master


Member


Joined: 26 Jul 2005
Posts: 188

Posted: 03 May 2006 12:52:52 pm    Post subject:

I would like to know how many people here have used hooks before. I used them in the calculator prank I did (homescreen and some key hooks). But I am sure many of don't know what a hook is. A hook is a useful piece of code somewhere in the calculators memory that is called when certain events trigger, for example a raw key hook (using the official name...) is a piece of code called after B_CALL(getkey) is called on the ti os. There 25different types of hooks I'm aware of. If you wish to know more check ths:
http://wikiti.denglend.net/index.php?title...s:Hooks:By_Name
Back to top
Weregoose
Authentic INTJ


Super Elite (Last Title)


Joined: 25 Nov 2004
Posts: 3976

Posted: 03 May 2006 12:59:09 pm    Post subject:

I know what a hook is, but don't plan on using one any time soon.
Back to top
elfprince13
Retired


Super Elite (Last Title)


Joined: 11 Apr 2005
Posts: 3500

Posted: 03 May 2006 01:55:36 pm    Post subject:

same. I know a fair bit of the theory/terminology involved with Asm programming, but I haven't taken the time to learn the language yet.
Back to top
Liazon
title goes here


Bandwidth Hog


Joined: 01 Nov 2005
Posts: 2007

Posted: 03 May 2006 03:38:13 pm    Post subject:

No idea of what a hook is, even though I have some basic ASM knowledge.

I still don't get what a hook is. Why doesn't Sigma talk about them in ASMin28?
Back to top
bukwirm


Member


Joined: 06 Dec 2005
Posts: 233

Posted: 03 May 2006 04:22:20 pm    Post subject:

You should add the option "I have a general knowledge of hooks, but have never used them before."

Edit: Spelling


Last edited by Guest on 03 May 2006 04:43:23 pm; edited 1 time in total
Back to top
SilverCalcKnight
|_


Active Member


Joined: 15 Nov 2005
Posts: 577

Posted: 03 May 2006 04:41:10 pm    Post subject:

Isn't a hook something that is set that triggers something if certain conditions are met? Like keyhooks that Omnicalc and MirageOS use? Triggered when a key is pressed?

I know no ASM, but I know quite a bit of the terms and whatnot. Could someone tell me what "jp $FFFF" means? I think it means "go away" as an insult (see Signs you're addicted to TI if you don't get it)
Back to top
DarkerLine
ceci n'est pas une |


Super Elite (Last Title)


Joined: 04 Nov 2003
Posts: 8328

Posted: 03 May 2006 04:59:16 pm    Post subject:

jp is the jump instruction (like Goto in Basic), $FFFF is an address. The code will basically crash your calculator.

Liazon wrote:
I still don't get what a hook is.  Why doesn't Sigma talk about them in ASMin28?
[post="77971"]<{POST_SNAPBACK}>[/post]
Hooks have the very specific use of causing an effect on the TIOS after the program has finished running. There's not really a lot of things you need them for, and I believe the reason Sigma didn't talk about them is the same as the reason he didn't explain what every single 83+ rom call does.

Last edited by Guest on 03 May 2006 05:03:47 pm; edited 1 time in total
Back to top
SilverCalcKnight
|_


Active Member


Joined: 15 Nov 2005
Posts: 577

Posted: 03 May 2006 06:20:20 pm    Post subject:

Ah, I see. That joke is __that__ much funnier now. Thanks.
Ever think of putting those signs of addiction into a book? That would be one way to get public attention... even if no one reads it...
Back to top
Liazon
title goes here


Bandwidth Hog


Joined: 01 Nov 2005
Posts: 2007

Posted: 03 May 2006 09:24:23 pm    Post subject:

DarkerLine wrote:
jp is the jump instruction (like Goto in Basic), $FFFF is an address. The code will basically crash your calculator.

Liazon wrote:
I still don't get what a hook is.  Why doesn't Sigma talk about them in ASMin28?
[post="77971"]<{POST_SNAPBACK}>[/post]
Hooks have the very specific use of causing an effect on the TIOS after the program has finished running. There's not really a lot of things you need them for, and I believe the reason Sigma didn't talk about them is the same as the reason he didn't explain what every single 83+ rom call does.
[post="77983"]<{POST_SNAPBACK}>[/post]


Then how do you "USE" hooks and what outputs are generated?

I know tr1p1ea had to use parser hooks for xlib, but that's about it. I don't know how it works. Can someone enlighten me?


Last edited by Guest on 03 May 2006 09:24:59 pm; edited 1 time in total
Back to top
DarkerLine
ceci n'est pas une |


Super Elite (Last Title)


Joined: 04 Nov 2003
Posts: 8328

Posted: 04 May 2006 09:39:06 am    Post subject:

The xlib hook basically checks if the function being called is real( and has more than one argument. If so, then the hook calls xlib to parse accordingly, otherwise it hands off the parsing to the TIOS.
Back to top
The Dragon Master


Member


Joined: 26 Jul 2005
Posts: 188

Posted: 04 May 2006 01:11:03 pm    Post subject:

I originally learned of hooks back when cirrus was still up. Keyhooks were so fun. Then I learned of others. That's when I started making evil calc pranks. Hooks can easily be used for malicious and fun pranks. Especially when imbeded into regular games.
Back to top
nathanpetersenn


Newbie


Joined: 11 Apr 2012
Posts: 4

Posted: 12 Apr 2012 10:49:15 pm    Post subject:

Hey! I'm a newbie at asm but I'm pretty good at TI Basic. I wrote a math assistant program and then converted it to a app via the basicbuilder application for windows. Long story short, I have a app.

I would like to run the app when a key sequence is pressed, similar to MirageOS and its [ON]+[APPS] hook.

HOW THE HECK DO I DO THIS! I've been looking around all over the internet for hooks and how to use them and such... I have a small understanding of them but whenever I get sample code for a hook, it never works. I don't know enough about asm to debug the program, so I look for a new example. (I have a compiler and all that [I made a "Hello World!" program so I know it works]) Could anyone perhaps modify a keyhook program so that [ON]+[PROGRAM] starts an app? Idk if its useful but I'm using a 84+SE and my app name is AAAMathy.

If anything, point me in the right direction so I can make this keyhook. THANKS!
Back to top
Display posts from previous:   
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
    »
» View previous topic :: View next topic  
Page 1 of 1 » All times are GMT - 5 Hours

 

Advertisement