-
Notifications
You must be signed in to change notification settings - Fork 0
/
security.asm
41 lines (32 loc) · 1.38 KB
/
security.asm
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
;--------------------------------------------------------
; COPYRIGHT (C) HARRY CLARK 2024
;--------------------------------------------------------
; GENERIC SEGA MEGA CD LOADER
;--------------------------------------------------------
;--------------------------------------------------------
; THIS FILE PERTAINS TOWARDS THE SECURITY FEATURES
; SUCH AS GENERIC TMSS AND OTHER CHECKERS
;--------------------------------------------------------
INCLUDE "macros.asm"
;--------------------------------------------------------
; DEFINE THE CONSTANTS NECESSARY FOR DETERMINING
; THE CORRECT BIOS BOOT REGION
;--------------------------------------------------------
; THIS WORKS UNDER THE GUISE OF ASSUMING THAT
; ALL CODE EXECUTES FROM THE SECURITY SECTOR BEFOREHAND
; BEFORE BOOTING INTO THE DESIGNATED REGION
;--------------------------------------------------------
SECURITY_SEC:
;INCBIN "security/jap.bin"
;INCBIN "security/usa.bin"
INCBIN "security/eur.bin"
BRA INIT_PROG
ALIGN $600 ;; MATCHES THE REGION AFTER COMPILE TIME
INIT_PROG:
MOVE.L #$C0000000, $C00004
MOVE.L #64, D0
SET_PAL_LOOP:
MOVE.W #$0F00, $C00000
DBF D0, SET_PAL_LOOP
INITLOOP:
BRA INITLOOP