Search found 205 matches

by DocWaluigean
Sat Jun 13, 2020 2:45 pm
Forum: Newbie Help Center
Topic: Hello, I'm back, still need assistences
Replies: 98
Views: 3348

Re: Hello, I'm back, still need assistences

I don't understand at first sight. LDA foobar - Load number into A Register from "foobar" label. "Foobar" is a silly name used in programming discussions where the identity is not particularly important, like of like saying "John Doe" for a hypothetical person. In the scenario I gave, "foobar" is t...
by DocWaluigean
Sat Jun 13, 2020 2:00 pm
Forum: Newbie Help Center
Topic: Hello, I'm back, still need assistences
Replies: 98
Views: 3348

Re: Hello, I'm back, still need assistences

This is the inside of the first "app" code of NES: .inesprg 1 ; 1x 16KB PRG code .ineschr 1 ; 1x 8KB CHR data .inesmap 0 ; mapper 0 = NROM, no bank swapping .inesmir 1 ; background mirroring ;;;;;;;;;;;;;;; .bank 0 .org $C000 RESET: SEI ; disable IRQs CLD ; disable decimal mode LDX #$40 STX $4017 ; ...
by DocWaluigean
Sat Jun 13, 2020 1:12 pm
Forum: Newbie Help Center
Topic: Hello, I'm back, still need assistences
Replies: 98
Views: 3348

Re: Hello, I'm back, still need assistences

Common Comparison opcodes CMP #$01 ; CoMPare A to the value $01 ; this actually does a subtract, but does not keep the result ; instead you check the status register to check for equal, ; less than, or greater than This one is not true about subtract. CMP - Compare Z,C,N = A-M This instruction comp...
by DocWaluigean
Sat Jun 13, 2020 12:56 pm
Forum: Newbie Help Center
Topic: Hello, I'm back, still need assistences
Replies: 98
Views: 3348

Re: Hello, I'm back, still need assistences

I'm going to try reading Nerdy Nights now, but I don't know if there's a better tool to use than ASM3 they provided. I know MESEN is a better choice than that.
by DocWaluigean
Sat Jun 13, 2020 12:50 pm
Forum: Newbie Help Center
Topic: Hello, I'm back, still need assistences
Replies: 98
Views: 3348

Re: Hello, I'm back, still need assistences

I'm going to just say that, I understand the basics of A, X, Y, and other things, but certain wording makes it difficult for me to understand. Although questions may be repeated, PLEASE simple answers, so it can help me: The Zero Flag: It turns on if the A, X, Y, or S Register has zero? It turns on ...
by DocWaluigean
Sat Jun 13, 2020 12:13 pm
Forum: Newbie Help Center
Topic: Hello, I'm back, still need assistences
Replies: 98
Views: 3348

Re: Hello, I'm back, still need assistences

CODE: SELECT ALL CODE: SELECT ALL LDA foobar ; Examine variable "foobar." BEQ label1 ; If it's 0, skip the next two lines and go down to label1. <do_stuff> ; These two lines will get executed only if "foobar" was not 0. <do_stuff> label1: <continue_here> ; This part gets executed regardless. LDX #7...
by DocWaluigean
Fri Jun 12, 2020 10:19 pm
Forum: Newbie Help Center
Topic: Hello, I'm back, still need assistences
Replies: 98
Views: 3348

Re: Hello, I'm back, still need assistences

An automatic compare-to-zero instruction (which updates the N and Z flags) is built into the following 65c02 instructions: LDA, LDX, LDY, INC, INX, INY, DEC, DEX, DEY, AND, ORA, EOR, ASL, LSR, ROL, ROR, PLA, SBC, ADC, TAX, TXA, TAY, TYA, and TSX, and on the 65c02 (ie, CMOS), INA, DEA, PLX, and PLY....
by DocWaluigean
Fri Jun 12, 2020 4:58 pm
Forum: Newbie Help Center
Topic: Hello, I'm back, still need assistences
Replies: 98
Views: 3348

