* We use decimal numbers (0 ~ 9) in our usual usage to count : 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, ...
* Computers use binary numbers (0 and 1) : 0, 1, 10, 11, 100, 101, 110, 111, 1000, 1001, 1010, 1011, 1100, 1101, 1110, 1111, ...
* Long series of binary numbers are not pleasant for human eye, so we force computers to show us hexadecimal numbers (0 ~ F) : 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, A, B, C, D, E, F, ...
* You can use windows calculator to convert Binary, Decimal and Hexadecimal numbers to each other :
* Need more info then read this : Hexadecimal
/////////////////////////////////////////////////////////////////////////////////////////////////
Code: Select all
;NES Programming Tutorial
;Level 1 : Source Code Structure
;+++++++++++++++++++++++++++++++++++++++++++++++++++++
;Constants
;+++++++++++++++++++++++++++++++++++++++++++++++++++++
;Variables
;+++++++++++++++++++++++++++++++++++++++++++++++++++++
;iNES header data (16bytes)
;+++++++++++++++++++++++++++++++++++++++++++++++++++++
;PRG Bank0 $8000 ~ $BFFF (16KB)
;---------------------------;
;PRG Bank1 $C000 ~ $FFFF (16KB)
;+++++++++++++++++++++++++++++++++++++++++++++++++++++
;CHR Bank0 $0000 ~ $1FFF (8KB)
* Download Notepad++ and start NES programming!
* Here is a user defined syntax highlighting in Notepad++ for ASM6 (Language --> User Defined Language --> Define your language --> Import --> npp_6502_asm6.xml --> Language --> 6502 assembly)
* Lines starting with ; are just comment
* Save the file with the name of : "Game.asm"
* Game.asm is called source code, because it has codes, right?
That's all for today!
/////////////////////////////////////////////////////////////////////////////////////////////////
Exercise :
Write your name inside of the source code as a comment!
/////////////////////////////////////////////////////////////////////////////////////////////////
Files :
Game.asm
/////////////////////////////////////////////////////////////////////////////////////////////////
Former Level : NES Programming Tutorial : Intro
Next Level : NES Programming Tutorial : iNES Header