diff options
| author | Uri Shaked | 2019-11-27 09:42:08 +0200 |
|---|---|---|
| committer | Uri Shaked | 2019-11-27 09:42:08 +0200 |
| commit | d8d169566094c70417c646275b51918458f98dbf (patch) | |
| tree | b487976bfedc19cb7509c59793d10ad4ddb8962f /src/interrupt.spec.ts | |
| parent | chore: release 0.3.0 (diff) | |
| download | avr8js-d8d169566094c70417c646275b51918458f98dbf.tar.gz avr8js-d8d169566094c70417c646275b51918458f98dbf.tar.bz2 avr8js-d8d169566094c70417c646275b51918458f98dbf.zip | |
fix: SP not initialized on reset
close #2
Diffstat (limited to 'src/interrupt.spec.ts')
| -rw-r--r-- | src/interrupt.spec.ts | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/interrupt.spec.ts b/src/interrupt.spec.ts index 06979ed..cc54e3c 100644 --- a/src/interrupt.spec.ts +++ b/src/interrupt.spec.ts @@ -5,6 +5,7 @@ describe('avrInterrupt', () => { it('should execute interrupt handler', () => { const cpu = new CPU(new Uint16Array(0x8000)); cpu.pc = 0x520; + cpu.data[94] = 0; cpu.data[93] = 0x80; // SP <- 0x80 cpu.data[95] = 0b10000001; // SREG <- I------C avrInterrupt(cpu, 5); |
