This page (revision-9) was last changed on 03-Feb-2023 15:21 by Florian Dingler 

This page was created on 13-Mar-2010 19:16 by Carsten Strotmann

Only authorized users are allowed to rename pages.

Only authorized users are allowed to delete pages.

Page revision history

Version Date Modified Size Author Changes ... Change note
9 03-Feb-2023 15:21 4 KB Florian Dingler to previous
8 05-Jul-2019 06:26 4 KB Florian Dingler to previous | to last
7 05-Jul-2019 06:18 4 KB Florian Dingler to previous | to last
6 31-Jan-2011 18:54 4 KB Gromit to previous | to last
5 31-Jan-2011 09:17 4 KB Gromit to previous | to last
4 26-Jul-2010 09:31 4 KB Gromit to previous | to last
3 26-Jul-2010 09:27 2 KB Gromit to previous | to last
2 13-Mar-2010 19:17 333 bytes Carsten Strotmann to previous | to last
1 13-Mar-2010 19:16 169 bytes Carsten Strotmann to last

Page References

Incoming links Outgoing links

Version management

Difference between version and

At line 1 changed 4 lines
!!!Interrupts in ACTION
General Information
!General Information
At line 8 changed one line
Published: ANALOG July 1984 \\
Published: Antic July 1984 \\
----
!!!Interrupts in ACTION
At line 10 changed one line
[{Image src='interruptinaction.gif' width='..' height='..' align='left|center|right' style='..' class='..' }]
;Synopsis: ''This article discusses advanced programming techniques using the ACTION! language. To use the accompanying listings, you must have the ACTION! cartridge from Optimized Systems Software.''
At line 12 changed one line
PDF: [Interrupts in ACTION/interruptinaction.PDF]
An "interrupt" takes place in a computer system whenever one process takes precedence over a process that is being executed. It interrupts the lower-priority process so that it (the interrupt) can be executed first. Several interrupts are available on the Atari computers, including the display-list interrupt (DLI), the vertical-blank interrupt (VBI), and the system-timer interrupt, which was discussed in the January issue (Antic, "Page Flipping!" P. 34).
At line 13 added 11 lines
Before ACTION! came along, you had to be able to program in machine language to use these interrupts. Clinton Parker, ACTION!'s author, may have envisioned that ACTION! programmers would continue to use machine code to write interrupt routines, installing blocks of machine-language codes generated by their assemblers into their ACTION! programs. But ACTlON! is so fast that you call actually write a VBI or a system-timer interrupt in this high-level language, which is much easier than writing it in machine language.
Unfortunately when an ACTION! VBI interrupts an ACTION! program, the two use the same space in memory to hold temporary math variables for calculation. Because of this, the interrupt routine can alter the variables from the interrupted routine. As a result, results can be quite unpredictable.
Mike Fitch of Optimized Systems Software (OSS), ACTION!'s publisher, has solved this dilemma with two short machine-language routines that save the contents of the temporary math registers to the stack at the beginning of the interrupt, and then restore them just before the interrupt ends. Mike calls these routines SAVETEMPS and GETTEMPS.
You use the DEFINE command to assign machine-language code blocks to SAVETEMPS and GETTEMPS. The accompanying ACTION! program demonstrates the use of GETTEMPS and SAVETEMPS in a VBI. It also produces an interesting effect on the screen. These routines are just what you need if you want to use interrupts written in ACTION!
''David Plotkin is a chemical engineer with Standard Oil Company of California and an avid game programmer.
''
At line 28 changed one line
$CA $10 $F2 $A5 $D3 $48]",
$CA $10 $F1 $A5 $D3 $48]",
; diese SAVETEMPS Routine ist aus der Action! Fehlerkorrekturliste. Sie ist umfangreicher als das originale Beispiel aus dem Magazin
; und funktioniert sicher. Das Original sichert nur die Variablen für Addition/Subtraktion
At line 31 changed one line
$68 $95 $C0 $E8 $E0 $08 $D0 $F0]"
$68 $95 $C0 $E8 $E0 $08 $D0 $EF]"
; das gleiche wie oben gilt auch für die GETTEMPS Routine