DE2带的IP核ISP12362报错问题解决 Error:avalon_slave_1_irq: associatedAddressablePoint out of range

问题来源与对友晶提供的ISP1362 IP核的使用,由于Quartus II版本问题,它提供的IP基于7.0版本,而我用的版本为11.1,在SOPC Builder中重新加载IP,就出现了上述的错误报告,在网上找了资料,以一下方法解决:

 
将avalon_slave_1_irq 的Inteface类型设置为interrupt_sender,Signal Type设置为irq_n,后续中断设置为对将avalon_slave_0,IP编辑过程是没错误了,但是添加的时候会出现将avalon_slave_0不能同时存在两个中断的问题,坑人的解决方法在此表示失效了。
 
然后就发散思维,自己添加了一个avalon_slave_1 Inteface,IP编辑和添加都没错误,只是警告这个总线没有信号相连,忽略,然后generate,麻烦来了,SOPC生成报错,生成过程被迫中止。
 
继续发散,将两个中断在HDL代码中合并,然后全世界都安静了,可是不要小瞧错误的隐藏能力,在Nios II编程过后,给你一个大大的耳光——“无法识别的硬件设备”。郁闷的结果!
 
没办法,去GOOGLE找大牛吧,在ALTERA官网,有人说用如下文件代替原来的isp1362_if.v
module ISP1362_CTRL (//Avalon Interface
                                clk, address, readdata, writedata, writedata_avalon_slave_1, chipselect_n, read_n, write_n, reset_n, write_n_avalon_slave_1, irq_n, irq_n_avalon_slave_1,
                                //Phillips USB controller
                                OTG_ADDR, OTG_DATA, OTG_CS_N, OTG_RD_N, OTG_WR_N, OTG_RST_N, OTG_INT0, OTG_INT1, OTG_FSPEED, OTG_LSPEED, OTG_DACK0_N, OTG_DACK1_N);
        
        //Avalon Interface
        input clk, chipselect_n, read_n, write_n, reset_n, write_n_avalon_slave_1;
        input [1:0] address;
        input [15:0] writedata;
        input [7:0] writedata_avalon_slave_1;
        output [15:0] readdata;
        output irq_n, irq_n_avalon_slave_1;
        
        //Phillips USB controller
        output [1:0] OTG_ADDR;
        inout [15:0] OTG_DATA;
        output OTG_CS_N, OTG_RD_N, OTG_WR_N, OTG_RST_N;
        input OTG_INT0, OTG_INT1;
        output OTG_FSPEED, OTG_LSPEED, OTG_DACK0_N, OTG_DACK1_N;
        
        //Registers
        reg [15:0] data, readdata;
        reg [1:0] OTG_ADDR;
        reg OTG_CS_N, OTG_RD_N, OTG_WR_N;
        reg irq_n, irq_n_avalon_slave_1;
        
        //Assignments
        assign OTG_RST_N = reset_n;
        assign OTG_DATA = OTG_WR_N ? 16'hZZZZ : data;
        assign OTG_DACK0_N = 1'b1, OTG_DACK1_N = 1'b1;
        assign OTG_FSPEED = 0, OTG_LSPEED = 0;
        
        //Reset condition
        always @ (posedge clk or negedge reset_n)
        begin
                if (reset_n==0)
                begin
                        data            <=  0;
                        readdata        <=      0;
                        OTG_ADDR        <=      0;
                        OTG_CS_N        <=      1;
                        OTG_RD_N        <=      1;
                        OTG_WR_N        <=      1;
                        irq_n                                   <=      1;
                        irq_n_avalon_slave_1    <=      1;
                end
                
                else
                begin
                        data            <=      writedata;
                        readdata        <=      OTG_DATA;
                        OTG_ADDR        <=      address;
                        OTG_CS_N        <=      chipselect_n;
                        OTG_RD_N        <=      read_n;
                        OTG_WR_N        <=      write_n;
                        irq_n                                   <=      OTG_INT0;
                        irq_n_avalon_slave_1    <=      OTG_INT1;
                end
        end
endmodule

后面的过程愉快而轻松,换过的方法非常多,郁闷到死,找资料还是GOOGLE靠谱。

posted on 2014-04-16 11:06  电子组装技术  阅读(737)  评论(0编辑  收藏  举报

导航