summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--cpu.c15
1 files changed, 12 insertions, 3 deletions
diff --git a/cpu.c b/cpu.c
index acb4efb..d754c15 100644
--- a/cpu.c
+++ b/cpu.c
@@ -588,7 +588,10 @@ tax(void)
static void
tay(uint8_t arg)
{
-/* TODO: complete this */
+ regs.y = regs.a;
+
+ STATUS_UPDATE_ZERO(regs.y);
+ STATUS_UPDATE_NEGATIVE(regs.y);
}
static void
@@ -600,7 +603,10 @@ tsx(uint8_t arg)
static void
txa(uint8_t arg)
{
-/* TODO: complete this */
+ regs.a = regs.x;
+
+ STATUS_UPDATE_ZERO(regs.a);
+ STATUS_UPDATE_NEGATIVE(regs.a);
}
static void
@@ -612,7 +618,10 @@ txs(uint8_t arg)
static void
tya(uint8_t arg)
{
-/* TODO: complete this */
+ regs.a = regs.y;
+
+ STATUS_UPDATE_ZERO(regs.a);
+ STATUS_UPDATE_NEGATIVE(regs.a);
}
static void