Closed 6502cloud closed 7 years ago
The behaviour looks correct to me. Can you give more details of the problem?
$ env PYTHONPATH=. python ./py65/monitor.py
Py65 Monitor
PC AC XR YR SP NV-BDIZC
6502: 0000 00 00 00 ff 00110000
registers pc=600
.
PC AC XR YR SP NV-BDIZC
6502: 0600 00 00 00 ff 00110000
assemble
$0600 d0 00 BNE $0602
$0602 d0 fc BNE $0600
$0604 d0 fe BNE $0604
Yeah, you are correct. I had a bug in my assembler function that was causing things to be off by 2. My PC counter wasn't incremented in the correct spot.
Branching offsets were always off by two when assembled.