Home » Archimedes archive » Acorn User » AU 1998-03 B.adf » StarInfo » Lurcock/s/IphHdr

Lurcock/s/IphHdr

This website contains an archive of files for the Acorn Electron, BBC Micro, Acorn Archimedes, Commodore 16 and Commodore 64 computers, which Dominic Ford has rescued from his private collection of floppy disks and cassettes.

Some of these files were originally commercial releases in the 1980s and 1990s, but they are now widely available online. I assume that copyright over them is no longer being asserted. If you own the copyright and would like files to be removed, please contact me.

Tape/disk: Home » Archimedes archive » Acorn User » AU 1998-03 B.adf » StarInfo
Filename: Lurcock/s/IphHdr
Read OK:
File size: 0D91 bytes
Load address: 0000
Exec address: 0000
File contents
; Intelligent Pointer Hider
; Module header

        GET     ADFS::HardDisc4.$.AcornC_C++.Examples.AsmHdrs.h.SWINames
	GET	s.Layout
        AREA    |!!!Module$$Header|, CODE, READONLY

        IMPORT  |__RelocCode|            ; Link symbol for relocation routine
	IMPORT	|Poll_Loop|
	IMPORT	|Event_Code|

        ENTRY

ModBase
        DCD     RM_Start   -ModBase
        DCD     RM_Init    -ModBase
        DCD     RM_Die     -ModBase
        DCD     RM_Service -ModBase
        DCD     RM_Title   -ModBase
        DCD     RM_HelpStr -ModBase
        DCD     RM_HC_Table-ModBase

RM_Title
        =       "IPH", 0

RM_HelpStr
        =       "Intelligent Pointer Hider", 9, 9
        =       "1.00 (04 Apr 1997)", 0
        ALIGN

