1
0
mirror of https://github.com/aap/pdp6.git synced 2026-03-10 20:53:56 +00:00

emu: implemented register state; passing diags part1

This commit is contained in:
aap
2019-01-21 22:52:19 +01:00
parent aec208c1a7
commit 36e33cc937
4 changed files with 283 additions and 273 deletions

534
emu/apr.c

File diff suppressed because it is too large Load Diff

View File

@@ -539,7 +539,8 @@ sblk:
chk = (chk<<1 | chk>>35) + w & FW;
dep(right(iowd), 0, w);
if(d)
dep(right(iowd), 0, w);
iowd += 01000001;
}
if(readwits(fp) != chk)

View File

@@ -230,9 +230,9 @@ updateapr(Apr *apr, Ptr *ptr)
}
}
setelements(apr->mb, mb_l, 36);
setelements(apr->ar, ar_l, 36);
setelements(apr->mq, mq_l, 36);
setelements(apr->c.mb, mb_l, 36);
setelements(apr->c.ar, ar_l, 36);
setelements(apr->c.mq, mq_l, 36);
ff_l[0].state = apr->key_ex_st;
ff_l[1].state = apr->key_ex_sync;
@@ -272,7 +272,7 @@ updateapr(Apr *apr, Ptr *ptr)
ff_l[32].state = apr->fdf1;
ff_l[33].state = apr->fdf2;
ff_l[34].state = apr->ir & H6 && apr->mq & F1 && !apr->nrf3;
ff_l[34].state = apr->ir & H6 && apr->c.mq & F1 && !apr->nrf3;
ff_l[35].state = apr->nrf1;
ff_l[36].state = apr->nrf2;
ff_l[37].state = apr->nrf3;

View File

@@ -307,6 +307,13 @@ enum Extpulse {
EXT_NONEXIT_MEM = 4
};
/* everything that is read AND written at the same time */
struct AprState
{
word ar;
word mb;
word mq;
};
struct Apr
{
@@ -315,15 +322,13 @@ struct Apr
Membus membus;
int powered;
struct AprState c, n;
hword ir;
word mi;
word data;
hword pc;
hword ma;
hword mas;
word mb;
word ar;
word mq;
bool mq36;
u16 sc, fe;
u8 pr, rlr, rla;