* WalrusIRC

You need to have 5 posts and not be part of restricted usergroups in order to use the WalrusIRC embedded shoutbox. However, you can also access our IRC channel called #CodeWalrus via EFnet.

Author Topic: Axe Interrupts stop working  (Read 2438 times)

0 Members and 1 Guest are viewing this topic.

Offline p2

  • CodeWalrus Staff
  • Super User
  • Moderator
  • CodeWalrus Supporter
  • *
  • Join Date: Aug 2016
  • Location: Germany
  • Posts: 2293
  • Post Rating Ratio: +9/-0
  • *Wubba lubba dub dub*
    • KaliPhobos
  • Gender: Male
Axe Interrupts stop working
« on: August 17, 2016, 09:12:49 am »
I had the following code:

(click to show/hide)
It ended with B being set to 3 but X still counting... (Interrupt stopped working)
Then I modified it like this:
(click to show/hide)
Like this it was working (both counting up)..

Then thanks to c4ooo I found another way it was working:
(click to show/hide)
But why did the interrupt stop working in the first place? BEcause of the "Output" command or something?

Edit: Fixed massive use of wrong var names sorry >.<
« Last Edit: August 17, 2016, 09:33:51 am by p2 »


  • Calculators owned: ti-83+, ti-84+, ti-84+, ti-84+se, ti-84+se(te), ti-nsphire, ti-nsphire CX-CAS, ti-voyage, ti-voyage, Who reads this list anyways...?
Anyway war sucks. Just bring us your food instead of missiles  :P ~ DJ Omnimaga (11.10.2016 20:21:48)
if you cant get a jframe set up, draw stuff to it, and receive input, i can only imagine how horrible your game code is _._   ~ c4ooo (14.11.2016 22:44:07)
If they pull a Harambe on me tell my family I love them ~ u/Pwntear37d (AssangeWatch /r/)
make Walrii great again ~ DJ Omnimaga (28.11.2016 23:01:31)
God invented the pc, satan the smartphone I guess ~ p4nix (16.02.2017 22:51:49)

Offline c4ooo

  • Super User
  • CW Contest II Winner
  • *
  • Join Date: Aug 2015
  • Location: 127.0.0.1
  • Posts: 1012
  • Post Rating Ratio: +12/-4
  • Advanced forumer
  • Gender: Male
Re: Axe Interrupts stop working
« Reply #1 on: August 17, 2016, 09:31:34 am »
Here's some working [and optimized] code:
Code: [Select]
.TRY03AXE
1->X->Y
Fix 5
fnInt(INTERRUPT,0)
Repeat getKey(15)
X++
ClrDraw
Text(0,,X>Dec)       .double comma is *Not* a typo
Text(0,9,Y>Dec)
DispGraph
End
LnReg^r
Return

Lbl INTERRUPT
Y+1->Y
Return
It should work. Anyways, what are you trying to accomplish here, if i may ask? :)

Offline p2

  • CodeWalrus Staff
  • Super User
  • Moderator
  • CodeWalrus Supporter
  • *
  • Join Date: Aug 2016
  • Location: Germany
  • Posts: 2293
  • Post Rating Ratio: +9/-0
  • *Wubba lubba dub dub*
    • KaliPhobos
  • Gender: Male
Re: Axe Interrupts stop working
« Reply #2 on: August 17, 2016, 09:35:33 am »
Just comparing the speed of the main loop to the interrupt (to see how fast the speed settings 0, 2, 4, 6 are ^^)