Re: Hello, I'm back, still need assistences

I mean erase the Registers of A, X, and Y if not using or at least replace it with new numbers, not the Address. I think why erase it is to set certain Flags on or off. No. Because you'd just be wasting cycles. Any time you need to use one of those registers, you either want the remaining value in ...
by DocWaluigean
Thu Jun 11, 2020 9:02 pm
Forum: Newbie Help Center
Topic: Hello, I'm back, still need assistences
Replies: 98
Views: 3348

Re: Hello, I'm back, still need assistences

But anyway, I'm wondering which "most important, basic stuff first" am I missing out right now? There's A, X, Y Register Address usages Binary, HEX, and normal numbers Carry Flag, Zero Flag, [and maybe Negative Flag but I still don't know how to activate it and use it yet.] I'm guessing I'm missing ...
by DocWaluigean
Thu Jun 11, 2020 8:51 pm
Forum: Newbie Help Center
Topic: Hello, I'm back, still need assistences
Replies: 98
Views: 3348

Re: Hello, I'm back, still need assistences

My concern is, if the code A = 5 : mem1 = A is true, does mem1 number changes if A = something other than 5? No. Once a value is copied, it doesn't matter what you do with the source of that value, the copy will not be affected. So it's not copy, huh? Guess I have to do AXYS = 0 if I want to erase ...
by DocWaluigean
Thu Jun 11, 2020 8:12 pm
Forum: Newbie Help Center
Topic: Hello, I'm back, still need assistences
Replies: 98
Views: 3348

Re: Hello, I'm back, still need assistences

In either case, they're copy, not move. Example 1: The code: LDA #5 STA mem1 where mem1 is a label corresponding to a certain memory location, is equivalent to, in higher level language terms: A = 5 mem1 = A Which after storing the value of A (5) into mem1, A still carries the value 5, so STA just ...
by DocWaluigean
Thu Jun 11, 2020 7:13 pm
Forum: Newbie Help Center
Topic: Hello, I'm back, still need assistences
Replies: 98
Views: 3348

Re: Hello, I'm back, still need assistences

At least 6502 jargon does not use the term "move" like many processors do, which I'm glad for, because "move" wrongly suggests it's no longer in the source. "Copy" is good. "Transfer" (like TAY, TYA, TAX, TXA, TXS, and TSX), "load," and "store" are still better than "move." So... In forms of LDA LD...
by DocWaluigean
Thu Jun 11, 2020 4:43 pm
Forum: Newbie Help Center
Topic: Hello, I'm back, still need assistences
Replies: 98
Views: 3348

Re: Hello, I'm back, still need assistences

If you're really interested in doing operations between A, X and Y without using temporary variables in RAM, there's a trick you can use: Have one page (256 bytes) in ROM memory hold all the values from 0 to 255: bytetable: .db $00, $01, $02, $03, $04, $05, $06, $07, $08, $09, $0a, $0b, $0c, $0d, $...
by DocWaluigean
Thu Jun 11, 2020 4:19 pm
Forum: Newbie Help Center
Topic: Hello, I'm back, still need assistences
Replies: 98
Views: 3348

Re: Hello, I'm back, still need assistences

LDA #20 LDX #10 STX $10 CMP $10 It's now comparing Register A with Register X? I think you just have to be more careful with how you word things, because even though the final effect is that you're in fact comparing A to X, the accurate thing to say here is that you're comparing the value in A to a...
by DocWaluigean
Thu Jun 11, 2020 3:47 pm
Forum: Newbie Help Center
Topic: Hello, I'm back, still need assistences
Replies: 98
Views: 3348

Re: Hello, I'm back, still need assistences

I think "if" is a better term than "while." "While" implies a condition that persists, usually in a loop, where you continue looping and looping until that condition ends. The C flag may be changing many, many times in that loop though, and the branch only sees if it's set at the moment the conditi...