1 | /*
|
---|
2 | =============================================================================
|
---|
3 | romp.c -- external declarations
|
---|
4 | =============================================================================
|
---|
5 | */
|
---|
6 |
|
---|
7 | #pragma once
|
---|
8 |
|
---|
9 | #include "regs.h"
|
---|
10 | #include "setjmp.h"
|
---|
11 | #include "stdint.h"
|
---|
12 |
|
---|
13 | #define MAXFNLN 13 /* xxxxxxxx.xxx + CR */
|
---|
14 | #define MAXARGLN 80 /* maximum argument length */
|
---|
15 | #define MAXCMDLN 128 /* maximum command line length */
|
---|
16 | #define MAXHS 80 /* maximum help string length */
|
---|
17 | #define MAXID 90 /* maximum ID string length */
|
---|
18 |
|
---|
19 | #define PDATELN 14
|
---|
20 |
|
---|
21 | /*
|
---|
22 | =============================================================================
|
---|
23 | external variables
|
---|
24 | =============================================================================
|
---|
25 | */
|
---|
26 |
|
---|
27 | extern int32_t afi;
|
---|
28 | extern int16_t aflag;
|
---|
29 | extern int8_t ahex[];
|
---|
30 | extern int8_t *aptr;
|
---|
31 | extern int16_t argln;
|
---|
32 | extern int8_t argsep;
|
---|
33 | extern int8_t argstr[MAXARGLN+1];
|
---|
34 | extern int16_t asig;
|
---|
35 | extern int16_t astat;
|
---|
36 | extern int16_t aval;
|
---|
37 | extern int16_t b0flag;
|
---|
38 | extern int16_t b1flag;
|
---|
39 | extern uint16_t baroff;
|
---|
40 | extern uint16_t baron;
|
---|
41 | extern int16_t baseled;
|
---|
42 | extern int8_t bfname[MAXFNLN+1];
|
---|
43 | extern int8_t cmdline[MAXCMDLN+1];
|
---|
44 | extern int16_t cmdunit;
|
---|
45 | extern int8_t *d_cur;
|
---|
46 | extern int8_t *d_last;
|
---|
47 | extern int8_t *d_next;
|
---|
48 | extern int16_t dflag;
|
---|
49 | extern int16_t exflag;
|
---|
50 | extern int16_t first1;
|
---|
51 | extern int32_t ftimer;
|
---|
52 | extern int16_t goflag;
|
---|
53 | extern int8_t hs_mtst[MAXHS+1];
|
---|
54 | extern int8_t idbuf[MAXID+1];
|
---|
55 | extern int16_t ilast;
|
---|
56 | extern int16_t inext;
|
---|
57 | extern int16_t iplev;
|
---|
58 | extern int16_t ledcntr;
|
---|
59 | extern int8_t *monptr;
|
---|
60 | extern int16_t monsw;
|
---|
61 | extern uint16_t *obj0;
|
---|
62 | extern uint16_t *p_ba0;
|
---|
63 | extern uint16_t *p_ba1;
|
---|
64 | extern uint16_t p_bv0;
|
---|
65 | extern uint16_t p_bv1;
|
---|
66 | extern int8_t *p_end;
|
---|
67 | extern int8_t *p_from;
|
---|
68 | extern int32_t p_goto;
|
---|
69 | extern int32_t p_len;
|
---|
70 | extern int8_t *p_to;
|
---|
71 | extern int32_t p_value;
|
---|
72 | extern int32_t p_width;
|
---|
73 | extern int8_t promdate[PDATELN+1];
|
---|
74 | extern int16_t redo;
|
---|
75 | extern struct regs *regptr;
|
---|
76 | extern jmp_buf restart;
|
---|
77 | extern int8_t *rlist[];
|
---|
78 | extern int16_t rnum;
|
---|
79 | extern int16_t sigadr[];
|
---|
80 | extern int16_t sigtab[128][2];
|
---|
81 | extern int8_t *sptr;
|
---|
82 | extern uint16_t swoff;
|
---|
83 | extern uint16_t swon;
|
---|
84 | extern uint16_t *tba0;
|
---|
85 | extern uint16_t *tba1;
|
---|
86 | extern int8_t *vrlist[];
|
---|
87 | extern int16_t vrnum;
|
---|
88 |
|
---|
89 | /*
|
---|
90 | =============================================================================
|
---|
91 | external functions
|
---|
92 | =============================================================================
|
---|
93 | */
|
---|
94 |
|
---|
95 | extern int16_t bphit(void);
|
---|
96 | extern int16_t cp_boot(void);
|
---|
97 | extern int16_t cp_chek(void);
|
---|
98 | extern int16_t cp_copy(void);
|
---|
99 | extern int16_t cp_dump(void);
|
---|
100 | extern int16_t cp_fill(void);
|
---|
101 | extern int16_t cp_go(void);
|
---|
102 | extern int16_t cp_ilev(void);
|
---|
103 | extern int16_t cp_ldmp(void);
|
---|
104 | extern int16_t cp_monc(void);
|
---|
105 | extern int16_t cp_monl(void);
|
---|
106 | extern int16_t cp_mons(void);
|
---|
107 | extern int16_t cp_mset(void);
|
---|
108 | extern int16_t cp_mtst(void);
|
---|
109 | extern int16_t cp_null(void);
|
---|
110 | extern int16_t cp_read(void);
|
---|
111 | extern int16_t cp_rset(void);
|
---|
112 | extern int16_t cp_vrst(void);
|
---|
113 | extern int16_t cp_wdmp(void);
|
---|
114 | extern int16_t cp_wfil(void);
|
---|
115 | extern int16_t cp_wset(void);
|
---|
116 | extern int16_t cx_adsp(void);
|
---|
117 | extern int16_t cx_boot(void);
|
---|
118 | extern int16_t cx_bpb(void);
|
---|
119 | extern int16_t cx_chek(void);
|
---|
120 | extern int16_t cx_copy(void);
|
---|
121 | extern int16_t cx_crsh(void);
|
---|
122 | extern int16_t cx_dini(void);
|
---|
123 | extern int16_t cx_dump(void);
|
---|
124 | extern int16_t cx_exit(void);
|
---|
125 | extern int16_t cx_fill(void);
|
---|
126 | extern int16_t cx_go(void);
|
---|
127 | extern int16_t cx_help(void);
|
---|
128 | extern int16_t cx_ilev(void);
|
---|
129 | extern int16_t cx_ldmp(void);
|
---|
130 | extern int16_t cx_load(void);
|
---|
131 | extern int16_t cx_mlod(void);
|
---|
132 | extern int16_t cx_mon(void);
|
---|
133 | extern int16_t cx_mset(void);
|
---|
134 | extern int16_t cx_mtst(void);
|
---|
135 | extern int16_t cx_next(void);
|
---|
136 | extern int16_t cx_omap(void);
|
---|
137 | extern int16_t cx_read(void);
|
---|
138 | extern int16_t cx_regs(void);
|
---|
139 | extern int16_t cx_rest(void);
|
---|
140 | extern int16_t cx_rset(void);
|
---|
141 | extern int16_t cx_vreg(void);
|
---|
142 | extern int16_t cx_vrst(void);
|
---|
143 | extern int16_t cx_wdmp(void);
|
---|
144 | extern int16_t cx_wfil(void);
|
---|
145 | extern int16_t cx_writ(void);
|
---|
146 | extern int16_t cx_wset(void);
|
---|
147 | extern int16_t cx_zap(void);
|
---|
148 | extern int16_t ddump(int8_t *loc, int8_t *lastloc, int16_t nwide, int16_t unit);
|
---|
149 | extern void do_cmd(void);
|
---|
150 | extern int16_t do_srec(int8_t *line);
|
---|
151 | extern void dobar(int16_t nb, int16_t bv);
|
---|
152 | extern void dosw(int16_t nb, int16_t sv);
|
---|
153 | extern int16_t dtext(int8_t *loc, int8_t *lastloc, int16_t nwide, int16_t unit);
|
---|
154 | extern uint16_t exp_c(uint16_t c);
|
---|
155 | extern int16_t getarg(void);
|
---|
156 | extern int16_t getcmd(void);
|
---|
157 | extern int16_t getlong(int32_t *var);
|
---|
158 | extern int16_t ldump(int32_t *loc, int32_t *lastloc, int16_t nwide, int16_t unit);
|
---|
159 | extern void main(void);
|
---|
160 | extern void padr(void *adr, int16_t unit);
|
---|
161 | extern int16_t pclr(void);
|
---|
162 | extern void progid(void);
|
---|
163 | extern int16_t pscan(void);
|
---|
164 | extern void puthn(uint32_t num, int16_t cw, int16_t unit);
|
---|
165 | extern void putn(uint32_t num, int16_t cw, int16_t unit);
|
---|
166 | extern void rompbp(int32_t d0, int32_t d1, int32_t d2, int32_t d3, int32_t d4, int32_t d5, int32_t d6, int32_t d7, int8_t *a0, int8_t *a1, int8_t *a2, int8_t *a3, int8_t *a4, int8_t *a5, int8_t *a6, int8_t *a7, uint16_t sr0, uint16_t sr, int8_t *pc);
|
---|
167 | extern int16_t setp(void *var, void *deflt);
|
---|
168 | extern int16_t setvar(int32_t *var, int32_t deflt);
|
---|
169 | extern void showcr(void);
|
---|
170 | extern void showrs(struct regs *rp);
|
---|
171 | extern int16_t waitcr2(void);
|
---|
172 | extern int16_t wdump(uint16_t *loc, uint16_t *lastloc, int16_t nwide, int16_t unit);
|
---|
173 | extern int16_t xdtoi(int16_t c);
|
---|