Skip to content

Commit

Permalink
Closes #13 - Move /shared_code to subdirectory of /lib
Browse files Browse the repository at this point in the history
  • Loading branch information
gregkrsak committed Mar 12, 2018
1 parent 2868a1f commit 0390036
Show file tree
Hide file tree
Showing 8 changed files with 16 additions and 19 deletions.
14 changes: 7 additions & 7 deletions first_nes.s
Original file line number Diff line number Diff line change
Expand Up @@ -39,16 +39,16 @@
; =================================================================================================

; CPU-Specific directives
.INCLUDE "shared_code/cpu.inc"
.INCLUDE "lib/shared_code/cpu.inc"

; Audio-specific directives
.INCLUDE "shared_code/apu.inc"
.INCLUDE "lib/shared_code/apu.inc"

; Video-specific directives
.INCLUDE "shared_code/ppu.inc"
.INCLUDE "lib/shared_code/ppu.inc"

; Joystick-specific directives
.INCLUDE "shared_code/controllers.inc"
.INCLUDE "lib/shared_code/controllers.inc"


; =================================================================================================
Expand Down Expand Up @@ -96,9 +96,9 @@
.INCLUDE "lib/isr/custom.s"

; Non-project-specific libraries. These may be shared across projects.
.INCLUDE "shared_code/cpu.s"
.INCLUDE "shared_code/apu.s"
.INCLUDE "shared_code/ppu.s"
.INCLUDE "lib/shared_code/cpu.s"
.INCLUDE "lib/shared_code/apu.s"
.INCLUDE "lib/shared_code/ppu.s"

; YOUR LIBRARY FILES GET INCLUDED HERE
; <libraries>
Expand Down
5 changes: 2 additions & 3 deletions shared_code/apu.inc → lib/shared_code/apu.inc
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
;
; first_nes
; shared_code/apu.inc
; lib/shared_code/apu.inc
;
; APU-Related assembler directives for Nintendo Entertainment System assembly language.
;
Expand Down Expand Up @@ -82,5 +82,4 @@ _DMC_LEN = $4013
; APU Frame counter
_FR_COUNTER = $4017 ; Reference: https://wiki.nesdev.com/w/index.php/APU_Frame_Counter


; End of apu.inc
; End of lib/shared_code/apu.inc
4 changes: 2 additions & 2 deletions shared_code/apu.s → lib/shared_code/apu.s
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
;
; first_nes
; shared_code/apu.s
; lib/shared_code/apu.s
;
; Common Audio-related routines.
;
Expand Down Expand Up @@ -47,4 +47,4 @@

.ENDPROC

; End of shared_code/apu.s
; End of lib/shared_code/apu.s
Original file line number Diff line number Diff line change
Expand Up @@ -37,5 +37,4 @@
_JOY1 = $4016
_JOY2 = $4017


; End of controllers.inc
; End of lib/shared_code/controllers.inc
2 changes: 1 addition & 1 deletion shared_code/cpu.inc → lib/shared_code/cpu.inc
Original file line number Diff line number Diff line change
Expand Up @@ -67,4 +67,4 @@
_RAM_CLEAR_PATTERN_1 = $00
_RAM_CLEAR_PATTERN_2 = $FE

; End of cpu.inc
; End of lib/shared_code/cpu.inc
2 changes: 1 addition & 1 deletion shared_code/cpu.s → lib/shared_code/cpu.s
Original file line number Diff line number Diff line change
Expand Up @@ -68,4 +68,4 @@ __ClearCPUMemory:
bne __clearMemoryLoop
jmp ISR_PowerOn_Reset::__CPUMemoryCleared

; End of shared_code/cpu.s
; End of lib/shared_code/cpu.s
3 changes: 1 addition & 2 deletions shared_code/ppu.inc → lib/shared_code/ppu.inc
Original file line number Diff line number Diff line change
Expand Up @@ -192,5 +192,4 @@ _OAMDATA = $2004 ; Reference: https://wiki.nesdev.com/w/index.php/P
; ------+-----+---------------------------------------------------------------
_OAMDMA = $4014 ; Reference: https://wiki.nesdev.com/w/index.php/PPU_registers#OAMDMA


; End of ppu.inc
; End of lib/shared_code/ppu.inc
2 changes: 1 addition & 1 deletion shared_code/ppu.s → lib/shared_code/ppu.s
Original file line number Diff line number Diff line change
Expand Up @@ -138,4 +138,4 @@

.ENDPROC

; End of shared_code/ppu.s
; End of lib/shared_code/ppu.s

0 comments on commit 0390036

Please sign in to comment.