mirror of
https://github.com/hoglet67/AtomBusMon.git
synced 2025-06-17 00:23:31 +00:00
Compare commits
3 Commits
release_2
...
hack_6502_
Author | SHA1 | Date | |
---|---|---|---|
f55292b499 | |||
85dbcb8732 | |||
50a86721e4 |
@ -14,7 +14,7 @@
|
||||
* VERSION and NAME are used in the start-up message
|
||||
********************************************************/
|
||||
|
||||
#define VERSION "0.981"
|
||||
#define VERSION "0.981 (custom for Bram)"
|
||||
|
||||
#if defined(CPU_Z80)
|
||||
#define NAME "ICE-Z80"
|
||||
@ -70,6 +70,7 @@ char *cmdStrings[] = {
|
||||
"load",
|
||||
"save",
|
||||
"srec",
|
||||
"ihex",
|
||||
"special",
|
||||
"reset",
|
||||
"trace",
|
||||
@ -123,6 +124,7 @@ void (*cmdFuncs[])(char *params) = {
|
||||
doCmdLoad,
|
||||
doCmdSave,
|
||||
doCmdSRec,
|
||||
doCmdIHex,
|
||||
doCmdSpecial,
|
||||
doCmdReset,
|
||||
doCmdTrace,
|
||||
@ -190,50 +192,51 @@ static const uint8_t helpMeta[] PROGMEM = {
|
||||
#endif
|
||||
17, 15, // help
|
||||
9, 8, // continue
|
||||
24, 7, // next
|
||||
32, 6, // step
|
||||
27, 7, // regs
|
||||
25, 7, // next
|
||||
33, 6, // step
|
||||
28, 7, // regs
|
||||
12, 10, // dis
|
||||
16, 7, // flush
|
||||
13, 11, // fill
|
||||
11, 9, // crc
|
||||
10, 13, // copy
|
||||
8, 13, // compare
|
||||
22, 1, // mem
|
||||
26, 2, // rd
|
||||
41, 3, // wr
|
||||
23, 1, // mem
|
||||
27, 2, // rd
|
||||
42, 3, // wr
|
||||
#if defined(CPU_Z80)
|
||||
20, 1, // io
|
||||
19, 2, // in
|
||||
25, 3, // out
|
||||
21, 1, // io
|
||||
20, 2, // in
|
||||
26, 3, // out
|
||||
#endif
|
||||
#if defined(CPU_6502) || defined(CPU_65C02)
|
||||
14, 0, // go
|
||||
15, 16, // exec
|
||||
23, 14, // mode
|
||||
24, 14, // mode
|
||||
#endif
|
||||
33, 12, // test
|
||||
21, 0, // load
|
||||
29, 9, // save
|
||||
31, 7, // srec
|
||||
30, 14, // special
|
||||
28, 7, // reset
|
||||
34, 6, // trace
|
||||
34, 12, // test
|
||||
22, 0, // load
|
||||
30, 9, // save
|
||||
32, 7, // srec
|
||||
19, 7, // ihex
|
||||
31, 14, // special
|
||||
29, 7, // reset
|
||||
35, 6, // trace
|
||||
1, 7, // blist
|
||||
6, 4, // breakx
|
||||
40, 4, // watchx
|
||||
41, 4, // watchx
|
||||
4, 4, // breakr
|
||||
38, 4, // watchr
|
||||
39, 4, // watchr
|
||||
5, 4, // breakw
|
||||
39, 4, // watchw
|
||||
40, 4, // watchw
|
||||
#if defined(CPU_Z80)
|
||||
2, 4, // breaki
|
||||
36, 4, // watchi
|
||||
37, 4, // watchi
|
||||
3, 4, // breako
|
||||
37, 4, // watcho
|
||||
38, 4, // watcho
|
||||
#endif
|
||||
7, 0, // clear
|
||||
35, 5, // trigger
|
||||
36, 5, // trigger
|
||||
0, 0
|
||||
};
|
||||
|
||||
@ -1972,6 +1975,10 @@ void doCmdSRec(char *params) {
|
||||
}
|
||||
}
|
||||
|
||||
void doCmdIHex(char *params) {
|
||||
logstr("TODO: implement intel hex command\n");
|
||||
}
|
||||
|
||||
void logSpecial(char *function, uint8_t value) {
|
||||
logs(function);
|
||||
if (value) {
|
||||
|
@ -62,6 +62,7 @@ void doCmdHelp(char *params);
|
||||
void doCmdHistory(char *params);
|
||||
void helpForCommand(uint8_t i);
|
||||
#endif
|
||||
void doCmdIHex(char *params);
|
||||
void doCmdIO(char *params);
|
||||
void doCmdList(char *params);
|
||||
void doCmdLoad(char *params);
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -104,8 +104,26 @@ architecture behavioral of MOS6502CpuMonALS is
|
||||
signal led_trig0 : std_logic;
|
||||
signal led_trig1 : std_logic;
|
||||
|
||||
|
||||
signal int_Phi0_div : unsigned(4 downto 0); -- internal Phi0 clock divider
|
||||
signal int_Phi0 : std_logic; -- internal Phi0 clock
|
||||
|
||||
begin
|
||||
|
||||
-- Hack to use an internal 1MHz clock instead of Phi0
|
||||
-- from the 50MHz clock on the EEPIZZA board
|
||||
process(clock)
|
||||
begin
|
||||
if rising_edge(clock) then
|
||||
if int_Phi0_div = 24 then
|
||||
int_Phi0 <= not int_Phi0; -- toggle int_Phi2 every 25 cycles
|
||||
int_Phi0_div <= (others => '0');
|
||||
else
|
||||
int_Phi0_div <= int_Phi0_div + 1;
|
||||
end if;
|
||||
end if;
|
||||
end process;
|
||||
|
||||
sw_reset_cpu <= not sw1;
|
||||
sw_reset_avr <= not sw2;
|
||||
led1 <= led_bkpt;
|
||||
@ -126,7 +144,7 @@ begin
|
||||
clock => clock,
|
||||
|
||||
-- 6502 Signals
|
||||
Phi0 => PhiIn,
|
||||
Phi0 => int_Phi0, -- hack to use internal Phi0
|
||||
Phi1 => Phi1Out,
|
||||
Phi2 => Phi2Out,
|
||||
IRQ_n => IRQ_n,
|
||||
@ -175,7 +193,7 @@ begin
|
||||
OERW_n <= not (BE);
|
||||
OEAH_n <= not (BE);
|
||||
OEAL_n <= not (BE);
|
||||
OED_n <= not (BE and PhiIn); -- TODO: might need to use a slightly delayed version of Phi2 here
|
||||
OED_n <= not (BE and int_Phi0); -- hack to use interal Phi0
|
||||
DIRD <= R_W_n_int;
|
||||
|
||||
end behavioral;
|
||||
|
Reference in New Issue
Block a user