aboutsummaryrefslogtreecommitdiff
path: root/src/cpu/interrupt.ts
diff options
context:
space:
mode:
authorUri Shaked2021-09-10 21:16:34 +0300
committerUri Shaked2021-09-10 21:16:34 +0300
commit96a6dba4371a2e319a47335b2bf366b695b6c17a (patch)
tree1664c852cc86826a9fd6795a6512c6d8fa92a686 /src/cpu/interrupt.ts
parentfeat(adc): ADC peripheral #13 (diff)
downloadavr8js-96a6dba4371a2e319a47335b2bf366b695b6c17a.tar.gz
avr8js-96a6dba4371a2e319a47335b2bf366b695b6c17a.tar.bz2
avr8js-96a6dba4371a2e319a47335b2bf366b695b6c17a.zip
refactor: remove the ICPU interface
Removing the interface simplifies the code
Diffstat (limited to '')
-rw-r--r--src/cpu/interrupt.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/cpu/interrupt.ts b/src/cpu/interrupt.ts
index 1bfa035..2e4ceb9 100644
--- a/src/cpu/interrupt.ts
+++ b/src/cpu/interrupt.ts
@@ -6,9 +6,9 @@
* Copyright (C) 2019, Uri Shaked
*/
-import { ICPU } from './cpu';
+import { CPU } from './cpu';
-export function avrInterrupt(cpu: ICPU, addr: number) {
+export function avrInterrupt(cpu: CPU, addr: number) {
const sp = cpu.dataView.getUint16(93, true);
cpu.data[sp] = cpu.pc & 0xff;
cpu.data[sp - 1] = (cpu.pc >> 8) & 0xff;