(a, b byte)
| 300 | } |
| 301 | |
| 302 | func (cpu *CPU) compare(a, b byte) { |
| 303 | cpu.setZN(a - b) |
| 304 | if a >= b { |
| 305 | cpu.C = 1 |
| 306 | } else { |
| 307 | cpu.C = 0 |
| 308 | } |
| 309 | } |
| 310 | |
| 311 | // Read16 reads two bytes using Read to return a double-word value |
| 312 | func (cpu *CPU) Read16(address uint16) uint16 { |