mirror of
https://github.com/FireEmblemUniverse/fireemblem8u.git
synced 2024-11-27 07:00:21 +00:00
Merge pull request #16 from ProjectRevoTPP/split_asm
split more asm files and merge sources
This commit is contained in:
commit
0736f5b306
318
asm/IO.s
318
asm/IO.s
@ -1,318 +0,0 @@
|
||||
.INCLUDE "macro.inc"
|
||||
|
||||
.SYNTAX UNIFIED
|
||||
|
||||
THUMB_FUNC_START SetInterrupt_LCDVBlank
|
||||
SetInterrupt_LCDVBlank: @ 0x08001258
|
||||
push {lr}
|
||||
adds r3, r0, #0
|
||||
cmp r3, #0
|
||||
beq _08001284
|
||||
ldr r2, _0800127C @ gUnknown_03003080
|
||||
ldrb r0, [r2, #4]
|
||||
movs r1, #8
|
||||
orrs r0, r1
|
||||
strb r0, [r2, #4]
|
||||
movs r0, #0
|
||||
adds r1, r3, #0
|
||||
bl SetIRQHandler
|
||||
ldr r2, _08001280 @ 0x04000200
|
||||
ldrh r0, [r2]
|
||||
movs r1, #1
|
||||
orrs r0, r1
|
||||
b _08001298
|
||||
.align 2, 0
|
||||
_0800127C: .4byte gUnknown_03003080
|
||||
_08001280: .4byte 0x04000200
|
||||
_08001284:
|
||||
ldr r2, _080012A0 @ gUnknown_03003080
|
||||
ldrb r1, [r2, #4]
|
||||
movs r0, #9
|
||||
rsbs r0, r0, #0
|
||||
ands r0, r1
|
||||
strb r0, [r2, #4]
|
||||
ldr r2, _080012A4 @ 0x04000200
|
||||
ldrh r1, [r2]
|
||||
ldr r0, _080012A8 @ 0x0000FFFE
|
||||
ands r0, r1
|
||||
_08001298:
|
||||
strh r0, [r2]
|
||||
pop {r0}
|
||||
bx r0
|
||||
.align 2, 0
|
||||
_080012A0: .4byte gUnknown_03003080
|
||||
_080012A4: .4byte 0x04000200
|
||||
_080012A8: .4byte 0x0000FFFE
|
||||
|
||||
THUMB_FUNC_START SetInterrupt_LCDVCountMatch
|
||||
SetInterrupt_LCDVCountMatch: @ 0x080012AC
|
||||
push {r4, lr}
|
||||
adds r4, r0, #0
|
||||
cmp r4, #0
|
||||
beq _080012DC
|
||||
ldr r2, _080012D4 @ gUnknown_03003080
|
||||
ldrb r0, [r2, #4]
|
||||
movs r1, #0x20
|
||||
orrs r0, r1
|
||||
strb r0, [r2, #4]
|
||||
movs r0, #2
|
||||
adds r1, r4, #0
|
||||
bl SetIRQHandler
|
||||
ldr r2, _080012D8 @ 0x04000200
|
||||
ldrh r0, [r2]
|
||||
movs r1, #4
|
||||
orrs r0, r1
|
||||
strh r0, [r2]
|
||||
b _080012F4
|
||||
.align 2, 0
|
||||
_080012D4: .4byte gUnknown_03003080
|
||||
_080012D8: .4byte 0x04000200
|
||||
_080012DC:
|
||||
ldr r2, _080012FC @ gUnknown_03003080
|
||||
ldrb r1, [r2, #4]
|
||||
movs r0, #0x21
|
||||
rsbs r0, r0, #0
|
||||
ands r0, r1
|
||||
strb r0, [r2, #4]
|
||||
ldr r3, _08001300 @ 0x04000200
|
||||
ldrh r1, [r3]
|
||||
ldr r0, _08001304 @ 0x0000FFFB
|
||||
ands r0, r1
|
||||
strh r0, [r3]
|
||||
strb r4, [r2, #5]
|
||||
_080012F4:
|
||||
pop {r4}
|
||||
pop {r0}
|
||||
bx r0
|
||||
.align 2, 0
|
||||
_080012FC: .4byte gUnknown_03003080
|
||||
_08001300: .4byte 0x04000200
|
||||
_08001304: .4byte 0x0000FFFB
|
||||
|
||||
THUMB_FUNC_START sub_8001308
|
||||
sub_8001308: @ 0x08001308
|
||||
ldr r2, _08001318 @ 0x04000004
|
||||
ldrb r1, [r2]
|
||||
lsls r0, r0, #8
|
||||
orrs r1, r0
|
||||
lsls r1, r1, #0x10
|
||||
lsrs r1, r1, #0x10
|
||||
strh r1, [r2]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_08001318: .4byte 0x04000004
|
||||
|
||||
THUMB_FUNC_START SetLCDVCountSetting
|
||||
SetLCDVCountSetting: @ 0x0800131C
|
||||
ldr r1, _08001324 @ gUnknown_03003080
|
||||
strb r0, [r1, #5]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_08001324: .4byte gUnknown_03003080
|
||||
|
||||
THUMB_FUNC_START SetMainUpdateRoutine
|
||||
SetMainUpdateRoutine: @ 0x08001328
|
||||
ldr r1, _08001330 @ gUnknown_02024CB8
|
||||
str r0, [r1]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_08001330: .4byte gUnknown_02024CB8
|
||||
|
||||
THUMB_FUNC_START ExecMainUpdate
|
||||
ExecMainUpdate: @ 0x08001334
|
||||
push {lr}
|
||||
ldr r0, _08001348 @ gUnknown_02024CB8
|
||||
ldr r0, [r0]
|
||||
cmp r0, #0
|
||||
beq _08001342
|
||||
bl _call_via_r0
|
||||
_08001342:
|
||||
pop {r0}
|
||||
bx r0
|
||||
.align 2, 0
|
||||
_08001348: .4byte gUnknown_02024CB8
|
||||
|
||||
THUMB_FUNC_START _UpdateKeyStatus
|
||||
_UpdateKeyStatus: @ 0x0800134C
|
||||
push {r4, r5, lr}
|
||||
adds r2, r0, #0
|
||||
lsls r1, r1, #0x10
|
||||
lsrs r5, r1, #0x10
|
||||
ldrh r1, [r2, #4]
|
||||
strh r1, [r2, #0xa]
|
||||
strh r5, [r2, #4]
|
||||
adds r0, r5, #0
|
||||
bics r0, r1
|
||||
strh r0, [r2, #6]
|
||||
strh r0, [r2, #8]
|
||||
cmp r0, #0
|
||||
beq _08001368
|
||||
strh r5, [r2, #0xc]
|
||||
_08001368:
|
||||
movs r0, #0
|
||||
strh r0, [r2, #0xe]
|
||||
ldrh r0, [r2, #4]
|
||||
adds r3, r0, #0
|
||||
cmp r3, #0
|
||||
bne _0800138C
|
||||
ldrh r4, [r2, #0xc]
|
||||
cmp r4, #0
|
||||
beq _08001386
|
||||
ldrh r1, [r2, #0xa]
|
||||
ldr r0, _080013A8 @ 0x00000303
|
||||
ands r0, r1
|
||||
cmp r4, r0
|
||||
bne _08001386
|
||||
strh r1, [r2, #0xe]
|
||||
_08001386:
|
||||
lsls r0, r3, #0x10
|
||||
cmp r0, #0
|
||||
beq _080013AC
|
||||
_0800138C:
|
||||
lsls r0, r3, #0x10
|
||||
lsrs r0, r0, #0x10
|
||||
ldrh r1, [r2, #0xa]
|
||||
cmp r0, r1
|
||||
bne _080013AC
|
||||
ldrb r0, [r2, #2]
|
||||
subs r0, #1
|
||||
strb r0, [r2, #2]
|
||||
lsls r0, r0, #0x18
|
||||
cmp r0, #0
|
||||
bne _080013B0
|
||||
strh r3, [r2, #6]
|
||||
ldrb r0, [r2, #1]
|
||||
b _080013AE
|
||||
.align 2, 0
|
||||
_080013A8: .4byte 0x00000303
|
||||
_080013AC:
|
||||
ldrb r0, [r2]
|
||||
_080013AE:
|
||||
strb r0, [r2, #2]
|
||||
_080013B0:
|
||||
ldrh r0, [r2, #0x10]
|
||||
eors r0, r3
|
||||
ands r0, r3
|
||||
strh r0, [r2, #0x10]
|
||||
ldr r0, _080013C4 @ 0x000003F3
|
||||
ands r0, r5
|
||||
cmp r0, #0
|
||||
beq _080013C8
|
||||
movs r0, #0
|
||||
b _080013D2
|
||||
.align 2, 0
|
||||
_080013C4: .4byte 0x000003F3
|
||||
_080013C8:
|
||||
ldrh r1, [r2, #0x12]
|
||||
ldr r0, _080013DC @ 0x0000FFFE
|
||||
cmp r1, r0
|
||||
bhi _080013D4
|
||||
adds r0, r1, #1
|
||||
_080013D2:
|
||||
strh r0, [r2, #0x12]
|
||||
_080013D4:
|
||||
pop {r4, r5}
|
||||
pop {r0}
|
||||
bx r0
|
||||
.align 2, 0
|
||||
_080013DC: .4byte 0x0000FFFE
|
||||
|
||||
THUMB_FUNC_START UpdateKeyStatus
|
||||
UpdateKeyStatus: @ 0x080013E0
|
||||
push {lr}
|
||||
adds r2, r0, #0
|
||||
ldr r0, _0800140C @ 0x04000130
|
||||
ldrh r0, [r0]
|
||||
mvns r0, r0
|
||||
lsls r0, r0, #0x16
|
||||
lsrs r1, r0, #0x16
|
||||
movs r0, #0xf
|
||||
ands r0, r1
|
||||
cmp r0, #0xf
|
||||
beq _080013FC
|
||||
ldr r0, _08001410 @ gUnknown_03000010
|
||||
ldrh r0, [r0]
|
||||
bics r1, r0
|
||||
_080013FC:
|
||||
lsls r1, r1, #0x10
|
||||
asrs r1, r1, #0x10
|
||||
adds r0, r2, #0
|
||||
bl _UpdateKeyStatus
|
||||
pop {r0}
|
||||
bx r0
|
||||
.align 2, 0
|
||||
_0800140C: .4byte 0x04000130
|
||||
_08001410: .4byte gUnknown_03000010
|
||||
|
||||
THUMB_FUNC_START sub_8001414
|
||||
sub_8001414: @ 0x08001414
|
||||
movs r1, #0
|
||||
strh r1, [r0, #8]
|
||||
strh r1, [r0, #6]
|
||||
strh r1, [r0, #4]
|
||||
bx lr
|
||||
|
||||
THUMB_FUNC_START ResetKeyStatus
|
||||
ResetKeyStatus: @ 0x08001420
|
||||
movs r2, #0
|
||||
movs r1, #0xc
|
||||
strb r1, [r0]
|
||||
movs r1, #4
|
||||
strb r1, [r0, #1]
|
||||
movs r1, #0
|
||||
strh r2, [r0, #0xa]
|
||||
strh r2, [r0, #4]
|
||||
strh r2, [r0, #8]
|
||||
strb r1, [r0, #2]
|
||||
strh r2, [r0, #0x12]
|
||||
ldr r0, _0800143C @ gUnknown_03000010
|
||||
strh r2, [r0]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_0800143C: .4byte gUnknown_03000010
|
||||
|
||||
THUMB_FUNC_START SetKeyStatus_IgnoreMask
|
||||
SetKeyStatus_IgnoreMask: @ 0x08001440
|
||||
ldr r1, _08001448 @ gUnknown_03000010
|
||||
strh r0, [r1]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_08001448: .4byte gUnknown_03000010
|
||||
|
||||
THUMB_FUNC_START GetKeyStatus_IgnoreMask
|
||||
GetKeyStatus_IgnoreMask: @ 0x0800144C
|
||||
ldr r0, _08001454 @ gUnknown_03000010
|
||||
ldrh r0, [r0]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_08001454: .4byte gUnknown_03000010
|
||||
|
||||
THUMB_FUNC_START KeyStatusSetter_Set
|
||||
KeyStatusSetter_Set: @ 0x08001458
|
||||
ldr r1, _0800146C @ gUnknown_0858791C
|
||||
ldr r2, [r1]
|
||||
adds r0, #0x64
|
||||
ldrh r1, [r0]
|
||||
strh r1, [r2, #8]
|
||||
ldrh r1, [r0]
|
||||
strh r1, [r2, #6]
|
||||
ldrh r0, [r0]
|
||||
strh r0, [r2, #4]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_0800146C: .4byte gUnknown_0858791C
|
||||
|
||||
THUMB_FUNC_START NewKeyStatusSetter
|
||||
NewKeyStatusSetter: @ 0x08001470
|
||||
push {r4, lr}
|
||||
adds r4, r0, #0
|
||||
ldr r0, _08001488 @ gUnknown_08587920
|
||||
movs r1, #1
|
||||
bl Proc_Create
|
||||
adds r0, #0x64
|
||||
strh r4, [r0]
|
||||
pop {r4}
|
||||
pop {r0}
|
||||
bx r0
|
||||
.align 2, 0
|
||||
_08001488: .4byte gUnknown_08587920
|
3346
asm/code.s
3346
asm/code.s
File diff suppressed because it is too large
Load Diff
1200
asm/rom_800148C.s → asm/dma.s
Normal file → Executable file
1200
asm/rom_800148C.s → asm/dma.s
Normal file → Executable file
File diff suppressed because it is too large
Load Diff
3066
asm/fontgrp.s
Executable file
3066
asm/fontgrp.s
Executable file
File diff suppressed because it is too large
Load Diff
315
asm/graphics.s → asm/hardware.s
Normal file → Executable file
315
asm/graphics.s → asm/hardware.s
Normal file → Executable file
@ -627,3 +627,318 @@ RegisterBlankTile: @ 0x08001240
|
||||
bl RegisterFillTile
|
||||
pop {r0}
|
||||
bx r0
|
||||
|
||||
THUMB_FUNC_START SetInterrupt_LCDVBlank
|
||||
SetInterrupt_LCDVBlank: @ 0x08001258
|
||||
push {lr}
|
||||
adds r3, r0, #0
|
||||
cmp r3, #0
|
||||
beq _08001284
|
||||
ldr r2, _0800127C @ gUnknown_03003080
|
||||
ldrb r0, [r2, #4]
|
||||
movs r1, #8
|
||||
orrs r0, r1
|
||||
strb r0, [r2, #4]
|
||||
movs r0, #0
|
||||
adds r1, r3, #0
|
||||
bl SetIRQHandler
|
||||
ldr r2, _08001280 @ 0x04000200
|
||||
ldrh r0, [r2]
|
||||
movs r1, #1
|
||||
orrs r0, r1
|
||||
b _08001298
|
||||
.align 2, 0
|
||||
_0800127C: .4byte gUnknown_03003080
|
||||
_08001280: .4byte 0x04000200
|
||||
_08001284:
|
||||
ldr r2, _080012A0 @ gUnknown_03003080
|
||||
ldrb r1, [r2, #4]
|
||||
movs r0, #9
|
||||
rsbs r0, r0, #0
|
||||
ands r0, r1
|
||||
strb r0, [r2, #4]
|
||||
ldr r2, _080012A4 @ 0x04000200
|
||||
ldrh r1, [r2]
|
||||
ldr r0, _080012A8 @ 0x0000FFFE
|
||||
ands r0, r1
|
||||
_08001298:
|
||||
strh r0, [r2]
|
||||
pop {r0}
|
||||
bx r0
|
||||
.align 2, 0
|
||||
_080012A0: .4byte gUnknown_03003080
|
||||
_080012A4: .4byte 0x04000200
|
||||
_080012A8: .4byte 0x0000FFFE
|
||||
|
||||
THUMB_FUNC_START SetInterrupt_LCDVCountMatch
|
||||
SetInterrupt_LCDVCountMatch: @ 0x080012AC
|
||||
push {r4, lr}
|
||||
adds r4, r0, #0
|
||||
cmp r4, #0
|
||||
beq _080012DC
|
||||
ldr r2, _080012D4 @ gUnknown_03003080
|
||||
ldrb r0, [r2, #4]
|
||||
movs r1, #0x20
|
||||
orrs r0, r1
|
||||
strb r0, [r2, #4]
|
||||
movs r0, #2
|
||||
adds r1, r4, #0
|
||||
bl SetIRQHandler
|
||||
ldr r2, _080012D8 @ 0x04000200
|
||||
ldrh r0, [r2]
|
||||
movs r1, #4
|
||||
orrs r0, r1
|
||||
strh r0, [r2]
|
||||
b _080012F4
|
||||
.align 2, 0
|
||||
_080012D4: .4byte gUnknown_03003080
|
||||
_080012D8: .4byte 0x04000200
|
||||
_080012DC:
|
||||
ldr r2, _080012FC @ gUnknown_03003080
|
||||
ldrb r1, [r2, #4]
|
||||
movs r0, #0x21
|
||||
rsbs r0, r0, #0
|
||||
ands r0, r1
|
||||
strb r0, [r2, #4]
|
||||
ldr r3, _08001300 @ 0x04000200
|
||||
ldrh r1, [r3]
|
||||
ldr r0, _08001304 @ 0x0000FFFB
|
||||
ands r0, r1
|
||||
strh r0, [r3]
|
||||
strb r4, [r2, #5]
|
||||
_080012F4:
|
||||
pop {r4}
|
||||
pop {r0}
|
||||
bx r0
|
||||
.align 2, 0
|
||||
_080012FC: .4byte gUnknown_03003080
|
||||
_08001300: .4byte 0x04000200
|
||||
_08001304: .4byte 0x0000FFFB
|
||||
|
||||
THUMB_FUNC_START sub_8001308
|
||||
sub_8001308: @ 0x08001308
|
||||
ldr r2, _08001318 @ 0x04000004
|
||||
ldrb r1, [r2]
|
||||
lsls r0, r0, #8
|
||||
orrs r1, r0
|
||||
lsls r1, r1, #0x10
|
||||
lsrs r1, r1, #0x10
|
||||
strh r1, [r2]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_08001318: .4byte 0x04000004
|
||||
|
||||
THUMB_FUNC_START SetLCDVCountSetting
|
||||
SetLCDVCountSetting: @ 0x0800131C
|
||||
ldr r1, _08001324 @ gUnknown_03003080
|
||||
strb r0, [r1, #5]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_08001324: .4byte gUnknown_03003080
|
||||
|
||||
THUMB_FUNC_START SetMainUpdateRoutine
|
||||
SetMainUpdateRoutine: @ 0x08001328
|
||||
ldr r1, _08001330 @ gUnknown_02024CB8
|
||||
str r0, [r1]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_08001330: .4byte gUnknown_02024CB8
|
||||
|
||||
THUMB_FUNC_START ExecMainUpdate
|
||||
ExecMainUpdate: @ 0x08001334
|
||||
push {lr}
|
||||
ldr r0, _08001348 @ gUnknown_02024CB8
|
||||
ldr r0, [r0]
|
||||
cmp r0, #0
|
||||
beq _08001342
|
||||
bl _call_via_r0
|
||||
_08001342:
|
||||
pop {r0}
|
||||
bx r0
|
||||
.align 2, 0
|
||||
_08001348: .4byte gUnknown_02024CB8
|
||||
|
||||
THUMB_FUNC_START _UpdateKeyStatus
|
||||
_UpdateKeyStatus: @ 0x0800134C
|
||||
push {r4, r5, lr}
|
||||
adds r2, r0, #0
|
||||
lsls r1, r1, #0x10
|
||||
lsrs r5, r1, #0x10
|
||||
ldrh r1, [r2, #4]
|
||||
strh r1, [r2, #0xa]
|
||||
strh r5, [r2, #4]
|
||||
adds r0, r5, #0
|
||||
bics r0, r1
|
||||
strh r0, [r2, #6]
|
||||
strh r0, [r2, #8]
|
||||
cmp r0, #0
|
||||
beq _08001368
|
||||
strh r5, [r2, #0xc]
|
||||
_08001368:
|
||||
movs r0, #0
|
||||
strh r0, [r2, #0xe]
|
||||
ldrh r0, [r2, #4]
|
||||
adds r3, r0, #0
|
||||
cmp r3, #0
|
||||
bne _0800138C
|
||||
ldrh r4, [r2, #0xc]
|
||||
cmp r4, #0
|
||||
beq _08001386
|
||||
ldrh r1, [r2, #0xa]
|
||||
ldr r0, _080013A8 @ 0x00000303
|
||||
ands r0, r1
|
||||
cmp r4, r0
|
||||
bne _08001386
|
||||
strh r1, [r2, #0xe]
|
||||
_08001386:
|
||||
lsls r0, r3, #0x10
|
||||
cmp r0, #0
|
||||
beq _080013AC
|
||||
_0800138C:
|
||||
lsls r0, r3, #0x10
|
||||
lsrs r0, r0, #0x10
|
||||
ldrh r1, [r2, #0xa]
|
||||
cmp r0, r1
|
||||
bne _080013AC
|
||||
ldrb r0, [r2, #2]
|
||||
subs r0, #1
|
||||
strb r0, [r2, #2]
|
||||
lsls r0, r0, #0x18
|
||||
cmp r0, #0
|
||||
bne _080013B0
|
||||
strh r3, [r2, #6]
|
||||
ldrb r0, [r2, #1]
|
||||
b _080013AE
|
||||
.align 2, 0
|
||||
_080013A8: .4byte 0x00000303
|
||||
_080013AC:
|
||||
ldrb r0, [r2]
|
||||
_080013AE:
|
||||
strb r0, [r2, #2]
|
||||
_080013B0:
|
||||
ldrh r0, [r2, #0x10]
|
||||
eors r0, r3
|
||||
ands r0, r3
|
||||
strh r0, [r2, #0x10]
|
||||
ldr r0, _080013C4 @ 0x000003F3
|
||||
ands r0, r5
|
||||
cmp r0, #0
|
||||
beq _080013C8
|
||||
movs r0, #0
|
||||
b _080013D2
|
||||
.align 2, 0
|
||||
_080013C4: .4byte 0x000003F3
|
||||
_080013C8:
|
||||
ldrh r1, [r2, #0x12]
|
||||
ldr r0, _080013DC @ 0x0000FFFE
|
||||
cmp r1, r0
|
||||
bhi _080013D4
|
||||
adds r0, r1, #1
|
||||
_080013D2:
|
||||
strh r0, [r2, #0x12]
|
||||
_080013D4:
|
||||
pop {r4, r5}
|
||||
pop {r0}
|
||||
bx r0
|
||||
.align 2, 0
|
||||
_080013DC: .4byte 0x0000FFFE
|
||||
|
||||
THUMB_FUNC_START UpdateKeyStatus
|
||||
UpdateKeyStatus: @ 0x080013E0
|
||||
push {lr}
|
||||
adds r2, r0, #0
|
||||
ldr r0, _0800140C @ 0x04000130
|
||||
ldrh r0, [r0]
|
||||
mvns r0, r0
|
||||
lsls r0, r0, #0x16
|
||||
lsrs r1, r0, #0x16
|
||||
movs r0, #0xf
|
||||
ands r0, r1
|
||||
cmp r0, #0xf
|
||||
beq _080013FC
|
||||
ldr r0, _08001410 @ gUnknown_03000010
|
||||
ldrh r0, [r0]
|
||||
bics r1, r0
|
||||
_080013FC:
|
||||
lsls r1, r1, #0x10
|
||||
asrs r1, r1, #0x10
|
||||
adds r0, r2, #0
|
||||
bl _UpdateKeyStatus
|
||||
pop {r0}
|
||||
bx r0
|
||||
.align 2, 0
|
||||
_0800140C: .4byte 0x04000130
|
||||
_08001410: .4byte gUnknown_03000010
|
||||
|
||||
THUMB_FUNC_START sub_8001414
|
||||
sub_8001414: @ 0x08001414
|
||||
movs r1, #0
|
||||
strh r1, [r0, #8]
|
||||
strh r1, [r0, #6]
|
||||
strh r1, [r0, #4]
|
||||
bx lr
|
||||
|
||||
THUMB_FUNC_START ResetKeyStatus
|
||||
ResetKeyStatus: @ 0x08001420
|
||||
movs r2, #0
|
||||
movs r1, #0xc
|
||||
strb r1, [r0]
|
||||
movs r1, #4
|
||||
strb r1, [r0, #1]
|
||||
movs r1, #0
|
||||
strh r2, [r0, #0xa]
|
||||
strh r2, [r0, #4]
|
||||
strh r2, [r0, #8]
|
||||
strb r1, [r0, #2]
|
||||
strh r2, [r0, #0x12]
|
||||
ldr r0, _0800143C @ gUnknown_03000010
|
||||
strh r2, [r0]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_0800143C: .4byte gUnknown_03000010
|
||||
|
||||
THUMB_FUNC_START SetKeyStatus_IgnoreMask
|
||||
SetKeyStatus_IgnoreMask: @ 0x08001440
|
||||
ldr r1, _08001448 @ gUnknown_03000010
|
||||
strh r0, [r1]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_08001448: .4byte gUnknown_03000010
|
||||
|
||||
THUMB_FUNC_START GetKeyStatus_IgnoreMask
|
||||
GetKeyStatus_IgnoreMask: @ 0x0800144C
|
||||
ldr r0, _08001454 @ gUnknown_03000010
|
||||
ldrh r0, [r0]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_08001454: .4byte gUnknown_03000010
|
||||
|
||||
THUMB_FUNC_START KeyStatusSetter_Set
|
||||
KeyStatusSetter_Set: @ 0x08001458
|
||||
ldr r1, _0800146C @ gUnknown_0858791C
|
||||
ldr r2, [r1]
|
||||
adds r0, #0x64
|
||||
ldrh r1, [r0]
|
||||
strh r1, [r2, #8]
|
||||
ldrh r1, [r0]
|
||||
strh r1, [r2, #6]
|
||||
ldrh r0, [r0]
|
||||
strh r0, [r2, #4]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_0800146C: .4byte gUnknown_0858791C
|
||||
|
||||
THUMB_FUNC_START NewKeyStatusSetter
|
||||
NewKeyStatusSetter: @ 0x08001470
|
||||
push {r4, lr}
|
||||
adds r4, r0, #0
|
||||
ldr r0, _08001488 @ gUnknown_08587920
|
||||
movs r1, #1
|
||||
bl Proc_Create
|
||||
adds r0, #0x64
|
||||
strh r4, [r0]
|
||||
pop {r4}
|
||||
pop {r0}
|
||||
bx r0
|
||||
.align 2, 0
|
||||
_08001488: .4byte gUnknown_08587920
|
286
asm/icon.s
Executable file
286
asm/icon.s
Executable file
@ -0,0 +1,286 @@
|
||||
.INCLUDE "macro.inc"
|
||||
|
||||
.SYNTAX UNIFIED
|
||||
|
||||
THUMB_FUNC_START ResetIconGraphics_
|
||||
ResetIconGraphics_: @ 0x08003578
|
||||
push {lr}
|
||||
bl ResetIconGraphics
|
||||
pop {r0}
|
||||
bx r0
|
||||
|
||||
THUMB_FUNC_START ResetIconGraphics
|
||||
ResetIconGraphics: @ 0x08003584
|
||||
push {r4, lr}
|
||||
sub sp, #4
|
||||
mov r0, sp
|
||||
movs r4, #0
|
||||
strh r4, [r0]
|
||||
ldr r1, _080035AC @ gUnknown_02026A90
|
||||
ldr r2, _080035B0 @ 0x010001C0
|
||||
bl CpuSet
|
||||
mov r0, sp
|
||||
adds r0, #2
|
||||
strh r4, [r0]
|
||||
ldr r1, _080035B4 @ gUnknown_02026E10
|
||||
ldr r2, _080035B8 @ 0x01000010
|
||||
bl CpuSet
|
||||
add sp, #4
|
||||
pop {r4}
|
||||
pop {r0}
|
||||
bx r0
|
||||
.align 2, 0
|
||||
_080035AC: .4byte gUnknown_02026A90
|
||||
_080035B0: .4byte 0x010001C0
|
||||
_080035B4: .4byte gUnknown_02026E10
|
||||
_080035B8: .4byte 0x01000010
|
||||
|
||||
THUMB_FUNC_START LoadIconPalettes
|
||||
LoadIconPalettes: @ 0x080035BC
|
||||
push {lr}
|
||||
adds r1, r0, #0
|
||||
ldr r0, _080035D0 @ gUnknown_085996F4
|
||||
lsls r1, r1, #5
|
||||
movs r2, #0x40
|
||||
bl CopyToPaletteBuffer
|
||||
pop {r0}
|
||||
bx r0
|
||||
.align 2, 0
|
||||
_080035D0: .4byte gUnknown_085996F4
|
||||
|
||||
THUMB_FUNC_START LoadIconPalette
|
||||
LoadIconPalette: @ 0x080035D4
|
||||
push {lr}
|
||||
lsls r0, r0, #5
|
||||
ldr r2, _080035E8 @ gUnknown_085996F4
|
||||
adds r0, r0, r2
|
||||
lsls r1, r1, #5
|
||||
movs r2, #0x20
|
||||
bl CopyToPaletteBuffer
|
||||
pop {r0}
|
||||
bx r0
|
||||
.align 2, 0
|
||||
_080035E8: .4byte gUnknown_085996F4
|
||||
|
||||
THUMB_FUNC_START sub_80035EC
|
||||
sub_80035EC: @ 0x080035EC
|
||||
push {lr}
|
||||
movs r2, #0
|
||||
movs r1, #0x1f
|
||||
ldr r3, _0800360C @ gUnknown_02026E10
|
||||
_080035F4:
|
||||
adds r0, r1, r3
|
||||
ldrb r0, [r0]
|
||||
cmp r0, #0
|
||||
beq _080035FE
|
||||
adds r2, #1
|
||||
_080035FE:
|
||||
subs r1, #1
|
||||
cmp r1, #0
|
||||
bge _080035F4
|
||||
adds r0, r2, #0
|
||||
pop {r1}
|
||||
bx r1
|
||||
.align 2, 0
|
||||
_0800360C: .4byte gUnknown_02026E10
|
||||
|
||||
THUMB_FUNC_START GetIconGfxTileIndex
|
||||
GetIconGfxTileIndex: @ 0x08003610
|
||||
adds r1, r0, #0
|
||||
lsls r1, r1, #2
|
||||
movs r2, #0xc0
|
||||
lsls r2, r2, #2
|
||||
adds r0, r2, #0
|
||||
subs r0, r0, r1
|
||||
lsls r0, r0, #0x10
|
||||
lsrs r0, r0, #0x10
|
||||
bx lr
|
||||
|
||||
THUMB_FUNC_START GetIconGfxIndex
|
||||
GetIconGfxIndex: @ 0x08003624
|
||||
push {r4, lr}
|
||||
movs r2, #0
|
||||
ldr r4, _0800363C @ gUnknown_02026E10
|
||||
adds r3, r0, #1
|
||||
_0800362C:
|
||||
adds r1, r2, r4
|
||||
ldrb r0, [r1]
|
||||
cmp r0, #0
|
||||
bne _08003640
|
||||
strb r3, [r1]
|
||||
adds r0, r2, #0
|
||||
b _0800364A
|
||||
.align 2, 0
|
||||
_0800363C: .4byte gUnknown_02026E10
|
||||
_08003640:
|
||||
adds r2, #1
|
||||
cmp r2, #0x1f
|
||||
ble _0800362C
|
||||
movs r0, #1
|
||||
rsbs r0, r0, #0
|
||||
_0800364A:
|
||||
pop {r4}
|
||||
pop {r1}
|
||||
bx r1
|
||||
|
||||
THUMB_FUNC_START GetIconTileIndex
|
||||
GetIconTileIndex: @ 0x08003650
|
||||
push {r4, r5, lr}
|
||||
adds r4, r0, #0
|
||||
ldr r0, _0800366C @ gUnknown_02026A90
|
||||
lsls r1, r4, #2
|
||||
adds r5, r1, r0
|
||||
ldrb r0, [r5, #1]
|
||||
cmp r0, #0
|
||||
beq _08003670
|
||||
ldrb r0, [r5]
|
||||
cmp r0, #0xfe
|
||||
bhi _080036A4
|
||||
adds r0, #1
|
||||
strb r0, [r5]
|
||||
b _080036A4
|
||||
.align 2, 0
|
||||
_0800366C: .4byte gUnknown_02026A90
|
||||
_08003670:
|
||||
ldrb r0, [r5]
|
||||
adds r0, #1
|
||||
strb r0, [r5]
|
||||
adds r0, r4, #0
|
||||
bl GetIconGfxIndex
|
||||
adds r0, #1
|
||||
strb r0, [r5, #1]
|
||||
lsls r4, r4, #7
|
||||
ldr r0, _080036B4 @ gUnknown_085926F4
|
||||
adds r4, r4, r0
|
||||
ldrb r0, [r5, #1]
|
||||
bl GetIconGfxTileIndex
|
||||
adds r1, r0, #0
|
||||
lsls r1, r1, #0x10
|
||||
lsrs r1, r1, #0xb
|
||||
movs r2, #0xc0
|
||||
lsls r2, r2, #0x13
|
||||
ldr r0, _080036B8 @ 0x0001FFE0
|
||||
ands r1, r0
|
||||
adds r1, r1, r2
|
||||
adds r0, r4, #0
|
||||
movs r2, #0x80
|
||||
bl RegisterTileGraphics
|
||||
_080036A4:
|
||||
ldrb r0, [r5, #1]
|
||||
bl GetIconGfxTileIndex
|
||||
lsls r0, r0, #0x10
|
||||
lsrs r0, r0, #0x10
|
||||
pop {r4, r5}
|
||||
pop {r1}
|
||||
bx r1
|
||||
.align 2, 0
|
||||
_080036B4: .4byte gUnknown_085926F4
|
||||
_080036B8: .4byte 0x0001FFE0
|
||||
|
||||
THUMB_FUNC_START DrawIcon
|
||||
DrawIcon: @ 0x080036BC
|
||||
push {r4, r5, lr}
|
||||
adds r4, r0, #0
|
||||
adds r0, r1, #0
|
||||
adds r5, r2, #0
|
||||
cmp r0, #0
|
||||
bge _080036D8
|
||||
movs r0, #0
|
||||
strh r0, [r4]
|
||||
strh r0, [r4, #2]
|
||||
adds r1, r4, #0
|
||||
adds r1, #0x40
|
||||
strh r0, [r1]
|
||||
adds r1, #2
|
||||
b _08003704
|
||||
_080036D8:
|
||||
bl GetIconTileIndex
|
||||
adds r0, r0, r5
|
||||
lsls r0, r0, #0x10
|
||||
lsrs r1, r0, #0x10
|
||||
movs r2, #0x80
|
||||
lsls r2, r2, #9
|
||||
adds r0, r0, r2
|
||||
strh r1, [r4]
|
||||
lsrs r1, r0, #0x10
|
||||
adds r0, r0, r2
|
||||
strh r1, [r4, #2]
|
||||
adds r2, r4, #0
|
||||
adds r2, #0x40
|
||||
lsrs r1, r0, #0x10
|
||||
movs r3, #0x80
|
||||
lsls r3, r3, #9
|
||||
adds r0, r0, r3
|
||||
lsrs r0, r0, #0x10
|
||||
strh r1, [r2]
|
||||
adds r1, r4, #0
|
||||
adds r1, #0x42
|
||||
_08003704:
|
||||
strh r0, [r1]
|
||||
pop {r4, r5}
|
||||
pop {r0}
|
||||
bx r0
|
||||
|
||||
THUMB_FUNC_START ClearIconGfx
|
||||
ClearIconGfx: @ 0x0800370C
|
||||
ldr r2, _08003724 @ gUnknown_02026E10
|
||||
ldr r1, _08003728 @ gUnknown_02026A90
|
||||
lsls r0, r0, #2
|
||||
adds r0, r0, r1
|
||||
ldrb r1, [r0, #1]
|
||||
subs r1, #1
|
||||
adds r1, r1, r2
|
||||
movs r2, #0
|
||||
strb r2, [r1]
|
||||
strb r2, [r0, #1]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_08003724: .4byte gUnknown_02026E10
|
||||
_08003728: .4byte gUnknown_02026A90
|
||||
|
||||
THUMB_FUNC_START LoadIconObjectGraphics
|
||||
LoadIconObjectGraphics: @ 0x0800372C
|
||||
push {r4, r5, lr}
|
||||
adds r2, r0, #0
|
||||
ldr r5, _08003758 @ 0x06010000
|
||||
ldr r0, _0800375C @ 0x000003FF
|
||||
ands r0, r1
|
||||
lsls r0, r0, #5
|
||||
adds r5, r0, r5
|
||||
cmp r2, #0
|
||||
bge _08003760
|
||||
movs r0, #0
|
||||
adds r1, r5, #0
|
||||
movs r2, #0x40
|
||||
bl RegisterFillTile
|
||||
movs r0, #0x80
|
||||
lsls r0, r0, #3
|
||||
adds r1, r5, r0
|
||||
movs r0, #0
|
||||
movs r2, #0x40
|
||||
bl RegisterFillTile
|
||||
b _08003780
|
||||
.align 2, 0
|
||||
_08003758: .4byte 0x06010000
|
||||
_0800375C: .4byte 0x000003FF
|
||||
_08003760:
|
||||
ldr r4, _08003788 @ gUnknown_085926F4
|
||||
lsls r0, r2, #7
|
||||
adds r4, r0, r4
|
||||
adds r0, r4, #0
|
||||
adds r1, r5, #0
|
||||
movs r2, #0x40
|
||||
bl RegisterTileGraphics
|
||||
adds r4, #0x40
|
||||
movs r0, #0x80
|
||||
lsls r0, r0, #3
|
||||
adds r1, r5, r0
|
||||
adds r0, r4, #0
|
||||
movs r2, #0x40
|
||||
bl RegisterTileGraphics
|
||||
_08003780:
|
||||
pop {r4, r5}
|
||||
pop {r0}
|
||||
bx r0
|
||||
.align 2, 0
|
||||
_08003788: .4byte gUnknown_085926F4
|
136
asm/ramfunc.s
Executable file
136
asm/ramfunc.s
Executable file
@ -0,0 +1,136 @@
|
||||
.INCLUDE "macro.inc"
|
||||
|
||||
.SYNTAX UNIFIED
|
||||
|
||||
THUMB_FUNC_START StoreRoutinesToIRAM
|
||||
StoreRoutinesToIRAM: @ 0x08002AF8
|
||||
push {r4, r5, lr}
|
||||
ldr r2, _08002B54 @ ARMCodeToCopy_End
|
||||
ldr r4, _08002B58 @ ARMCodeToCopy_Start
|
||||
subs r2, r2, r4
|
||||
ldr r5, _08002B5C @ gUnknown_03003750
|
||||
lsrs r0, r2, #0x1f
|
||||
adds r2, r2, r0
|
||||
lsls r2, r2, #0xa
|
||||
lsrs r2, r2, #0xb
|
||||
adds r0, r4, #0
|
||||
adds r1, r5, #0
|
||||
bl CpuSet
|
||||
ldr r1, _08002B60 @ gUnknown_03003740
|
||||
ldr r0, _08002B64 @ IRAMARM_Func3_DrawGlyph
|
||||
subs r0, r0, r4
|
||||
adds r0, r0, r5
|
||||
str r0, [r1]
|
||||
ldr r1, _08002B68 @ gUnknown_03004150
|
||||
ldr r0, _08002B6C @ IRAMARM_DecompText
|
||||
subs r0, r0, r4
|
||||
adds r0, r0, r5
|
||||
str r0, [r1]
|
||||
ldr r1, _08002B70 @ gUnknown_03003130
|
||||
ldr r0, _08002B74 @ IRAMARM_CopyToSecondaryOAM
|
||||
subs r0, r0, r4
|
||||
adds r0, r0, r5
|
||||
str r0, [r1]
|
||||
ldr r1, _08002B78 @ gUnknown_03004154
|
||||
ldr r0, _08002B7C @ IRAMARM_CopyToPrimaryOAM
|
||||
subs r0, r0, r4
|
||||
adds r0, r0, r5
|
||||
str r0, [r1]
|
||||
ldr r1, _08002B80 @ gUnknown_03004960
|
||||
ldr r0, _08002B84 @ IRAMARM_Func5
|
||||
subs r0, r0, r4
|
||||
adds r0, r0, r5
|
||||
str r0, [r1]
|
||||
ldr r1, _08002B88 @ gUnknown_03003128
|
||||
ldr r0, _08002B8C @ IRAMARM_FillMovementMap
|
||||
subs r0, r0, r4
|
||||
adds r0, r0, r5
|
||||
str r0, [r1]
|
||||
pop {r4, r5}
|
||||
pop {r0}
|
||||
bx r0
|
||||
.align 2, 0
|
||||
_08002B54: .4byte ARMCodeToCopy_End
|
||||
_08002B58: .4byte ARMCodeToCopy_Start
|
||||
_08002B5C: .4byte gUnknown_03003750
|
||||
_08002B60: .4byte gUnknown_03003740
|
||||
_08002B64: .4byte IRAMARM_Func3_DrawGlyph
|
||||
_08002B68: .4byte gUnknown_03004150
|
||||
_08002B6C: .4byte IRAMARM_DecompText
|
||||
_08002B70: .4byte gUnknown_03003130
|
||||
_08002B74: .4byte IRAMARM_CopyToSecondaryOAM
|
||||
_08002B78: .4byte gUnknown_03004154
|
||||
_08002B7C: .4byte IRAMARM_CopyToPrimaryOAM
|
||||
_08002B80: .4byte gUnknown_03004960
|
||||
_08002B84: .4byte IRAMARM_Func5
|
||||
_08002B88: .4byte gUnknown_03003128
|
||||
_08002B8C: .4byte IRAMARM_FillMovementMap
|
||||
|
||||
THUMB_FUNC_START CallARM_Func3
|
||||
CallARM_Func3: @ 0x08002B90
|
||||
push {r4, lr}
|
||||
ldr r4, _08002BA0 @ gUnknown_03003740
|
||||
ldr r4, [r4]
|
||||
bl _call_via_r4
|
||||
pop {r4}
|
||||
pop {r0}
|
||||
bx r0
|
||||
.align 2, 0
|
||||
_08002BA0: .4byte gUnknown_03003740
|
||||
|
||||
THUMB_FUNC_START CallARM_DecompText
|
||||
CallARM_DecompText: @ 0x08002BA4
|
||||
push {lr}
|
||||
ldr r2, _08002BB4 @ gUnknown_03004150
|
||||
ldr r2, [r2]
|
||||
bl _call_via_r2
|
||||
pop {r0}
|
||||
bx r0
|
||||
.align 2, 0
|
||||
_08002BB4: .4byte gUnknown_03004150
|
||||
|
||||
THUMB_FUNC_START CallARM_PushToSecondaryOAM
|
||||
CallARM_PushToSecondaryOAM: @ 0x08002BB8
|
||||
push {r4, lr}
|
||||
ldr r4, _08002BC8 @ gUnknown_03003130
|
||||
ldr r4, [r4]
|
||||
bl _call_via_r4
|
||||
pop {r4}
|
||||
pop {r0}
|
||||
bx r0
|
||||
.align 2, 0
|
||||
_08002BC8: .4byte gUnknown_03003130
|
||||
|
||||
THUMB_FUNC_START CallARM_PushToPrimaryOAM
|
||||
CallARM_PushToPrimaryOAM: @ 0x08002BCC
|
||||
push {r4, lr}
|
||||
ldr r4, _08002BDC @ gUnknown_03004154
|
||||
ldr r4, [r4]
|
||||
bl _call_via_r4
|
||||
pop {r4}
|
||||
pop {r0}
|
||||
bx r0
|
||||
.align 2, 0
|
||||
_08002BDC: .4byte gUnknown_03004154
|
||||
|
||||
THUMB_FUNC_START CallARM_Func5
|
||||
CallARM_Func5: @ 0x08002BE0
|
||||
push {lr}
|
||||
ldr r3, _08002BF0 @ gUnknown_03004960
|
||||
ldr r3, [r3]
|
||||
bl _call_via_r3
|
||||
pop {r0}
|
||||
bx r0
|
||||
.align 2, 0
|
||||
_08002BF0: .4byte gUnknown_03004960
|
||||
|
||||
THUMB_FUNC_START CallARM_FillMovementMap
|
||||
CallARM_FillMovementMap: @ 0x08002BF4
|
||||
push {lr}
|
||||
ldr r0, _08002C04 @ gUnknown_03003128
|
||||
ldr r0, [r0]
|
||||
bl _call_via_r0
|
||||
pop {r0}
|
||||
bx r0
|
||||
.align 2, 0
|
||||
_08002C04: .4byte gUnknown_03003128
|
1070
asm/soundwrapper.s
Executable file
1070
asm/soundwrapper.s
Executable file
File diff suppressed because it is too large
Load Diff
11
ldscript.txt
11
ldscript.txt
@ -28,12 +28,17 @@ SECTIONS
|
||||
asm/crt0.o(.text);
|
||||
asm/arm.o(.text);
|
||||
src/main.o(.text);
|
||||
src/fe3_dummy.o(.text);
|
||||
src/irq.o(.text);
|
||||
asm/rng.o(.text);
|
||||
asm/time.o(.text);
|
||||
asm/graphics.o(.text);
|
||||
asm/IO.o(.text);
|
||||
asm/rom_800148C.o(.text);
|
||||
asm/hardware.o(.text);
|
||||
asm/dma.o(.text);
|
||||
asm/soundwrapper.o(.text);
|
||||
asm/ramfunc.o(.text);
|
||||
src/proc.o(.text);
|
||||
asm/icon.o(.text);
|
||||
asm/fontgrp.o(.text);
|
||||
asm/code.o(.text);
|
||||
asm/m4a_1.o(.text);
|
||||
src/m4a_2.o(.text);
|
||||
|
9
src/fe3_dummy.c
Executable file
9
src/fe3_dummy.c
Executable file
@ -0,0 +1,9 @@
|
||||
#include "global.h"
|
||||
#include "functions.h"
|
||||
#include "variables.h"
|
||||
|
||||
void PrintDebugBuildDateAndTime(u16 *bg)
|
||||
{
|
||||
PrintDebugStringToBG(bg, gBuildDateTime);
|
||||
PrintDebugStringToBG(bg - 0x20, gYearProjectCreated); // subtract to print to the line above.
|
||||
}
|
27
src/irq.c
Executable file
27
src/irq.c
Executable file
@ -0,0 +1,27 @@
|
||||
#include "global.h"
|
||||
#include "functions.h"
|
||||
#include "variables.h"
|
||||
|
||||
#define IRQ_COUNT 14
|
||||
extern void *gIRQHandlers[IRQ_COUNT];
|
||||
extern u32 IntrMain_Buffer[0x200];
|
||||
|
||||
void DummyIRQRoutine(void);
|
||||
|
||||
void StoreIRQToIRAM(void)
|
||||
{
|
||||
int i;
|
||||
for(i = 0; i < IRQ_COUNT; i++)
|
||||
gIRQHandlers[i] = DummyIRQRoutine;
|
||||
|
||||
CpuFastCopy(GlobalIRQHandler, IntrMain_Buffer, sizeof IntrMain_Buffer);
|
||||
INTR_VECTOR = IntrMain_Buffer;
|
||||
}
|
||||
|
||||
void DummyIRQRoutine(void)
|
||||
{}
|
||||
|
||||
void SetIRQHandler(int index, void *irq)
|
||||
{
|
||||
gIRQHandlers[index] = irq;
|
||||
}
|
29
src/main.c
29
src/main.c
@ -2,12 +2,7 @@
|
||||
#include "functions.h"
|
||||
#include "proc.h"
|
||||
|
||||
#define IRQ_COUNT 14
|
||||
extern void *gIRQHandlers[IRQ_COUNT];
|
||||
extern u32 IntrMain_Buffer[0x200];
|
||||
|
||||
void StoreIRQToIRAM();
|
||||
void DummyIRQRoutine(void);
|
||||
|
||||
void AgbMain()
|
||||
{
|
||||
@ -50,27 +45,3 @@ void AgbMain()
|
||||
sub_8001C78();
|
||||
};
|
||||
}
|
||||
|
||||
void PrintDebugBuildDateAndTime(u16 *bg)
|
||||
{
|
||||
PrintDebugStringToBG(bg, gBuildDateTime);
|
||||
PrintDebugStringToBG(bg - 0x20, gYearProjectCreated); // subtract to print to the line above.
|
||||
}
|
||||
|
||||
void StoreIRQToIRAM(void)
|
||||
{
|
||||
int i;
|
||||
for(i = 0; i < IRQ_COUNT; i++)
|
||||
gIRQHandlers[i] = DummyIRQRoutine;
|
||||
|
||||
CpuFastCopy(GlobalIRQHandler, IntrMain_Buffer, sizeof IntrMain_Buffer);
|
||||
INTR_VECTOR = IntrMain_Buffer;
|
||||
}
|
||||
|
||||
void DummyIRQRoutine(void)
|
||||
{}
|
||||
|
||||
void SetIRQHandler(int index, void *irq)
|
||||
{
|
||||
gIRQHandlers[index] = irq;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user