From cf1ee28a524bbda8dbaac7304cf517bb56558470 Mon Sep 17 00:00:00 2001 From: michael Date: Sun, 11 Mar 2007 15:29:00 +0000 Subject: [PATCH] add vio to trigger an interrupt from chipscope (doesn't work currently, but doesn't harm either) --- dhwk/Makefile | 5 +++- dhwk/dhwk.cpj | 55 +++++++++++++++++++++++++++++++---------- dhwk/icon.arg | 2 +- dhwk/source/pci/top.vhd | 26 ++++++++++++++++--- dhwk/vio.arg | 9 +++++++ 5 files changed, 79 insertions(+), 18 deletions(-) create mode 100644 dhwk/vio.arg diff --git a/dhwk/Makefile b/dhwk/Makefile index b96c0bb..8eb21b5 100644 --- a/dhwk/Makefile +++ b/dhwk/Makefile @@ -3,7 +3,7 @@ CLEANFILES := dhwk_fifo* fifo_generator_* param.opt dhwk_all: ip all -ip: icon.edn ila.edn dhwk_fifo.ngc +ip: icon.edn ila.edn vio.edn dhwk_fifo.ngc icon.edn: icon.arg $(CHIPSCOPE)/bin/lin/generate.sh icon -f=$< @@ -11,6 +11,9 @@ icon.edn: icon.arg ila.edn: ila.arg $(CHIPSCOPE)/bin/lin/generate.sh ila -f=$< +vio.edn: vio.arg + $(CHIPSCOPE)/bin/lin/generate.sh vio -f=$< + dhwk_fifo.ngc: fifo.xco coregen -b $< -rmdir -p tmp/_cg diff --git a/dhwk/dhwk.cpj b/dhwk/dhwk.cpj index f093432..b145d9c 100644 --- a/dhwk/dhwk.cpj +++ b/dhwk/dhwk.cpj @@ -1,5 +1,5 @@ #ChipScope Pro Analyzer Project File, Version 3.0 -#Sun Mar 11 14:28:36 GMT+01:00 2007 +#Sun Mar 11 16:28:31 GMT+01:00 2007 deviceChain.deviceName0=XCF02S deviceChain.deviceName1=XCF04S deviceChain.deviceName2=XC3S1500 @@ -10,8 +10,8 @@ deviceChain.name0=MyDevice0 deviceChain.name1=MyDevice1 deviceChain.name2=MyDevice2 deviceIds=050450930504609301434093 -mdiAreaHeight=0.8178654292343387 -mdiAreaHeightLast=0.8538283062645011 +mdiAreaHeight=0.8251173708920188 +mdiAreaHeightLast=0.8615023474178404 mdiCount=2 mdiDevice0=2 mdiDevice1=2 @@ -19,22 +19,22 @@ mdiType0=1 mdiType1=0 mdiUnit0=0 mdiUnit1=0 -navigatorHeight=0.16821345707656613 -navigatorHeightLast=0.16821345707656613 -navigatorWidth=0.17701863354037267 -navigatorWidthLast=0.17701863354037267 +navigatorHeight=0.16901408450704225 +navigatorHeightLast=0.16901408450704225 +navigatorWidth=0.1786407766990291 +navigatorWidthLast=0.1786407766990291 unit.-1.-1.username= -unit.2.0.0.HEIGHT0=0.2934473 +unit.2.0.0.HEIGHT0=0.2942857 unit.2.0.0.TriggerRow0=1 unit.2.0.0.TriggerRow1=1 unit.2.0.0.TriggerRow2=1 -unit.2.0.0.WIDTH0=0.9974457 +unit.2.0.0.WIDTH0=0.9976019 unit.2.0.0.X0=0.0 unit.2.0.0.Y0=0.0 -unit.2.0.1.HEIGHT1=0.71652424 -unit.2.0.1.WIDTH1=0.99872285 -unit.2.0.1.X1=-0.0012771392 -unit.2.0.1.Y1=0.28490028 +unit.2.0.1.HEIGHT1=0.7171429 +unit.2.0.1.WIDTH1=0.99880093 +unit.2.0.1.X1=-0.0011990408 +unit.2.0.1.Y1=0.28428572 unit.2.0.MFBitsA0=0XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX unit.2.0.MFBitsB0=00000000000000000000000000000000 unit.2.0.MFCompareA0=0 @@ -971,3 +971,32 @@ unit.2.0.waveform.posn.9.channel=76 unit.2.0.waveform.posn.9.name=SERRn unit.2.0.waveform.posn.9.radix=1 unit.2.0.waveform.posn.9.type=signal +unit.2.1.6.HEIGHT6=0.6142857 +unit.2.1.6.WIDTH6=0.9616307 +unit.2.1.6.X6=0.016786572 +unit.2.1.6.Y6=0.32714286 +unit.2.1.coretype=VIO +unit.2.1.port.-1.buscount=0 +unit.2.1.port.-1.channelcount=0 +unit.2.1.port.0.buscount=0 +unit.2.1.port.0.channelcount=0 +unit.2.1.port.1.buscount=0 +unit.2.1.port.1.channelcount=1 +unit.2.1.port.1.s.0.alias=PCI_INTA +unit.2.1.port.1.s.0.color=java.awt.Color[r\=0,g\=0,b\=124] +unit.2.1.port.1.s.0.display=0 +unit.2.1.port.1.s.0.name=AsyncOut[0] +unit.2.1.port.1.s.0.orderindex=-1 +unit.2.1.port.1.s.0.persistence=0 +unit.2.1.port.1.s.0.value=1 +unit.2.1.port.1.s.0.visible=1 +unit.2.1.port.2.buscount=0 +unit.2.1.port.2.channelcount=0 +unit.2.1.portcount=3 +unit.2.1.username=MyVIO1 +unit.2.1.vio.count=1 +unit.2.1.vio.posn.0.channel=0 +unit.2.1.vio.posn.0.name=PCI_INTA +unit.2.1.vio.posn.0.port=1 +unit.2.1.vio.posn.0.type=signal +unit.2.1.vio.readperiod=0 diff --git a/dhwk/icon.arg b/dhwk/icon.arg index fc56ce1..9e4596a 100644 --- a/dhwk/icon.arg +++ b/dhwk/icon.arg @@ -2,7 +2,7 @@ # Usage: generate.exe icon -f= # -compname=icon --numports=1 +-numports=2 -devicefamily=Spartan3 -bscanchain=1 -outputdirectory=. diff --git a/dhwk/source/pci/top.vhd b/dhwk/source/pci/top.vhd index 01c30b6..86cd575 100644 --- a/dhwk/source/pci/top.vhd +++ b/dhwk/source/pci/top.vhd @@ -97,8 +97,10 @@ architecture SCHEMATIC of dhwk is signal watch_PCI_PERRn : std_logic; signal watch_PCI_REQn : std_logic; signal control0 : std_logic_vector(35 downto 0); + signal control1 : std_logic_vector(35 downto 0); signal data : std_logic_vector(95 downto 0); signal trig0 : std_logic_vector(31 downto 0); + signal vio_async_out : std_logic_vector(0 downto 0); component MESS_1_TB Port ( DEVSELn : In std_logic; @@ -232,7 +234,8 @@ architecture SCHEMATIC of dhwk is component icon port ( - control0 : out std_logic_vector(35 downto 0) + control0 : out std_logic_vector(35 downto 0); + control1 : out std_logic_vector(35 downto 0) ); end component; @@ -246,6 +249,14 @@ architecture SCHEMATIC of dhwk is ); end component; + component vio + port + ( + control : in std_logic_vector(35 downto 0); + async_out : out std_logic_vector(0 downto 0) + ); + end component; + begin watch_PCI_REQn <= '1'; @@ -255,7 +266,8 @@ begin LED_3 <= not PCI_IDSEL; LED_4 <= not PCI_FRAMEn; LED_5 <= not watch_PCI_INTAn; - PCI_INTAn <= watch_PCI_INTAn; + PCI_INTAn <= watch_PCI_INTAn and (not vio_async_out(0)); + trig0(31 downto 0) <= ( 0 => watch_PCI_INTAn, 1 => R_FIFO_READn, @@ -412,7 +424,8 @@ begin i_icon : icon port map ( - control0 => control0 + control0 => control0, + control1 => control1 ); i_ila : ila @@ -423,4 +436,11 @@ begin data => data, trig0 => trig0 ); + + i_vio : vio + port map + ( + control => control1, + async_out => vio_async_out + ); end SCHEMATIC; diff --git a/dhwk/vio.arg b/dhwk/vio.arg new file mode 100644 index 0000000..44f7884 --- /dev/null +++ b/dhwk/vio.arg @@ -0,0 +1,9 @@ +# +# Usage: generate.exe vio -f= +# +-compname=vio +-outputdirectory=. +-devicefamily=Spartan3 +-srl16type=2 +-asyncoutwidth=1 +-createcdc -- 2.39.5