π
<-

Utilization des Auto-Ints (92+)

Programmation et implémentation d'algorithmes.

Re: Utilization des Auto-Ints (92+)

Unread postby Lionel Debroux » 16 Mar 2016, 08:01

Edit: Just looked into PolySnd a bit. I can't figure out how it's using AUTO_INT_5. There's a move.w #$700,d0, trap #1 at the beginning... so how exactly does this work?

In my local copy of PolySnd 2.47.2, which is in a pristine state according to the files' date stamps, both occurrences of move.w #$700,d0; trap #1 in the sources/statique folder are commented out ? Otherwise, yeah, it shouldn't work.

Looking at it, there's a bug in GetHardware: the andi.l immediate operand should be E00000. And GetHardware should have been inlined.
Membre de la TI-Chess Team.
Co-mainteneur de GCC4TI (documentation en ligne de GCC4TI), TIEmu et TILP.
User avatar
Lionel DebrouxSuper Modo
Niveau 14: CI (Calculateur de l'Infini)
Niveau 14: CI (Calculateur de l'Infini)
Level up: 11.4%
 
Posts: 6873
Joined: 23 Dec 2009, 00:00
Location: France
Gender: Male
Calculator(s):
MyCalcs profile
Class: -
GitHub: debrouxl

Re: Utilization des Auto-Ints (92+)

Unread postby utz » 16 Mar 2016, 12:25

D'oh! Of course I had an outdated version of PolySnd.

Anyway, I now have a working 4-channel sound routine using auto-ints 5 and 6. Which is still quite a stretch from what I have in mind, but for now I'm glad I at least managed to figure the interrupt thing, so thanks a ton for your help, Lionel.

Only one problem remains: After running the program, I can't turn off the calc (ie it'll turn itself on again after a fraction of a second). I had this problem even before implementing the interrupts, so it should be unrelated to that. In my opinion(tm) I'm resetting everything to system defaults on exit (ie restoring original int mask, clean usr stack, pull link port lines high, disable direct sound). Any ideas what I might be missing here?
User avatar
utz
Niveau 3: MH (Membre Habitué)
Niveau 3: MH (Membre Habitué)
Level up: 36%
 
Posts: 13
Joined: 15 Mar 2016, 10:05
Gender: Not specified
Calculator(s):
MyCalcs profile

Re: Utilization des Auto-Ints (92+)

Unread postby Lionel Debroux » 16 Mar 2016, 14:56

What I did in my aforementioned TV Noise demo didn't yield such behaviour after exiting the program, so try doing the same :)
Membre de la TI-Chess Team.
Co-mainteneur de GCC4TI (documentation en ligne de GCC4TI), TIEmu et TILP.
User avatar
Lionel DebrouxSuper Modo
Niveau 14: CI (Calculateur de l'Infini)
Niveau 14: CI (Calculateur de l'Infini)
Level up: 11.4%
 
Posts: 6873
Joined: 23 Dec 2009, 00:00
Location: France
Gender: Male
Calculator(s):
MyCalcs profile
Class: -
GitHub: debrouxl

Re: Utilization des Auto-Ints (92+)

Unread postby utz » 16 Mar 2016, 15:06

Problem solved, was resetting the wrong bits in ($60000E). Interesting side note, seems the 92+ does not like writes to bit 2 (and possibly 3) of the aforementioned port. I've yet to see something about that in J89hw.txt :o
User avatar
utz
Niveau 3: MH (Membre Habitué)
Niveau 3: MH (Membre Habitué)
Level up: 36%
 
Posts: 13
Joined: 15 Mar 2016, 10:05
Gender: Not specified
Calculator(s):
MyCalcs profile

Re: Utilization des Auto-Ints (92+)

Unread postby Lionel Debroux » 16 Mar 2016, 15:11

OSLinkReset does that and more.
Membre de la TI-Chess Team.
Co-mainteneur de GCC4TI (documentation en ligne de GCC4TI), TIEmu et TILP.
User avatar
Lionel DebrouxSuper Modo
Niveau 14: CI (Calculateur de l'Infini)
Niveau 14: CI (Calculateur de l'Infini)
Level up: 11.4%
 
Posts: 6873
Joined: 23 Dec 2009, 00:00
Location: France
Gender: Male
Calculator(s):
MyCalcs profile
Class: -
GitHub: debrouxl

Re: Utilization des Auto-Ints (92+)

Unread postby utz » 20 Mar 2016, 23:01

Ok, so how exactly do I use that function? I tried jsr tios::OSLinkReset, but that failed (unresolved symbol).
User avatar
utz
Niveau 3: MH (Membre Habitué)
Niveau 3: MH (Membre Habitué)
Level up: 36%
 
Posts: 13
Joined: 15 Mar 2016, 10:05
Gender: Not specified
Calculator(s):
MyCalcs profile

Re: Utilization des Auto-Ints (92+)

Unread postby Lionel Debroux » 20 Mar 2016, 23:10

First of all, you need to include the appropriate os.h header file. It's in $TIGCC/include/asm for A68k or $TIGCC/include/s for GNU as.
The ROM_CALL method is up to you, with different speed / size compatibility tradeoffs: direct ROM_CALLs, optimized ROM_CALLs, kernel-style ROM_CALLs, F-Line ROM_CALLs, etc. See the documentation.
Membre de la TI-Chess Team.
Co-mainteneur de GCC4TI (documentation en ligne de GCC4TI), TIEmu et TILP.
User avatar
Lionel DebrouxSuper Modo
Niveau 14: CI (Calculateur de l'Infini)
Niveau 14: CI (Calculateur de l'Infini)
Level up: 11.4%
 
Posts: 6873
Joined: 23 Dec 2009, 00:00
Location: France
Gender: Male
Calculator(s):
MyCalcs profile
Class: -
GitHub: debrouxl

Re: Utilization des Auto-Ints (92+)

Unread postby utz » 21 Mar 2016, 00:52

Ok, so I gather ROM_CALL OSLinkReset will do a "direct" ROM_CALL? Aside from it being slow (which doesn't matter much at this point), are there any other drawbacks of doing it this way? Sorry, I don't really understand the documentation on this, at least as far as asm usage is concerned.

Anyway, got 4 channel sample playback working. Needs a bit more testing before I can release it though.
User avatar
utz
Niveau 3: MH (Membre Habitué)
Niveau 3: MH (Membre Habitué)
Level up: 36%
 
Posts: 13
Joined: 15 Mar 2016, 10:05
Gender: Not specified
Calculator(s):
MyCalcs profile

Re: Utilization des Auto-Ints (92+)

Unread postby Lionel Debroux » 21 Mar 2016, 07:44

Direct ROM_CALLs always work, but they're one of the largest ways to perform ROM_CALLs, because the jump table's address is always reloaded, no Common Subexpression Elimination occurs. Slowness doesn't matter here indeed, the ROM_CALL itself contains much more code than that. And F-Line ROM_CALLs are slower than direct ROM_CALLs, and work only on AMS 2.04+ (unless one enables the internal F-Line emulator), but they're the smallest way to perform ROM_CALLs: only 2 bytes, no relocation.
Membre de la TI-Chess Team.
Co-mainteneur de GCC4TI (documentation en ligne de GCC4TI), TIEmu et TILP.
User avatar
Lionel DebrouxSuper Modo
Niveau 14: CI (Calculateur de l'Infini)
Niveau 14: CI (Calculateur de l'Infini)
Level up: 11.4%
 
Posts: 6873
Joined: 23 Dec 2009, 00:00
Location: France
Gender: Male
Calculator(s):
MyCalcs profile
Class: -
GitHub: debrouxl

Re: Utilization des Auto-Ints (92+)

Unread postby nature » 21 Mar 2016, 11:10

Bonjour, c’est un peu difficile de lire le post en français et les commentaires en anglais. Nous on veut tout simplement trouver des solutions à ces problèmes et on perd du temps à traduire ces commentaires pour mieux comprendre.
User avatar
nature
Niveau 0: MI (Membre Inactif)
Niveau 0: MI (Membre Inactif)
Level up: 0%
 
Posts: 13
Joined: 21 Mar 2016, 10:26
Gender: Not specified
Calculator(s):
MyCalcs profile

PreviousNext

Return to Programmation

Who is online

Users browsing this forum: ClaudeBot [spider] and 0 guests

-
Search
-
Social TI-Planet
-
Featured topics
Comparaisons des meilleurs prix pour acheter sa calculatrice !
"1 calculatrice pour tous", le programme solidaire de Texas Instruments. Reçois gratuitement et sans aucune obligation d'achat, 5 calculatrices couleur programmables en Python à donner aux élèves les plus nécessiteux de ton lycée. Tu peux recevoir au choix 5 TI-82 Advanced Edition Python ou bien 5 TI-83 Premium CE Edition Python.
Enseignant(e), reçois gratuitement 1 exemplaire de test de la TI-82 Advanced Edition Python. À demander d'ici le 31 décembre 2024.
Aidez la communauté à documenter les révisions matérielles en listant vos calculatrices graphiques !
1234
-
Donations / Premium
For more contests, prizes, reviews, helping us pay the server and domains...
Donate
Discover the the advantages of a donor account !
JoinRejoignez the donors and/or premium!les donateurs et/ou premium !


Partner and ad
Notre partenaire Jarrety Calculatrices à acheter chez Calcuso
-
Stats.
1268 utilisateurs:
>1243 invités
>18 membres
>7 robots
Record simultané (sur 6 mois):
7582 utilisateurs (le 25/06/2025)
-
Other interesting websites
Texas Instruments Education
Global | France
 (English / Français)
Banque de programmes TI
ticalc.org
 (English)
La communauté TI-82
tout82.free.fr
 (Français)