source: buchla-68k/lib700/jumpto.s@ 861ab45

Last change on this file since 861ab45 was 8325447, checked in by Thomas Lopatic <thomas@…>, 7 years ago

Removed _ prefix.

  • Property mode set to 100644
File size: 1.6 KB
RevLine 
[4f508e6]1| ------------------------------------------------------------------------------
2| jumpto.s -- miscellaneous ROMP support functions
3| Version 4 -- 1987-10-14 -- D.N. Lynx Crowe
4
5| WARNING:
6| --------
7| These functions, in general, assume supervisor mode and
8| 'sane' arguments, so no error checking is done.
9
10| halt()
11
12| Brings the processor to a grinding halt. Requires external
13| reset to restart things. Use only for catastrophic hard halts.
14
15| jumpto(addr)
16| long addr;
17
18| Jumps to 'addr'. No error check is done on 'addr'.
19
20| rjumpto(addr)
21| long addr;
22
23| Performs the 68000 'RESET' command, then jumps to 'addr'.
24| No error check is made on 'addr'.
25
26| sjumpto(addr, stack)
27| long addr, stack;
28
29| Sets a7 to 'stack', then jumps to 'addr'.
30| No error check is done on 'addr'.
31
32| xreset()
33
34| Performs the 68000 'RESET' command. This is very dangerous,
35| and should be used with extreme care regarding such
36| things as interrupts, device initialization, vectors,
37| and sundry other reset-related things.
38
39| ------------------------------------------------------------------------------
[f40a309]40 .text
[4f508e6]41
[8325447]42 .xdef halt,jumpto,rjumpto,sjumpto,xreset
[4f508e6]43
[f40a309]44 .page
[4f508e6]45
[8325447]46halt: stop #0x2700 | stop dead, interrupts disabled
47 jmp halt | stay stopped if stepped thru
[4f508e6]48
[8325447]49jumpto: movea.l 4(a7),a0 | get jump address
[4f508e6]50 jmp (a0) | go to the jump address
51
[8325447]52rjumpto: reset | reset external devices
[4f508e6]53 movea.l 4(a7),a0 | get jump address
54 jmp (a0) | go to the jump address
55
[8325447]56sjumpto: movea.l 4(a7),a0 | get jump address
[4f508e6]57 movea.l 8(a7),a7 | set stack pointer
58 jmp (a0) | go to the jump address
59
[8325447]60xreset: reset | reset external devices
[4f508e6]61 rts | return to caller
62
[f40a309]63 .end
Note: See TracBrowser for help on using the repository browser.