From 77b2540293dea4b6c348b3154e62c095de780142 Mon Sep 17 00:00:00 2001 From: Aleksey Veresov Date: Mon, 22 Mar 2021 16:45:26 +0300 Subject: . --- src/Commands.hs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'src/Commands.hs') diff --git a/src/Commands.hs b/src/Commands.hs index 32fc17f..e12cfdf 100644 --- a/src/Commands.hs +++ b/src/Commands.hs @@ -110,7 +110,12 @@ doTRAP :: Int -> Emulator () doTRAP _ = return () doLINK :: Int -> Emulator () -doLINK _ = return () +doLINK a = do + incPC + addr <- readA a + sp <- readA 7 + writeA 7 (sp-4) + setLong (sp-4) addr doUNLK :: Int -> Emulator () doUNLK a = do -- cgit v1.2.3