-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy patheater.cpp
More file actions
33 lines (27 loc) · 735 Bytes
/
eater.cpp
File metadata and controls
33 lines (27 loc) · 735 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
#include "OctalBusTransceivers.h"
#include "implements.h"
class EightBit {
private:
implements::Array BUS_;
public:
int clock(int HLT, int mode, int CLK, int SS) {
int out = 0;
if (!HLT) {
if (mode) {
out = CLK;
} else {
out = SS;
}
}
return out;
}
implements::Array reg_A(int AI, int AO, int CLK, int CLR, implements::Array BUS) {
// Assign BUS to BUS_
BUS_ = BUS;
return BUS_;
}
implements::Array reg_B(int BI, int BO, int CLK, int CLR, implements::Array BUS) {
// Just reuses reg_A
return reg_A(BI, BO, CLK, CLR, BUS);
}
};