RM_Start
	LDR	r12,[r12]
	LDR	r0,[r12,#TaskHandle]	; get task handle
	TEQ	r0,#0			; are we running?
	LDRGT	r1,Task
	SWIGT	XWimp_CloseDown		; if so, quit
	MOVGT	r0,#0
	STRGT	r0,[r12,#TaskHandle]	; and store task handle of zero
	MOV	r0,#300
	ADD	r0,r0,#10
	LDR	r1,Task
	ADR	r2,RM_Title
	ADR	r3,Msg_List
	SWI	XWimp_Initialise
	SWIVS	XOS_Exit		; exit if an error occurred
	STR	r1,[r12,#TaskHandle]	; store task handle
	STR	r0,[r12]
	MOV	r1,r12
	SWI	XWimp_GetWindowState
	SWI	XWimp_OpenWindow
	B	Poll_Loop

RM_Init
        STMFD   sp!, {r7-r11,r14}
        BL      |__RelocCode|		; initialise absolute code pointers
	MOV	r0,#6                   ; reason code for claim
	MOV	r3,#300			; no. of bytes
	SWI	XOS_Module
	BVS	Init_Exit		; skip this if error occurred
	STR	r2,[r12]		; store our workspace pointer
	MOV	r0,#0			; no task handle yet -
	STR	r0,[r2,#TaskHandle]	; - so just store zero
	STR	r0,[r2,#Hidden]
	STR	r0,[r2,#PollWord]
	MOV	r0,#&10			; event vector
	ADR	r1,Event_Code
	SWI	XOS_Claim		; (r12 will point to memory)
	MOV	r0,#14
	MOV	r1,#11
	SWI	XOS_Byte		; enable key pressed event
Init_Exit
        LDMFD   sp!, {r7-r11,r15}

RM_Die
	STMFD	sp!,{r7-r11,r14}
	LDR	r12,[r12]		; get workspace pointer
	LDR	r0,[r12,#TaskHandle]	; get task handle
	TEQ	r0,#0			; are we running as a task?
	LDRGT	r1,Task			; if so get "TASK"
	SWIGT	XWimp_CloseDown		; and terminate
	MOV	r1,#0
	STR	r1,[r12,#TaskHandle]
	MOV	r0,#&10
	ADR	r1,Event_Code
	MOV	r2,r12
	SWI	XOS_Release		; release vector routine
	MOV	r0,#7			; 7 = free workspace
	SWI	XOS_Module
	MOV	r0,#13
	MOV	r1,#11
	SWI	XOS_Byte		; disable key pressed event
	LDMFD	sp!,{r7-r11,PC}

RM_Service
	LDR	r12,[r12]			; get workspace pointer
	STMFD	sp!,{r14}
	TEQ	r1,#&49				; StartWimp
	BEQ	Service_StartWimp
	TEQ	r1,#&4A				; StartedWimp
	BEQ	Service_StartedWimp
	TEQ	r1,#&27				; Reset?
	MOVEQ	r14,#0				; if so, zero task handle
	STREQ	r14,[r12,#TaskHandle]		; and store it
	LDMFD	sp!,{PC}

Service_StartWimp
	LDR	r14,[r12,#TaskHandle]		; get task handle
	TEQ	r14,#0				; are we running?
	MVNEQ	r14,#0				; if not, set handle to -1
	STREQ	r14,[r12,#TaskHandle]
	ADREQ	r0,RM_HC_Table			; point r0 to start command
	MOVEQ	r1,#0				; and claim the service
	LDMFD	sp!,{PC}

Service_StartedWimp
	LDR	r14,[r12,#TaskHandle]
	CMN	r14,#1				; is taskhandle -1?
	MOVEQ	r14,#0				; if so, zero it
	STREQ	r14,[r12,#TaskHandle]
	LDMFD	sp!,{PC}

RM_HC_Table
	=	"Desktop_Iph",0
	ALIGN
	DCD	StarCommand-ModBase
	DCD	0
	DCD	0
	DCD	DoNotUse-ModBase
	=	0
	ALIGN

DoNotUse
	=	"Do not use *Desktop_Iph, use *Desktop instead.",0
	ALIGN

StarCommand
	STMFD	sp!,{r14}
	MOV	r2,r0			; parameters
	ADR	r1,RM_Title
	MOV	R0,#2			; enter as language
	SWI	XOS_Module
	LDMFD	sp!,{PC}

Task	=	"TASK"

Msg_List
	DCD	0

        END
00000000  3b 20 49 6e 74 65 6c 6c  69 67 65 6e 74 20 50 6f  |; Intelligent Po|
00000010  69 6e 74 65 72 20 48 69  64 65 72 0a 3b 20 4d 6f  |inter Hider.; Mo|
00000020  64 75 6c 65 20 68 65 61  64 65 72 0a 0a 20 20 20  |dule header..   |
00000030  20 20 20 20 20 47 45 54  20 20 20 20 20 41 44 46  |     GET     ADF|
00000040  53 3a 3a 48 61 72 64 44  69 73 63 34 2e 24 2e 41  |S::HardDisc4.$.A|
00000050  63 6f 72 6e 43 5f 43 2b  2b 2e 45 78 61 6d 70 6c  |cornC_C++.Exampl|
00000060  65 73 2e 41 73 6d 48 64  72 73 2e 68 2e 53 57 49  |es.AsmHdrs.h.SWI|
00000070  4e 61 6d 65 73 0a 09 47  45 54 09 73 2e 4c 61 79  |Names..GET.s.Lay|
00000080  6f 75 74 0a 20 20 20 20  20 20 20 20 41 52 45 41  |out.        AREA|
00000090  20 20 20 20 7c 21 21 21  4d 6f 64 75 6c 65 24 24  |    |!!!Module$$|
000000a0  48 65 61 64 65 72 7c 2c  20 43 4f 44 45 2c 20 52  |Header|, CODE, R|
000000b0  45 41 44 4f 4e 4c 59 0a  0a 20 20 20 20 20 20 20  |EADONLY..       |
000000c0  20 49 4d 50 4f 52 54 20  20 7c 5f 5f 52 65 6c 6f  | IMPORT  |__Relo|
000000d0  63 43 6f 64 65 7c 20 20  20 20 20 20 20 20 20 20  |cCode|          |
000000e0  20 20 3b 20 4c 69 6e 6b  20 73 79 6d 62 6f 6c 20  |  ; Link symbol |
000000f0  66 6f 72 20 72 65 6c 6f  63 61 74 69 6f 6e 20 72  |for relocation r|
00000100  6f 75 74 69 6e 65 0a 09  49 4d 50 4f 52 54 09 7c  |outine..IMPORT.||
00000110  50 6f 6c 6c 5f 4c 6f 6f  70 7c 0a 09 49 4d 50 4f  |Poll_Loop|..IMPO|
00000120  52 54 09 7c 45 76 65 6e  74 5f 43 6f 64 65 7c 0a  |RT.|Event_Code|.|
00000130  0a 20 20 20 20 20 20 20  20 45 4e 54 52 59 0a 0a  |.        ENTRY..|
00000140  4d 6f 64 42 61 73 65 0a  20 20 20 20 20 20 20 20  |ModBase.        |
00000150  44 43 44 20 20 20 20 20  52 4d 5f 53 74 61 72 74  |DCD     RM_Start|
00000160  20 20 20 2d 4d 6f 64 42  61 73 65 0a 20 20 20 20  |   -ModBase.    |
00000170  20 20 20 20 44 43 44 20  20 20 20 20 52 4d 5f 49  |    DCD     RM_I|
00000180  6e 69 74 20 20 20 20 2d  4d 6f 64 42 61 73 65 0a  |nit    -ModBase.|
00000190  20 20 20 20 20 20 20 20  44 43 44 20 20 20 20 20  |        DCD     |
000001a0  52 4d 5f 44 69 65 20 20  20 20 20 2d 4d 6f 64 42  |RM_Die     -ModB|
000001b0  61 73 65 0a 20 20 20 20  20 20 20 20 44 43 44 20  |ase.        DCD |
000001c0  20 20 20 20 52 4d 5f 53  65 72 76 69 63 65 20 2d  |    RM_Service -|
000001d0  4d 6f 64 42 61 73 65 0a  20 20 20 20 20 20 20 20  |ModBase.        |
000001e0  44 43 44 20 20 20 20 20  52 4d 5f 54 69 74 6c 65  |DCD     RM_Title|
000001f0  20 20 20 2d 4d 6f 64 42  61 73 65 0a 20 20 20 20  |   -ModBase.    |
00000200  20 20 20 20 44 43 44 20  20 20 20 20 52 4d 5f 48  |    DCD     RM_H|
00000210  65 6c 70 53 74 72 20 2d  4d 6f 64 42 61 73 65 0a  |elpStr -ModBase.|
00000220  20 20 20 20 20 20 20 20  44 43 44 20 20 20 20 20  |        DCD     |
00000230  52 4d 5f 48 43 5f 54 61  62 6c 65 2d 4d 6f 64 42  |RM_HC_Table-ModB|
00000240  61 73 65 0a 0a 52 4d 5f  54 69 74 6c 65 0a 20 20  |ase..RM_Title.  |
00000250  20 20 20 20 20 20 3d 20  20 20 20 20 20 20 22 49  |      =       "I|
00000260  50 48 22 2c 20 30 0a 0a  52 4d 5f 48 65 6c 70 53  |PH", 0..RM_HelpS|
00000270  74 72 0a 20 20 20 20 20  20 20 20 3d 20 20 20 20  |tr.        =    |
00000280  20 20 20 22 49 6e 74 65  6c 6c 69 67 65 6e 74 20  |   "Intelligent |
00000290  50 6f 69 6e 74 65 72 20  48 69 64 65 72 22 2c 20  |Pointer Hider", |
000002a0  39 2c 20 39 0a 20 20 20  20 20 20 20 20 3d 20 20  |9, 9.        =  |
000002b0  20 20 20 20 20 22 31 2e  30 30 20 28 30 34 20 41  |     "1.00 (04 A|
000002c0  70 72 20 31 39 39 37 29  22 2c 20 30 0a 20 20 20  |pr 1997)", 0.   |
000002d0  20 20 20 20 20 41 4c 49  47 4e 0a 0a 52 4d 5f 53  |     ALIGN..RM_S|
000002e0  74 61 72 74 0a 09 4c 44  52 09 72 31 32 2c 5b 72  |tart..LDR.r12,[r|
000002f0  31 32 5d 0a 09 4c 44 52  09 72 30 2c 5b 72 31 32  |12]..LDR.r0,[r12|
00000300  2c 23 54 61 73 6b 48 61  6e 64 6c 65 5d 09 3b 20  |,#TaskHandle].; |
00000310  67 65 74 20 74 61 73 6b  20 68 61 6e 64 6c 65 0a  |get task handle.|
00000320  09 54 45 51 09 72 30 2c  23 30 09 09 09 3b 20 61  |.TEQ.r0,#0...; a|
00000330  72 65 20 77 65 20 72 75  6e 6e 69 6e 67 3f 0a 09  |re we running?..|
00000340  4c 44 52 47 54 09 72 31  2c 54 61 73 6b 0a 09 53  |LDRGT.r1,Task..S|
00000350  57 49 47 54 09 58 57 69  6d 70 5f 43 6c 6f 73 65  |WIGT.XWimp_Close|
00000360  44 6f 77 6e 09 09 3b 20  69 66 20 73 6f 2c 20 71  |Down..; if so, q|
00000370  75 69 74 0a 09 4d 4f 56  47 54 09 72 30 2c 23 30  |uit..MOVGT.r0,#0|
00000380  0a 09 53 54 52 47 54 09  72 30 2c 5b 72 31 32 2c  |..STRGT.r0,[r12,|
00000390  23 54 61 73 6b 48 61 6e  64 6c 65 5d 09 3b 20 61  |#TaskHandle].; a|
000003a0  6e 64 20 73 74 6f 72 65  20 74 61 73 6b 20 68 61  |nd store task ha|
000003b0  6e 64 6c 65 20 6f 66 20  7a 65 72 6f 0a 09 4d 4f  |ndle of zero..MO|
000003c0  56 09 72 30 2c 23 33 30  30 0a 09 41 44 44 09 72  |V.r0,#300..ADD.r|
000003d0  30 2c 72 30 2c 23 31 30  0a 09 4c 44 52 09 72 31  |0,r0,#10..LDR.r1|
000003e0  2c 54 61 73 6b 0a 09 41  44 52 09 72 32 2c 52 4d  |,Task..ADR.r2,RM|
000003f0  5f 54 69 74 6c 65 0a 09  41 44 52 09 72 33 2c 4d  |_Title..ADR.r3,M|
00000400  73 67 5f 4c 69 73 74 0a  09 53 57 49 09 58 57 69  |sg_List..SWI.XWi|
00000410  6d 70 5f 49 6e 69 74 69  61 6c 69 73 65 0a 09 53  |mp_Initialise..S|
00000420  57 49 56 53 09 58 4f 53  5f 45 78 69 74 09 09 3b  |WIVS.XOS_Exit..;|
00000430  20 65 78 69 74 20 69 66  20 61 6e 20 65 72 72 6f  | exit if an erro|
00000440  72 20 6f 63 63 75 72 72  65 64 0a 09 53 54 52 09  |r occurred..STR.|
00000450  72 31 2c 5b 72 31 32 2c  23 54 61 73 6b 48 61 6e  |r1,[r12,#TaskHan|
00000460  64 6c 65 5d 09 3b 20 73  74 6f 72 65 20 74 61 73  |dle].; store tas|
00000470  6b 20 68 61 6e 64 6c 65  0a 09 53 54 52 09 72 30  |k handle..STR.r0|
00000480  2c 5b 72 31 32 5d 0a 09  4d 4f 56 09 72 31 2c 72  |,[r12]..MOV.r1,r|
00000490  31 32 0a 09 53 57 49 09  58 57 69 6d 70 5f 47 65  |12..SWI.XWimp_Ge|
000004a0  74 57 69 6e 64 6f 77 53  74 61 74 65 0a 09 53 57  |tWindowState..SW|
000004b0  49 09 58 57 69 6d 70 5f  4f 70 65 6e 57 69 6e 64  |I.XWimp_OpenWind|
000004c0  6f 77 0a 09 42 09 50 6f  6c 6c 5f 4c 6f 6f 70 0a  |ow..B.Poll_Loop.|
000004d0  0a 52 4d 5f 49 6e 69 74  0a 20 20 20 20 20 20 20  |.RM_Init.       |
000004e0  20 53 54 4d 46 44 20 20  20 73 70 21 2c 20 7b 72  | STMFD   sp!, {r|
000004f0  37 2d 72 31 31 2c 72 31  34 7d 0a 20 20 20 20 20  |7-r11,r14}.     |
00000500  20 20 20 42 4c 20 20 20  20 20 20 7c 5f 5f 52 65  |   BL      |__Re|
00000510  6c 6f 63 43 6f 64 65 7c  09 09 3b 20 69 6e 69 74  |locCode|..; init|
00000520  69 61 6c 69 73 65 20 61  62 73 6f 6c 75 74 65 20  |ialise absolute |
00000530  63 6f 64 65 20 70 6f 69  6e 74 65 72 73 0a 09 4d  |code pointers..M|
00000540  4f 56 09 72 30 2c 23 36  20 20 20 20 20 20 20 20  |OV.r0,#6        |
00000550  20 20 20 20 20 20 20 20  20 20 20 3b 20 72 65 61  |           ; rea|
00000560  73 6f 6e 20 63 6f 64 65  20 66 6f 72 20 63 6c 61  |son code for cla|
00000570  69 6d 0a 09 4d 4f 56 09  72 33 2c 23 33 30 30 09  |im..MOV.r3,#300.|
00000580  09 09 3b 20 6e 6f 2e 20  6f 66 20 62 79 74 65 73  |..; no. of bytes|
00000590  0a 09 53 57 49 09 58 4f  53 5f 4d 6f 64 75 6c 65  |..SWI.XOS_Module|
000005a0  0a 09 42 56 53 09 49 6e  69 74 5f 45 78 69 74 09  |..BVS.Init_Exit.|
000005b0  09 3b 20 73 6b 69 70 20  74 68 69 73 20 69 66 20  |.; skip this if |
000005c0  65 72 72 6f 72 20 6f 63  63 75 72 72 65 64 0a 09  |error occurred..|
000005d0  53 54 52 09 72 32 2c 5b  72 31 32 5d 09 09 3b 20  |STR.r2,[r12]..; |
000005e0  73 74 6f 72 65 20 6f 75  72 20 77 6f 72 6b 73 70  |store our worksp|
000005f0  61 63 65 20 70 6f 69 6e  74 65 72 0a 09 4d 4f 56  |ace pointer..MOV|
00000600  09 72 30 2c 23 30 09 09  09 3b 20 6e 6f 20 74 61  |.r0,#0...; no ta|
00000610  73 6b 20 68 61 6e 64 6c  65 20 79 65 74 20 2d 0a  |sk handle yet -.|
00000620  09 53 54 52 09 72 30 2c  5b 72 32 2c 23 54 61 73  |.STR.r0,[r2,#Tas|
00000630  6b 48 61 6e 64 6c 65 5d  09 3b 20 2d 20 73 6f 20  |kHandle].; - so |
00000640  6a 75 73 74 20 73 74 6f  72 65 20 7a 65 72 6f 0a  |just store zero.|
00000650  09 53 54 52 09 72 30 2c  5b 72 32 2c 23 48 69 64  |.STR.r0,[r2,#Hid|
00000660  64 65 6e 5d 0a 09 53 54  52 09 72 30 2c 5b 72 32  |den]..STR.r0,[r2|
00000670  2c 23 50 6f 6c 6c 57 6f  72 64 5d 0a 09 4d 4f 56  |,#PollWord]..MOV|
00000680  09 72 30 2c 23 26 31 30  09 09 09 3b 20 65 76 65  |.r0,#&10...; eve|
00000690  6e 74 20 76 65 63 74 6f  72 0a 09 41 44 52 09 72  |nt vector..ADR.r|
000006a0  31 2c 45 76 65 6e 74 5f  43 6f 64 65 0a 09 53 57  |1,Event_Code..SW|
000006b0  49 09 58 4f 53 5f 43 6c  61 69 6d 09 09 3b 20 28  |I.XOS_Claim..; (|
000006c0  72 31 32 20 77 69 6c 6c  20 70 6f 69 6e 74 20 74  |r12 will point t|
000006d0  6f 20 6d 65 6d 6f 72 79  29 0a 09 4d 4f 56 09 72  |o memory)..MOV.r|
000006e0  30 2c 23 31 34 0a 09 4d  4f 56 09 72 31 2c 23 31  |0,#14..MOV.r1,#1|
000006f0  31 0a 09 53 57 49 09 58  4f 53 5f 42 79 74 65 09  |1..SWI.XOS_Byte.|
00000700  09 3b 20 65 6e 61 62 6c  65 20 6b 65 79 20 70 72  |.; enable key pr|
00000710  65 73 73 65 64 20 65 76  65 6e 74 0a 49 6e 69 74  |essed event.Init|
00000720  5f 45 78 69 74 0a 20 20  20 20 20 20 20 20 4c 44  |_Exit.        LD|
00000730  4d 46 44 20 20 20 73 70  21 2c 20 7b 72 37 2d 72  |MFD   sp!, {r7-r|
00000740  31 31 2c 72 31 35 7d 0a  0a 52 4d 5f 44 69 65 0a  |11,r15}..RM_Die.|
00000750  09 53 54 4d 46 44 09 73  70 21 2c 7b 72 37 2d 72  |.STMFD.sp!,{r7-r|
00000760  31 31 2c 72 31 34 7d 0a  09 4c 44 52 09 72 31 32  |11,r14}..LDR.r12|
00000770  2c 5b 72 31 32 5d 09 09  3b 20 67 65 74 20 77 6f  |,[r12]..; get wo|
00000780  72 6b 73 70 61 63 65 20  70 6f 69 6e 74 65 72 0a  |rkspace pointer.|
00000790  09 4c 44 52 09 72 30 2c  5b 72 31 32 2c 23 54 61  |.LDR.r0,[r12,#Ta|
000007a0  73 6b 48 61 6e 64 6c 65  5d 09 3b 20 67 65 74 20  |skHandle].; get |
000007b0  74 61 73 6b 20 68 61 6e  64 6c 65 0a 09 54 45 51  |task handle..TEQ|
000007c0  09 72 30 2c 23 30 09 09  09 3b 20 61 72 65 20 77  |.r0,#0...; are w|
000007d0  65 20 72 75 6e 6e 69 6e  67 20 61 73 20 61 20 74  |e running as a t|
000007e0  61 73 6b 3f 0a 09 4c 44  52 47 54 09 72 31 2c 54  |ask?..LDRGT.r1,T|
000007f0  61 73 6b 09 09 09 3b 20  69 66 20 73 6f 20 67 65  |ask...; if so ge|
00000800  74 20 22 54 41 53 4b 22  0a 09 53 57 49 47 54 09  |t "TASK"..SWIGT.|
00000810  58 57 69 6d 70 5f 43 6c  6f 73 65 44 6f 77 6e 09  |XWimp_CloseDown.|
00000820  09 3b 20 61 6e 64 20 74  65 72 6d 69 6e 61 74 65  |.; and terminate|
00000830  0a 09 4d 4f 56 09 72 31  2c 23 30 0a 09 53 54 52  |..MOV.r1,#0..STR|
00000840  09 72 31 2c 5b 72 31 32  2c 23 54 61 73 6b 48 61  |.r1,[r12,#TaskHa|
00000850  6e 64 6c 65 5d 0a 09 4d  4f 56 09 72 30 2c 23 26  |ndle]..MOV.r0,#&|
00000860  31 30 0a 09 41 44 52 09  72 31 2c 45 76 65 6e 74  |10..ADR.r1,Event|
00000870  5f 43 6f 64 65 0a 09 4d  4f 56 09 72 32 2c 72 31  |_Code..MOV.r2,r1|
00000880  32 0a 09 53 57 49 09 58  4f 53 5f 52 65 6c 65 61  |2..SWI.XOS_Relea|
00000890  73 65 09 09 3b 20 72 65  6c 65 61 73 65 20 76 65  |se..; release ve|
000008a0  63 74 6f 72 20 72 6f 75  74 69 6e 65 0a 09 4d 4f  |ctor routine..MO|
000008b0  56 09 72 30 2c 23 37 09  09 09 3b 20 37 20 3d 20  |V.r0,#7...; 7 = |
000008c0  66 72 65 65 20 77 6f 72  6b 73 70 61 63 65 0a 09  |free workspace..|
000008d0  53 57 49 09 58 4f 53 5f  4d 6f 64 75 6c 65 0a 09  |SWI.XOS_Module..|
000008e0  4d 4f 56 09 72 30 2c 23  31 33 0a 09 4d 4f 56 09  |MOV.r0,#13..MOV.|
000008f0  72 31 2c 23 31 31 0a 09  53 57 49 09 58 4f 53 5f  |r1,#11..SWI.XOS_|
00000900  42 79 74 65 09 09 3b 20  64 69 73 61 62 6c 65 20  |Byte..; disable |
00000910  6b 65 79 20 70 72 65 73  73 65 64 20 65 76 65 6e  |key pressed even|
00000920  74 0a 09 4c 44 4d 46 44  09 73 70 21 2c 7b 72 37  |t..LDMFD.sp!,{r7|
00000930  2d 72 31 31 2c 50 43 7d  0a 0a 52 4d 5f 53 65 72  |-r11,PC}..RM_Ser|
00000940  76 69 63 65 0a 09 4c 44  52 09 72 31 32 2c 5b 72  |vice..LDR.r12,[r|
00000950  31 32 5d 09 09 09 3b 20  67 65 74 20 77 6f 72 6b  |12]...; get work|
00000960  73 70 61 63 65 20 70 6f  69 6e 74 65 72 0a 09 53  |space pointer..S|
00000970  54 4d 46 44 09 73 70 21  2c 7b 72 31 34 7d 0a 09  |TMFD.sp!,{r14}..|
00000980  54 45 51 09 72 31 2c 23  26 34 39 09 09 09 09 3b  |TEQ.r1,#&49....;|
00000990  20 53 74 61 72 74 57 69  6d 70 0a 09 42 45 51 09  | StartWimp..BEQ.|
000009a0  53 65 72 76 69 63 65 5f  53 74 61 72 74 57 69 6d  |Service_StartWim|
000009b0  70 0a 09 54 45 51 09 72  31 2c 23 26 34 41 09 09  |p..TEQ.r1,#&4A..|
000009c0  09 09 3b 20 53 74 61 72  74 65 64 57 69 6d 70 0a  |..; StartedWimp.|
000009d0  09 42 45 51 09 53 65 72  76 69 63 65 5f 53 74 61  |.BEQ.Service_Sta|
000009e0  72 74 65 64 57 69 6d 70  0a 09 54 45 51 09 72 31  |rtedWimp..TEQ.r1|
000009f0  2c 23 26 32 37 09 09 09  09 3b 20 52 65 73 65 74  |,#&27....; Reset|
00000a00  3f 0a 09 4d 4f 56 45 51  09 72 31 34 2c 23 30 09  |?..MOVEQ.r14,#0.|
00000a10  09 09 09 3b 20 69 66 20  73 6f 2c 20 7a 65 72 6f  |...; if so, zero|
00000a20  20 74 61 73 6b 20 68 61  6e 64 6c 65 0a 09 53 54  | task handle..ST|
00000a30  52 45 51 09 72 31 34 2c  5b 72 31 32 2c 23 54 61  |REQ.r14,[r12,#Ta|
00000a40  73 6b 48 61 6e 64 6c 65  5d 09 09 3b 20 61 6e 64  |skHandle]..; and|
00000a50  20 73 74 6f 72 65 20 69  74 0a 09 4c 44 4d 46 44  | store it..LDMFD|
00000a60  09 73 70 21 2c 7b 50 43  7d 0a 0a 53 65 72 76 69  |.sp!,{PC}..Servi|
00000a70  63 65 5f 53 74 61 72 74  57 69 6d 70 0a 09 4c 44  |ce_StartWimp..LD|
00000a80  52 09 72 31 34 2c 5b 72  31 32 2c 23 54 61 73 6b  |R.r14,[r12,#Task|
00000a90  48 61 6e 64 6c 65 5d 09  09 3b 20 67 65 74 20 74  |Handle]..; get t|
00000aa0  61 73 6b 20 68 61 6e 64  6c 65 0a 09 54 45 51 09  |ask handle..TEQ.|
00000ab0  72 31 34 2c 23 30 09 09  09 09 3b 20 61 72 65 20  |r14,#0....; are |
00000ac0  77 65 20 72 75 6e 6e 69  6e 67 3f 0a 09 4d 56 4e  |we running?..MVN|
00000ad0  45 51 09 72 31 34 2c 23  30 09 09 09 09 3b 20 69  |EQ.r14,#0....; i|
00000ae0  66 20 6e 6f 74 2c 20 73  65 74 20 68 61 6e 64 6c  |f not, set handl|
00000af0  65 20 74 6f 20 2d 31 0a  09 53 54 52 45 51 09 72  |e to -1..STREQ.r|
00000b00  31 34 2c 5b 72 31 32 2c  23 54 61 73 6b 48 61 6e  |14,[r12,#TaskHan|
00000b10  64 6c 65 5d 0a 09 41 44  52 45 51 09 72 30 2c 52  |dle]..ADREQ.r0,R|
00000b20  4d 5f 48 43 5f 54 61 62  6c 65 09 09 09 3b 20 70  |M_HC_Table...; p|
00000b30  6f 69 6e 74 20 72 30 20  74 6f 20 73 74 61 72 74  |oint r0 to start|
00000b40  20 63 6f 6d 6d 61 6e 64  0a 09 4d 4f 56 45 51 09  | command..MOVEQ.|
00000b50  72 31 2c 23 30 09 09 09  09 3b 20 61 6e 64 20 63  |r1,#0....; and c|
00000b60  6c 61 69 6d 20 74 68 65  20 73 65 72 76 69 63 65  |laim the service|
00000b70  0a 09 4c 44 4d 46 44 09  73 70 21 2c 7b 50 43 7d  |..LDMFD.sp!,{PC}|
00000b80  0a 0a 53 65 72 76 69 63  65 5f 53 74 61 72 74 65  |..Service_Starte|
00000b90  64 57 69 6d 70 0a 09 4c  44 52 09 72 31 34 2c 5b  |dWimp..LDR.r14,[|
00000ba0  72 31 32 2c 23 54 61 73  6b 48 61 6e 64 6c 65 5d  |r12,#TaskHandle]|
00000bb0  0a 09 43 4d 4e 09 72 31  34 2c 23 31 09 09 09 09  |..CMN.r14,#1....|
00000bc0  3b 20 69 73 20 74 61 73  6b 68 61 6e 64 6c 65 20  |; is taskhandle |
00000bd0  2d 31 3f 0a 09 4d 4f 56  45 51 09 72 31 34 2c 23  |-1?..MOVEQ.r14,#|
00000be0  30 09 09 09 09 3b 20 69  66 20 73 6f 2c 20 7a 65  |0....; if so, ze|
00000bf0  72 6f 20 69 74 0a 09 53  54 52 45 51 09 72 31 34  |ro it..STREQ.r14|
00000c00  2c 5b 72 31 32 2c 23 54  61 73 6b 48 61 6e 64 6c  |,[r12,#TaskHandl|
00000c10  65 5d 0a 09 4c 44 4d 46  44 09 73 70 21 2c 7b 50  |e]..LDMFD.sp!,{P|
00000c20  43 7d 0a 0a 52 4d 5f 48  43 5f 54 61 62 6c 65 0a  |C}..RM_HC_Table.|
00000c30  09 3d 09 22 44 65 73 6b  74 6f 70 5f 49 70 68 22  |.=."Desktop_Iph"|
00000c40  2c 30 0a 09 41 4c 49 47  4e 0a 09 44 43 44 09 53  |,0..ALIGN..DCD.S|
00000c50  74 61 72 43 6f 6d 6d 61  6e 64 2d 4d 6f 64 42 61  |tarCommand-ModBa|
00000c60  73 65 0a 09 44 43 44 09  30 0a 09 44 43 44 09 30  |se..DCD.0..DCD.0|
00000c70  0a 09 44 43 44 09 44 6f  4e 6f 74 55 73 65 2d 4d  |..DCD.DoNotUse-M|
00000c80  6f 64 42 61 73 65 0a 09  3d 09 30 0a 09 41 4c 49  |odBase..=.0..ALI|
00000c90  47 4e 0a 0a 44 6f 4e 6f  74 55 73 65 0a 09 3d 09  |GN..DoNotUse..=.|
00000ca0  22 44 6f 20 6e 6f 74 20  75 73 65 20 2a 44 65 73  |"Do not use *Des|
00000cb0  6b 74 6f 70 5f 49 70 68  2c 20 75 73 65 20 2a 44  |ktop_Iph, use *D|
00000cc0  65 73 6b 74 6f 70 20 69  6e 73 74 65 61 64 2e 22  |esktop instead."|
00000cd0  2c 30 0a 09 41 4c 49 47  4e 0a 0a 53 74 61 72 43  |,0..ALIGN..StarC|
00000ce0  6f 6d 6d 61 6e 64 0a 09  53 54 4d 46 44 09 73 70  |ommand..STMFD.sp|
00000cf0  21 2c 7b 72 31 34 7d 0a  09 4d 4f 56 09 72 32 2c  |!,{r14}..MOV.r2,|
00000d00  72 30 09 09 09 3b 20 70  61 72 61 6d 65 74 65 72  |r0...; parameter|
00000d10  73 0a 09 41 44 52 09 72  31 2c 52 4d 5f 54 69 74  |s..ADR.r1,RM_Tit|
00000d20  6c 65 0a 09 4d 4f 56 09  52 30 2c 23 32 09 09 09  |le..MOV.R0,#2...|
00000d30  3b 20 65 6e 74 65 72 20  61 73 20 6c 61 6e 67 75  |; enter as langu|
00000d40  61 67 65 0a 09 53 57 49  09 58 4f 53 5f 4d 6f 64  |age..SWI.XOS_Mod|
00000d50  75 6c 65 0a 09 4c 44 4d  46 44 09 73 70 21 2c 7b  |ule..LDMFD.sp!,{|
00000d60  50 43 7d 0a 0a 54 61 73  6b 09 3d 09 22 54 41 53  |PC}..Task.=."TAS|
00000d70  4b 22 0a 0a 4d 73 67 5f  4c 69 73 74 0a 09 44 43  |K"..Msg_List..DC|
00000d80  44 09 30 0a 0a 20 20 20  20 20 20 20 20 45 4e 44  |D.0..        END|
00000d90  0a                                                |.|
00000d91