Edit:
Just tried jour code.
It works but the interrupt counter is like 10 times faster now O.o
Then the interrupt counter (Y) reaches 1000, the counter in the main loop (X) is only at 85... O.o
And was it the Output( causing the problem?
*Edit of Edit: Actually the interrupt counter is like 2-3x faster while the main loop is muuuuch slower >.<
« Last Edit: August 17, 2016, 09:48:40 am by p2 »
  • Calculators owned: ti-83+, ti-84+, ti-84+, ti-84+se, ti-84+se(te), ti-nsphire, ti-nsphire CX-CAS, ti-voyage, ti-voyage, Who reads this list anyways...?
Anyway war sucks. Just bring us your food instead of missiles  :P ~ DJ Omnimaga (11.10.2016 20:21:48)
if you cant get a jframe set up, draw stuff to it, and receive input, i can only imagine how horrible your game code is _._   ~ c4ooo (14.11.2016 22:44:07)
If they pull a Harambe on me tell my family I love them ~ u/Pwntear37d (AssangeWatch /r/)
make Walrii great again ~ DJ Omnimaga (28.11.2016 23:01:31)
God invented the pc, satan the smartphone I guess ~ p4nix (16.02.2017 22:51:49)

Offline c4ooo

  • Super User
  • CW Contest II Winner
  • *
  • Join Date: Aug 2015
  • Location: 127.0.0.1
  • Posts: 1012
  • Post Rating Ratio: +12/-4
  • Advanced forumer
  • Gender: Male
Re: Axe Interrupts stop working
« Reply #3 on: August 17, 2016, 09:47:59 am »
For me, at speed "0", when the interrupt counter reaches 1000, the loop counter is at around 150. Well using graph screen is slower then home screen i guess;  also my interrupt code is about a dozen T-states faster then yours.

Offline p2

  • CodeWalrus Staff
  • Super User
  • Moderator
  • CodeWalrus Supporter
  • *
  • Join Date: Aug 2016
  • Location: Germany
  • Posts: 2293
  • Post Rating Ratio: +9/-0
  • *Wubba lubba dub dub*
    • KaliPhobos
  • Gender: Male
Re: Axe Interrupts stop working
« Reply #4 on: August 17, 2016, 09:55:41 am »
When adding "Full" at the top of the code, I get 150 for X, too (with Y>999). But only the main loop speeds up, the interrupt remains the same speed it seems ^^
what calc are you using? :)
  • Calculators owned: ti-83+, ti-84+, ti-84+, ti-84+se, ti-84+se(te), ti-nsphire, ti-nsphire CX-CAS, ti-voyage, ti-voyage, Who reads this list anyways...?
Anyway war sucks. Just bring us your food instead of missiles  :P ~ DJ Omnimaga (11.10.2016 20:21:48)
if you cant get a jframe set up, draw stuff to it, and receive input, i can only imagine how horrible your game code is _._   ~ c4ooo (14.11.2016 22:44:07)
If they pull a Harambe on me tell my family I love them ~ u/Pwntear37d (AssangeWatch /r/)
make Walrii great again ~ DJ Omnimaga (28.11.2016 23:01:31)
God invented the pc, satan the smartphone I guess ~ p4nix (16.02.2017 22:51:49)

Offline c4ooo

  • Super User
  • CW Contest II Winner
  • *
  • Join Date: Aug 2015
  • Location: 127.0.0.1
  • Posts: 1012
  • Post Rating Ratio: +12/-4
  • Advanced forumer
  • Gender: Male
Re: Axe Interrupts stop working
« Reply #5 on: August 17, 2016, 09:57:16 am »
TI-84 plus. Also i dont use Full.

Offline p2

  • CodeWalrus Staff
  • Super User
  • Moderator
  • CodeWalrus Supporter
  • *
  • Join Date: Aug 2016
  • Location: Germany
  • Posts: 2293
  • Post Rating Ratio: +9/-0
  • *Wubba lubba dub dub*
    • KaliPhobos
  • Gender: Male
Re: Axe Interrupts stop working
« Reply #6 on: August 17, 2016, 10:00:02 am »
Is there any function to give you the exact time an interrupt at current speed would be triggered per second...? would be interesting >.>


Edit: quote from omnimaga:
The speeds for the interrupts are as follow (according to Hot Dog):

Speed // 83+ // 84+
0 // 560 Hz // 512 Hz
2 // 248 Hz // 228 Hz
4 // 170 Hz // 146 Hz
6 // 118 Hz // 108 Hz


And shouldn't there be a warning like "Dont use Output( command it will break your interrupts" or something...?
(As far as I understand it that has been the problem?)
« Last Edit: August 17, 2016, 10:20:26 am by p2 »
  • Calculators owned: ti-83+, ti-84+, ti-84+, ti-84+se, ti-84+se(te), ti-nsphire, ti-nsphire CX-CAS, ti-voyage, ti-voyage, Who reads this list anyways...?
Anyway war sucks. Just bring us your food instead of missiles  :P ~ DJ Omnimaga (11.10.2016 20:21:48)
if you cant get a jframe set up, draw stuff to it, and receive input, i can only imagine how horrible your game code is _._   ~ c4ooo (14.11.2016 22:44:07)
If they pull a Harambe on me tell my family I love them ~ u/Pwntear37d (AssangeWatch /r/)
make Walrii great again ~ DJ Omnimaga (28.11.2016 23:01:31)
God invented the pc, satan the smartphone I guess ~ p4nix (16.02.2017 22:51:49)

