init work

This commit is contained in:
Kyle J Cardoza 2024-07-11 22:41:46 -04:00
parent 65975d61fb
commit a2bf42fa01
2 changed files with 4 additions and 13 deletions

View File

@ -32,19 +32,6 @@ delay_y
dey
bne delay_y
// Set stack to $001FF
ldx ##0x01FF
txs
// Set data bank to 0
lda #0
pha
plb
// Set direct page to $0000
pea #0x0000
pld
// Enable all the in-use chip select lines.
lda #0b11110011
sta PCS7

View File

@ -32,6 +32,7 @@
.section code, noreorder
.pubweak __program_root_section
__program_root_section:
clc
xce ; native 16-bit mode
@ -51,6 +52,7 @@ __program_root_section:
.section code, noroot, noreorder
.pubweak __data_initialization_needed
.extern __initialize_sections
__data_initialization_needed:
lda ##.word2 (.sectionEnd data_init_table)
sta dp:.tiny(_Dp+6)
@ -66,6 +68,7 @@ __data_initialization_needed:
.section code, noroot, noreorder
.pubweak __call_initialize_global_streams
.extern __initialize_global_streams
__call_initialize_global_streams:
jsl long:__initialize_global_streams
@ -73,6 +76,7 @@ __call_initialize_global_streams:
.section code, noroot, noreorder
.pubweak __call_heap_initialize
.extern __heap_initialize, __default_heap
__call_heap_initialize:
lda ##.word2 (.sectionStart heap)
sta dp:.tiny(_Dp+6)