OpenCores
URL https://opencores.org/ocsvn/nextz80/nextz80/trunk

Subversion Repositories nextz80

[/] [nextz80/] [trunk/] [NextZ80CPU.v] - Diff between revs 12 and 13

Go to most recent revision | Show entire file | Details | Blame | View Log

Rev 12 Rev 13
Line 169... Line 169...
                        if(!SNMI) FNMI <= 0;
                        if(!SNMI) FNMI <= 0;
                        if(SRESET) FETCH <= 10'b1110000000;
                        if(SRESET) FETCH <= 10'b1110000000;
                        else
                        else
                                if(FETCH[9:6] == 4'b1110) {FETCH[9:7]} <= 3'b000;       // exit RESET state
                                if(FETCH[9:6] == 4'b1110) {FETCH[9:7]} <= 3'b000;       // exit RESET state
                                else begin
                                else begin
                                        if(M1)
                                        if(M1 || (fetch98 == 2'b10))    // [DD/FD CB disp op] -  M1 is inactive during <op> byte read, but FETCH is performed
                                                case({MREQ, CPUStatus[9:8]})
                                                case({MREQ, CPUStatus[9:8]})
                                                        3'b000, 3'b001, 3'b100, 3'b101, 3'b110, 3'b111: FETCH <= {fetch98, DI};
                                                        3'b000, 3'b001, 3'b100, 3'b101, 3'b110, 3'b111: FETCH <= {fetch98, DI};
                                                        3'b010: FETCH <= {fetch98, 8'hff};      // IM1 - RST38
                                                        3'b010: FETCH <= {fetch98, 8'hff};      // IM1 - RST38
                                                        3'b011: ; // IM2 - get addrLO
                                                        3'b011: ; // IM2 - get addrLO
                                                endcase
                                                endcase
Line 904... Line 904...
                                                                case({STAGE[0], CPUStatus[4]})
                                                                case({STAGE[0], CPUStatus[4]})
                                                                        2'b00, 2'b11: begin
                                                                        2'b00, 2'b11: begin
                                                                                ALU160_SEL = 1;                 // PC
                                                                                ALU160_SEL = 1;                 // PC
                                                                                WE              = 6'b010000;    // PC
                                                                                WE              = 6'b010000;    // PC
                                                                                fetch98 = 2'b10;
                                                                                fetch98 = 2'b10;
 
                                                                                M1 = !CPUStatus[4];     // [DD/FD CB disp op] -  M1 is inactive during <op> byte read
                                                                        end
                                                                        end
                                                                        2'b01: begin
                                                                        2'b01: begin
                                                                                ALU160_SEL = 1;                 // PC
                                                                                ALU160_SEL = 1;                 // PC
                                                                                WE              = 6'b010100;    // PC, tmpHI
                                                                                WE              = 6'b010100;    // PC, tmpHI
                                                                                next_stage = 1;
                                                                                next_stage = 1;

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.