Hi all, I recently started taking a course called microprocessors and it involves a lot of programming, which is a new field for me. As you've guessed, it's pretty tough and I can't seem to get my head around the logic. We currently use hexadecimal notations to write our programs and the textbook I'm using is not comprehensive enough for me.
I have a few questions due next week that I'm working on. We are asked to write a program that transfers 400bytes of memory from $C000 to $D000. This is what I've been able to come up with but it's not working as intended.

LDX #0X3000
LDY #0X4000
LDAB 0190
LOOP:
LDAA 0X00,X
STAA 0X00,Y
INX
INY
CPX 0190
BNE LOOP
BRA

so, I've been told that this will only count to 256 instead of 400. I've tried to do some research and there isn't any material out there that does it justice. Any help will be appreciated.