Offline E37

  • Full User
  • Join Date: Jul 2016
  • Location: Lihilzard Empire
  • Posts: 232
  • Post Rating Ratio: +10/-0
  • I own 2 game consoles, a ti-83 and a ti-84!
    • E37
Re: Axe Interrupts stop working
« Reply #7 on: August 17, 2016, 07:52:25 pm »
Is there any function to give you the exact time an interrupt at current speed would be triggered per second...? would be interesting >.>


Edit: quote from omnimaga:
The speeds for the interrupts are as follow (according to Hot Dog):

Speed // 83+ // 84+
0 // 560 Hz // 512 Hz
2 // 248 Hz // 228 Hz
4 // 170 Hz // 146 Hz
6 // 118 Hz // 108 Hz


And shouldn't there be a warning like "Dont use Output( command it will break your interrupts" or something...?
(As far as I understand it that has been the problem?)
I see what you mean.
The command output sets the position of the cursor, but then is interrupted by the interrupt which moves the cursor.
When it returns back to the first output it continues where the cursor is and displays the text.
Output(x,y,exp)
is the same as :Output(x,y):Disp exp
  • Consoles, mobile devices and vintage computers owned: Ti83,Ti84!
I've never finished a project, there is always a way to improve!
What's my calc's name? Convert $37 to decimal. Look up that element in the periodic table. Then take the abbreviation of that element and you have it!
Look! A slime!    <(^.^)>

Offline p2

  • CodeWalrus Staff
  • Super User
  • Moderator
  • CodeWalrus Supporter
  • *
  • Join Date: Aug 2016
  • Location: Germany
  • Posts: 2293
  • Post Rating Ratio: +9/-0
  • *Wubba lubba dub dub*
    • KaliPhobos
  • Gender: Male
Re: Axe Interrupts stop working
« Reply #8 on: September 27, 2016, 09:11:00 am »
so if I just wanted to display something like a counter (always overwrite the last text at the same position) it'd be faster to once to Output(x,y) and then use nothing but a DISP inside a loop? :)
  • Calculators owned: ti-83+, ti-84+, ti-84+, ti-84+se, ti-84+se(te), ti-nsphire, ti-nsphire CX-CAS, ti-voyage, ti-voyage, Who reads this list anyways...?
Anyway war sucks. Just bring us your food instead of missiles  :P ~ DJ Omnimaga (11.10.2016 20:21:48)
if you cant get a jframe set up, draw stuff to it, and receive input, i can only imagine how horrible your game code is _._   ~ c4ooo (14.11.2016 22:44:07)
If they pull a Harambe on me tell my family I love them ~ u/Pwntear37d (AssangeWatch /r/)
make Walrii great again ~ DJ Omnimaga (28.11.2016 23:01:31)
God invented the pc, satan the smartphone I guess ~ p4nix (16.02.2017 22:51:49)

Offline E37

  • Full User
  • Join Date: Jul 2016
  • Location: Lihilzard Empire
  • Posts: 232
  • Post Rating Ratio: +10/-0
  • I own 2 game consoles, a ti-83 and a ti-84!
    • E37
Re: Axe Interrupts stop working
« Reply #9 on: September 27, 2016, 03:26:01 pm »
so if I just wanted to display something like a counter (always overwrite the last text at the same position) it'd be faster to once to Output(x,y) and then use nothing but a DISP inside a loop? :)
No you can't. Disp updates the cursor position. There is a way you can do it but you won't like it as much.
You can simply disable interrupts before the output and enable them after. Thankfully the disable and enable commands take only one byte each.
(what kind of project are you using interrupts on the home screen anyway? I have never heard of interrupts being used for anything other than greyscale)
  • Consoles, mobile devices and vintage computers owned: Ti83,Ti84!
I've never finished a project, there is always a way to improve!
What's my calc's name? Convert $37 to decimal. Look up that element in the periodic table. Then take the abbreviation of that element and you have it!
Look! A slime!    <(^.^)>

Offline p2

  • CodeWalrus Staff
  • Super User
  • Moderator
  • CodeWalrus Supporter
  • *
  • Join Date: Aug 2016
  • Location: Germany
  • Posts: 2293
  • Post Rating Ratio: +9/-0
  • *Wubba lubba dub dub*
    • KaliPhobos
  • Gender: Male
