35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
|
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
|
-
+
|
if(reg[4]) curnum=parseInt(reg[4],16);
if(reg[2] && !reg[1].includes("#")) {
console.log("#define OP_"+reg[2].toUpperCase()+" "+curnum);
if(flags&1) console.log("#define OP_"+reg[2].toUpperCase()+"_C "+(curnum+0x0800));
if(flags&2) console.log("#define OP_"+reg[2].toUpperCase()+"_E "+(curnum+0x1000));
if(3==(flags&3)) console.log("#define OP_"+reg[2].toUpperCase()+"_EC "+(curnum+0x1800));
if(10==(flags&10)) {
if(flags&1) console.log("#define OP_"+reg[2].toUpperCase()+"_EC16 "+(curnum+0x0801));
if(flags&1) console.log("#define OP_"+reg[2].toUpperCase()+"_EC16 "+(curnum+0x1801));
console.log("#define OP_"+reg[2].toUpperCase()+"_E16 "+(curnum+0x1001));
}
if(flags&32) {
console.log("#define OP_"+reg[2].toUpperCase()+"_D "+(curnum+0x2000));
if(flags&1) console.log("#define OP_"+reg[2].toUpperCase()+"_CD "+(curnum+0x2800));
}
}
|