Re: Axe Interrupts stop working
« Reply #10 on: September 27, 2016, 03:28:17 pm »
I'm not using it for any seroius project, just curious to learn some more about axe xD
aaaand used interrupt to display a counter since I'm stupid and I just wanted to see how fast these interrupts really are :3
  • Calculators owned: ti-83+, ti-84+, ti-84+, ti-84+se, ti-84+se(te), ti-nsphire, ti-nsphire CX-CAS, ti-voyage, ti-voyage, Who reads this list anyways...?
Anyway war sucks. Just bring us your food instead of missiles  :P ~ DJ Omnimaga (11.10.2016 20:21:48)
if you cant get a jframe set up, draw stuff to it, and receive input, i can only imagine how horrible your game code is _._   ~ c4ooo (14.11.2016 22:44:07)
If they pull a Harambe on me tell my family I love them ~ u/Pwntear37d (AssangeWatch /r/)
make Walrii great again ~ DJ Omnimaga (28.11.2016 23:01:31)
God invented the pc, satan the smartphone I guess ~ p4nix (16.02.2017 22:51:49)

Offline E37

  • Full User
  • Join Date: Jul 2016
  • Location: Lihilzard Empire
  • Posts: 232
  • Post Rating Ratio: +10/-0
  • I own 2 game consoles, a ti-83 and a ti-84!
    • E37
Re: Axe Interrupts stop working
« Reply #11 on: September 27, 2016, 03:33:43 pm »
I'm not using it for any seroius project, just curious to learn some more about axe xD
aaaand used interrupt to display a counter since I'm stupid and I just wanted to see how fast these interrupts really are :3
That's the best way to learn!
I hardly ever use interrupts. Unless you are doing a serious graphics projects, or need the most beautiful greyscale, it is best to leave interrupts alone.
More often than not, interrupts are not needed, simply displaying at the end of a loop is sufficient to create acceptable greyscale.
(plus it destroys L2 which is the biggest of all the free ram areas)
  • Consoles, mobile devices and vintage computers owned: Ti83,Ti84!
I've never finished a project, there is always a way to improve!
What's my calc's name? Convert $37 to decimal. Look up that element in the periodic table. Then take the abbreviation of that element and you have it!
Look! A slime!    <(^.^)>

Offline TheMachine02

  • Full User
  • Join Date: Dec 2014
  • Location:
  • Posts: 356
  • Post Rating Ratio: +14/-0
Re: Axe Interrupts stop working
« Reply #12 on: September 27, 2016, 03:36:56 pm »
(plus it destroys L2 which is the biggest of all the free ram areas)

L1 is the biggest area  :P And it only destroy about 256 bytes of L2 (if I remember well) , so you can still use it.

Offline E37

  • Full User
  • Join Date: Jul 2016
  • Location: Lihilzard Empire
  • Posts: 232
  • Post Rating Ratio: +10/-0
  • I own 2 game consoles, a ti-83 and a ti-84!
    • E37
Re: Axe Interrupts stop working
« Reply #13 on: September 27, 2016, 03:38:51 pm »
(plus it destroys L2 which is the biggest of all the free ram areas)

L1 is the biggest area  :P And it only destroy about 256 bytes of L2 (if I remember well) , so you can still use it.
No, that's untrue. L1 is the same size as L3 and L6.
L2 is the biggest at 800+ bytes.
Axe only lists L2 at 512 bytes, but the actual usable memory extends to beyond 800 (I don't remember the exact number)
  • Consoles, mobile devices and vintage computers owned: Ti83,Ti84!
I've never finished a project, there is always a way to improve!
What's my calc's name? Convert $37 to decimal. Look up that element in the periodic table. Then take the abbreviation of that element and you have it!
Look! A slime!    <(^.^)>

Offline TheMachine02

  • Full User
  • Join Date: Dec 2014
  • Location:
  • Posts: 356
  • Post Rating Ratio: +14/-0
Re: Axe Interrupts stop working
« Reply #14 on: September 27, 2016, 03:43:18 pm »
L2 is the biggest at 800+ bytes.
Axe only lists L2 at 512 bytes, but the actual usable memory extends to beyond 800 (I don't remember the exact number)

https://www.omnimaga.org/asm-language/8384-free-ram-areas/

well, I guess it could work then. But yeah, who want more than 768 bytes anyway  :P

 


You can also use the following HTML or bulletin board code to share it on your page or forum signature!


Also do not forget to check our affiliates below.
Planet Casio TI-Planet Calc.news BroniesQC BosaikNet Velocity Games