mirror of
https://github.com/hneemann/Digital.git
synced 2025-10-01 00:40:07 -04:00
modified some example circuits
This commit is contained in:
parent
f88a70bc47
commit
8ef847e056
552
src/main/dig/cmos/sram_simple.dig
Normal file
552
src/main/dig/cmos/sram_simple.dig
Normal file
@ -0,0 +1,552 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<circuit>
|
||||
<version>1</version>
|
||||
<visualElements>
|
||||
<visualElement>
|
||||
<elementName>NFET</elementName>
|
||||
<elementAttributes/>
|
||||
<pos x="500" y="320"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>PFET</elementName>
|
||||
<elementAttributes/>
|
||||
<pos x="500" y="220"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>NFET</elementName>
|
||||
<elementAttributes/>
|
||||
<pos x="580" y="320"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>PFET</elementName>
|
||||
<elementAttributes/>
|
||||
<pos x="580" y="220"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>NFET</elementName>
|
||||
<elementAttributes>
|
||||
<entry>
|
||||
<string>rotation</string>
|
||||
<rotation rotation="3"/>
|
||||
</entry>
|
||||
</elementAttributes>
|
||||
<pos x="460" y="280"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>NFET</elementName>
|
||||
<elementAttributes>
|
||||
<entry>
|
||||
<string>rotation</string>
|
||||
<rotation rotation="3"/>
|
||||
</entry>
|
||||
</elementAttributes>
|
||||
<pos x="660" y="280"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>PullDown</elementName>
|
||||
<elementAttributes/>
|
||||
<pos x="520" y="380"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>PullDown</elementName>
|
||||
<elementAttributes/>
|
||||
<pos x="600" y="380"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>PullUp</elementName>
|
||||
<elementAttributes/>
|
||||
<pos x="520" y="200"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>PullUp</elementName>
|
||||
<elementAttributes/>
|
||||
<pos x="600" y="200"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>LED</elementName>
|
||||
<elementAttributes>
|
||||
<entry>
|
||||
<string>rotation</string>
|
||||
<rotation rotation="1"/>
|
||||
</entry>
|
||||
</elementAttributes>
|
||||
<pos x="560" y="200"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>In</elementName>
|
||||
<elementAttributes>
|
||||
<entry>
|
||||
<string>Description</string>
|
||||
<string>Wortleitung 0</string>
|
||||
</entry>
|
||||
<entry>
|
||||
<string>Label</string>
|
||||
<string>WL0</string>
|
||||
</entry>
|
||||
</elementAttributes>
|
||||
<pos x="280" y="140"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>Driver</elementName>
|
||||
<elementAttributes>
|
||||
<entry>
|
||||
<string>rotation</string>
|
||||
<rotation rotation="1"/>
|
||||
</entry>
|
||||
<entry>
|
||||
<string>flipSelPos</string>
|
||||
<boolean>true</boolean>
|
||||
</entry>
|
||||
</elementAttributes>
|
||||
<pos x="400" y="440"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>Driver</elementName>
|
||||
<elementAttributes>
|
||||
<entry>
|
||||
<string>rotation</string>
|
||||
<rotation rotation="1"/>
|
||||
</entry>
|
||||
</elementAttributes>
|
||||
<pos x="680" y="440"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>In</elementName>
|
||||
<elementAttributes>
|
||||
<entry>
|
||||
<string>Description</string>
|
||||
<string>Write Enable</string>
|
||||
</entry>
|
||||
<entry>
|
||||
<string>Label</string>
|
||||
<string>WE</string>
|
||||
</entry>
|
||||
</elementAttributes>
|
||||
<pos x="280" y="480"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>In</elementName>
|
||||
<elementAttributes>
|
||||
<entry>
|
||||
<string>Description</string>
|
||||
<string>Data Input</string>
|
||||
</entry>
|
||||
<entry>
|
||||
<string>Label</string>
|
||||
<string>Data</string>
|
||||
</entry>
|
||||
</elementAttributes>
|
||||
<pos x="280" y="560"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>Not</elementName>
|
||||
<elementAttributes>
|
||||
<entry>
|
||||
<string>rotation</string>
|
||||
<rotation rotation="1"/>
|
||||
</entry>
|
||||
</elementAttributes>
|
||||
<pos x="400" y="540"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>Out</elementName>
|
||||
<elementAttributes>
|
||||
<entry>
|
||||
<string>Description</string>
|
||||
<string>Data Output</string>
|
||||
</entry>
|
||||
<entry>
|
||||
<string>Label</string>
|
||||
<string>D</string>
|
||||
</entry>
|
||||
</elementAttributes>
|
||||
<pos x="800" y="400"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>NFET</elementName>
|
||||
<elementAttributes/>
|
||||
<pos x="500" y="20"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>PFET</elementName>
|
||||
<elementAttributes/>
|
||||
<pos x="500" y="-80"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>NFET</elementName>
|
||||
<elementAttributes/>
|
||||
<pos x="580" y="20"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>PFET</elementName>
|
||||
<elementAttributes/>
|
||||
<pos x="580" y="-80"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>NFET</elementName>
|
||||
<elementAttributes>
|
||||
<entry>
|
||||
<string>rotation</string>
|
||||
<rotation rotation="3"/>
|
||||
</entry>
|
||||
</elementAttributes>
|
||||
<pos x="460" y="-20"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>NFET</elementName>
|
||||
<elementAttributes>
|
||||
<entry>
|
||||
<string>rotation</string>
|
||||
<rotation rotation="3"/>
|
||||
</entry>
|
||||
</elementAttributes>
|
||||
<pos x="660" y="-20"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>PullDown</elementName>
|
||||
<elementAttributes/>
|
||||
<pos x="520" y="80"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>PullDown</elementName>
|
||||
<elementAttributes/>
|
||||
<pos x="600" y="80"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>PullUp</elementName>
|
||||
<elementAttributes/>
|
||||
<pos x="520" y="-100"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>PullUp</elementName>
|
||||
<elementAttributes/>
|
||||
<pos x="600" y="-100"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>LED</elementName>
|
||||
<elementAttributes>
|
||||
<entry>
|
||||
<string>rotation</string>
|
||||
<rotation rotation="1"/>
|
||||
</entry>
|
||||
</elementAttributes>
|
||||
<pos x="560" y="-100"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>In</elementName>
|
||||
<elementAttributes>
|
||||
<entry>
|
||||
<string>Description</string>
|
||||
<string>Wortleitung 1</string>
|
||||
</entry>
|
||||
<entry>
|
||||
<string>Label</string>
|
||||
<string>WL1</string>
|
||||
</entry>
|
||||
</elementAttributes>
|
||||
<pos x="280" y="-160"/>
|
||||
</visualElement>
|
||||
</visualElements>
|
||||
<wires>
|
||||
<wire>
|
||||
<p1 x="460" y="0"/>
|
||||
<p2 x="480" y="0"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="660" y="0"/>
|
||||
<p2 x="680" y="0"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="520" y="0"/>
|
||||
<p2 x="560" y="0"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="400" y="0"/>
|
||||
<p2 x="420" y="0"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="560" y="0"/>
|
||||
<p2 x="620" y="0"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="280" y="480"/>
|
||||
<p2 x="540" y="480"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="480" y="360"/>
|
||||
<p2 x="500" y="360"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="560" y="360"/>
|
||||
<p2 x="580" y="360"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="460" y="300"/>
|
||||
<p2 x="480" y="300"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="660" y="300"/>
|
||||
<p2 x="680" y="300"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="520" y="300"/>
|
||||
<p2 x="560" y="300"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="400" y="300"/>
|
||||
<p2 x="420" y="300"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="560" y="300"/>
|
||||
<p2 x="620" y="300"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="280" y="140"/>
|
||||
<p2 x="420" y="140"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="620" y="140"/>
|
||||
<p2 x="800" y="140"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="420" y="140"/>
|
||||
<p2 x="620" y="140"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="480" y="-80"/>
|
||||
<p2 x="500" y="-80"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="560" y="-80"/>
|
||||
<p2 x="580" y="-80"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="280" y="560"/>
|
||||
<p2 x="400" y="560"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="400" y="560"/>
|
||||
<p2 x="680" y="560"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="680" y="400"/>
|
||||
<p2 x="800" y="400"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="480" y="-20"/>
|
||||
<p2 x="600" y="-20"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="420" y="440"/>
|
||||
<p2 x="540" y="440"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="540" y="440"/>
|
||||
<p2 x="660" y="440"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="480" y="280"/>
|
||||
<p2 x="600" y="280"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="480" y="220"/>
|
||||
<p2 x="500" y="220"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="560" y="220"/>
|
||||
<p2 x="580" y="220"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="480" y="60"/>
|
||||
<p2 x="500" y="60"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="560" y="60"/>
|
||||
<p2 x="580" y="60"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="280" y="-160"/>
|
||||
<p2 x="420" y="-160"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="420" y="-160"/>
|
||||
<p2 x="620" y="-160"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="620" y="-160"/>
|
||||
<p2 x="800" y="-160"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="400" y="460"/>
|
||||
<p2 x="400" y="500"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="400" y="540"/>
|
||||
<p2 x="400" y="560"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="400" y="-220"/>
|
||||
<p2 x="400" y="0"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="400" y="300"/>
|
||||
<p2 x="400" y="420"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="400" y="0"/>
|
||||
<p2 x="400" y="300"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="480" y="220"/>
|
||||
<p2 x="480" y="280"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="480" y="-80"/>
|
||||
<p2 x="480" y="-20"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="480" y="-20"/>
|
||||
<p2 x="480" y="0"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="480" y="0"/>
|
||||
<p2 x="480" y="60"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="480" y="280"/>
|
||||
<p2 x="480" y="300"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="480" y="300"/>
|
||||
<p2 x="480" y="360"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="560" y="200"/>
|
||||
<p2 x="560" y="220"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="560" y="-100"/>
|
||||
<p2 x="560" y="-80"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="560" y="-80"/>
|
||||
<p2 x="560" y="0"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="560" y="220"/>
|
||||
<p2 x="560" y="300"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="560" y="0"/>
|
||||
<p2 x="560" y="60"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="560" y="300"/>
|
||||
<p2 x="560" y="360"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="420" y="140"/>
|
||||
<p2 x="420" y="280"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="420" y="-160"/>
|
||||
<p2 x="420" y="-20"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="520" y="260"/>
|
||||
<p2 x="520" y="300"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="520" y="360"/>
|
||||
<p2 x="520" y="380"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="520" y="200"/>
|
||||
<p2 x="520" y="220"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="520" y="-40"/>
|
||||
<p2 x="520" y="0"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="520" y="60"/>
|
||||
<p2 x="520" y="80"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="520" y="-100"/>
|
||||
<p2 x="520" y="-80"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="520" y="300"/>
|
||||
<p2 x="520" y="320"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="520" y="0"/>
|
||||
<p2 x="520" y="20"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="600" y="260"/>
|
||||
<p2 x="600" y="280"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="600" y="360"/>
|
||||
<p2 x="600" y="380"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="600" y="200"/>
|
||||
<p2 x="600" y="220"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="600" y="-40"/>
|
||||
<p2 x="600" y="-20"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="600" y="60"/>
|
||||
<p2 x="600" y="80"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="600" y="-100"/>
|
||||
<p2 x="600" y="-80"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="600" y="-20"/>
|
||||
<p2 x="600" y="20"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="600" y="280"/>
|
||||
<p2 x="600" y="320"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="680" y="460"/>
|
||||
<p2 x="680" y="560"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="680" y="-220"/>
|
||||
<p2 x="680" y="0"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="680" y="300"/>
|
||||
<p2 x="680" y="400"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="680" y="0"/>
|
||||
<p2 x="680" y="300"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="680" y="400"/>
|
||||
<p2 x="680" y="420"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="620" y="140"/>
|
||||
<p2 x="620" y="280"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="620" y="-160"/>
|
||||
<p2 x="620" y="-20"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="540" y="440"/>
|
||||
<p2 x="540" y="480"/>
|
||||
</wire>
|
||||
</wires>
|
||||
</circuit>
|
@ -151,16 +151,6 @@ ist. Die jeweils anderen Ausgänge sind hochohmig.</string>
|
||||
</elementAttributes>
|
||||
<pos x="260" y="140"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>Const</elementName>
|
||||
<elementAttributes>
|
||||
<entry>
|
||||
<string>Value</string>
|
||||
<int>0</int>
|
||||
</entry>
|
||||
</elementAttributes>
|
||||
<pos x="280" y="160"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>Testcase</elementName>
|
||||
<elementAttributes>
|
||||
@ -233,6 +223,11 @@ ist. Die jeweils anderen Ausgänge sind hochohmig.</string>
|
||||
</elementAttributes>
|
||||
<pos x="760" y="160"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>Ground</elementName>
|
||||
<elementAttributes/>
|
||||
<pos x="280" y="180"/>
|
||||
</visualElement>
|
||||
</visualElements>
|
||||
<wires>
|
||||
<wire>
|
||||
@ -351,6 +346,10 @@ ist. Die jeweils anderen Ausgänge sind hochohmig.</string>
|
||||
<p1 x="600" y="220"/>
|
||||
<p2 x="600" y="380"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="280" y="160"/>
|
||||
<p2 x="280" y="180"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="540" y="160"/>
|
||||
<p2 x="540" y="180"/>
|
||||
|
@ -205,6 +205,20 @@ Bits übereinstimmen.</string>
|
||||
</elementAttributes>
|
||||
<pos x="880" y="40"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>Testcase</elementName>
|
||||
<elementAttributes>
|
||||
<entry>
|
||||
<string>Testdata</string>
|
||||
<testData>
|
||||
<dataString> P<Q_i P=Q_i P>Q_i P_3 P_2 P_1 P_0 Q_3 Q_2 Q_1 Q_0 P<Q P=Q P>Q
|
||||
repeat(256) 0 1 0 bits(4,n>>4) bits(4,n) ((n>>4)<(n&15)) ((n>>4)=(n&15)) ((n>>4)>(n&15))
|
||||
repeat(2<<(3+4)) bits(3,n) bits(4,n>>3) bits(4,n>>3) bits(3,n)</dataString>
|
||||
</testData>
|
||||
</entry>
|
||||
</elementAttributes>
|
||||
<pos x="840" y="320"/>
|
||||
</visualElement>
|
||||
</visualElements>
|
||||
<wires>
|
||||
<wire>
|
||||
|
@ -419,6 +419,19 @@
|
||||
</elementAttributes>
|
||||
<pos x="620" y="300"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>Testcase</elementName>
|
||||
<elementAttributes>
|
||||
<entry>
|
||||
<string>Testdata</string>
|
||||
<testData>
|
||||
<dataString>A_11 A_10 A_9 A_8 A_7 A_6 A_5 A_4 A_3 A_2 A_1 A_0 B_11 B_10 B_9 B_8 B_7 B_6 B_5 B_4 B_3 B_2 B_1 B_0 P<Q P=Q P>Q
|
||||
repeat(1<<16) bits(12,n>>8) bits(12,n&0xff) ((n>>8)<(n&0xff)) ((n>>8)=(n&0xff)) ((n>>8)>(n&0xff))</dataString>
|
||||
</testData>
|
||||
</entry>
|
||||
</elementAttributes>
|
||||
<pos x="580" y="740"/>
|
||||
</visualElement>
|
||||
</visualElements>
|
||||
<wires>
|
||||
<wire>
|
||||
|
@ -185,6 +185,22 @@ Subtraction (S=1) umgeschaltet werden kann.</string>
|
||||
</elementAttributes>
|
||||
<pos x="180" y="440"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>Testcase</elementName>
|
||||
<elementAttributes>
|
||||
<entry>
|
||||
<string>Testdata</string>
|
||||
<testData>
|
||||
<dataString>
|
||||
S A_3 A_2 A_1 A_0 B_3 B_2 B_1 B_0 S_3 S_2 S_1 S_0
|
||||
repeat(256) 0 bits(4,n>>4) bits(4,n) bits(4,(n>>4)+(n&15))
|
||||
repeat(256) 1 bits(4,n>>4) bits(4,n) bits(4,(n>>4)-(n&15))
|
||||
</dataString>
|
||||
</testData>
|
||||
</entry>
|
||||
</elementAttributes>
|
||||
<pos x="440" y="400"/>
|
||||
</visualElement>
|
||||
</visualElements>
|
||||
<wires>
|
||||
<wire>
|
||||
|
@ -31,6 +31,10 @@ aus vier Volladdierern.</string>
|
||||
<string>Label</string>
|
||||
<string>A_0</string>
|
||||
</entry>
|
||||
<entry>
|
||||
<string>Default</string>
|
||||
<int>1</int>
|
||||
</entry>
|
||||
</elementAttributes>
|
||||
<pos x="300" y="320"/>
|
||||
</visualElement>
|
||||
@ -66,6 +70,10 @@ aus vier Volladdierern.</string>
|
||||
<string>Label</string>
|
||||
<string>A_1</string>
|
||||
</entry>
|
||||
<entry>
|
||||
<string>Default</string>
|
||||
<int>1</int>
|
||||
</entry>
|
||||
</elementAttributes>
|
||||
<pos x="300" y="220"/>
|
||||
</visualElement>
|
||||
@ -111,6 +119,10 @@ aus vier Volladdierern.</string>
|
||||
<string>Label</string>
|
||||
<string>B_2</string>
|
||||
</entry>
|
||||
<entry>
|
||||
<string>Default</string>
|
||||
<int>1</int>
|
||||
</entry>
|
||||
</elementAttributes>
|
||||
<pos x="300" y="160"/>
|
||||
</visualElement>
|
||||
@ -146,6 +158,10 @@ aus vier Volladdierern.</string>
|
||||
<string>Label</string>
|
||||
<string>B_3</string>
|
||||
</entry>
|
||||
<entry>
|
||||
<string>Default</string>
|
||||
<int>1</int>
|
||||
</entry>
|
||||
</elementAttributes>
|
||||
<pos x="300" y="60"/>
|
||||
</visualElement>
|
||||
|
@ -41,7 +41,7 @@ logische Funktion mit zwei Eingängen nachbilden.</string>
|
||||
<visualElement>
|
||||
<elementName>Ground</elementName>
|
||||
<elementAttributes/>
|
||||
<pos x="100" y="200"/>
|
||||
<pos x="-60" y="200"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>Switch</elementName>
|
||||
@ -59,12 +59,12 @@ logische Funktion mit zwei Eingängen nachbilden.</string>
|
||||
<string>S_3</string>
|
||||
</entry>
|
||||
</elementAttributes>
|
||||
<pos x="100" y="180"/>
|
||||
<pos x="-60" y="180"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>Ground</elementName>
|
||||
<elementAttributes/>
|
||||
<pos x="40" y="200"/>
|
||||
<pos x="0" y="200"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>Switch</elementName>
|
||||
@ -78,12 +78,12 @@ logische Funktion mit zwei Eingängen nachbilden.</string>
|
||||
<string>S_2</string>
|
||||
</entry>
|
||||
</elementAttributes>
|
||||
<pos x="40" y="180"/>
|
||||
<pos x="0" y="180"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>Ground</elementName>
|
||||
<elementAttributes/>
|
||||
<pos x="-20" y="200"/>
|
||||
<pos x="60" y="200"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>Switch</elementName>
|
||||
@ -97,12 +97,12 @@ logische Funktion mit zwei Eingängen nachbilden.</string>
|
||||
<string>S_1</string>
|
||||
</entry>
|
||||
</elementAttributes>
|
||||
<pos x="-20" y="180"/>
|
||||
<pos x="60" y="180"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>Ground</elementName>
|
||||
<elementAttributes/>
|
||||
<pos x="-80" y="200"/>
|
||||
<pos x="120" y="200"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>Switch</elementName>
|
||||
@ -120,27 +120,27 @@ logische Funktion mit zwei Eingängen nachbilden.</string>
|
||||
<string>S_0</string>
|
||||
</entry>
|
||||
</elementAttributes>
|
||||
<pos x="-80" y="180"/>
|
||||
<pos x="120" y="180"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>PullUp</elementName>
|
||||
<elementAttributes/>
|
||||
<pos x="-80" y="40"/>
|
||||
<pos x="120" y="40"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>PullUp</elementName>
|
||||
<elementAttributes/>
|
||||
<pos x="-20" y="40"/>
|
||||
<pos x="60" y="40"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>PullUp</elementName>
|
||||
<elementAttributes/>
|
||||
<pos x="40" y="40"/>
|
||||
<pos x="0" y="40"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>PullUp</elementName>
|
||||
<elementAttributes/>
|
||||
<pos x="100" y="40"/>
|
||||
<pos x="-60" y="40"/>
|
||||
</visualElement>
|
||||
<visualElement>
|
||||
<elementName>Out</elementName>
|
||||
@ -182,7 +182,7 @@ definiert.</string>
|
||||
</visualElements>
|
||||
<wires>
|
||||
<wire>
|
||||
<p1 x="-20" y="80"/>
|
||||
<p1 x="60" y="80"/>
|
||||
<p2 x="200" y="80"/>
|
||||
</wire>
|
||||
<wire>
|
||||
@ -194,7 +194,7 @@ definiert.</string>
|
||||
<p2 x="180" y="-100"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="40" y="100"/>
|
||||
<p1 x="0" y="100"/>
|
||||
<p2 x="200" y="100"/>
|
||||
</wire>
|
||||
<wire>
|
||||
@ -202,7 +202,7 @@ definiert.</string>
|
||||
<p2 x="200" y="20"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="100" y="120"/>
|
||||
<p1 x="-60" y="120"/>
|
||||
<p2 x="200" y="120"/>
|
||||
</wire>
|
||||
<wire>
|
||||
@ -218,7 +218,7 @@ definiert.</string>
|
||||
<p2 x="300" y="60"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="-80" y="60"/>
|
||||
<p1 x="120" y="60"/>
|
||||
<p2 x="180" y="60"/>
|
||||
</wire>
|
||||
<wire>
|
||||
@ -226,28 +226,16 @@ definiert.</string>
|
||||
<p2 x="160" y="20"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="-20" y="180"/>
|
||||
<p2 x="-20" y="200"/>
|
||||
<p1 x="0" y="180"/>
|
||||
<p2 x="0" y="200"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="-20" y="40"/>
|
||||
<p2 x="-20" y="80"/>
|
||||
<p1 x="0" y="40"/>
|
||||
<p2 x="0" y="100"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="-20" y="80"/>
|
||||
<p2 x="-20" y="140"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="100" y="180"/>
|
||||
<p2 x="100" y="200"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="100" y="40"/>
|
||||
<p2 x="100" y="120"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="100" y="120"/>
|
||||
<p2 x="100" y="140"/>
|
||||
<p1 x="0" y="100"/>
|
||||
<p2 x="0" y="140"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="180" y="40"/>
|
||||
@ -258,28 +246,40 @@ definiert.</string>
|
||||
<p2 x="180" y="0"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="40" y="180"/>
|
||||
<p2 x="40" y="200"/>
|
||||
<p1 x="120" y="180"/>
|
||||
<p2 x="120" y="200"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="40" y="40"/>
|
||||
<p2 x="40" y="100"/>
|
||||
<p1 x="120" y="40"/>
|
||||
<p2 x="120" y="60"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="40" y="100"/>
|
||||
<p2 x="40" y="140"/>
|
||||
<p1 x="120" y="60"/>
|
||||
<p2 x="120" y="140"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="-80" y="180"/>
|
||||
<p2 x="-80" y="200"/>
|
||||
<p1 x="-60" y="180"/>
|
||||
<p2 x="-60" y="200"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="-80" y="40"/>
|
||||
<p2 x="-80" y="60"/>
|
||||
<p1 x="-60" y="40"/>
|
||||
<p2 x="-60" y="120"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="-80" y="60"/>
|
||||
<p2 x="-80" y="140"/>
|
||||
<p1 x="-60" y="120"/>
|
||||
<p2 x="-60" y="140"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="60" y="180"/>
|
||||
<p2 x="60" y="200"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="60" y="40"/>
|
||||
<p2 x="60" y="80"/>
|
||||
</wire>
|
||||
<wire>
|
||||
<p1 x="60" y="80"/>
|
||||
<p2 x="60" y="140"/>
|
||||
</wire>
|
||||
</wires>
|
||||
</circuit>
|
@ -28,8 +28,8 @@ public class TestExamples extends TestCase {
|
||||
*/
|
||||
public void testDistExamples() throws Exception {
|
||||
File examples = new File(Resources.getRoot().getParentFile().getParentFile(), "/main/dig");
|
||||
assertEquals(109, new FileScanner(this::check).scan(examples));
|
||||
assertEquals(55, testCasesInFiles);
|
||||
assertEquals(110, new FileScanner(this::check).scan(examples));
|
||||
assertEquals(58, testCasesInFiles);
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
x
Reference in New Issue
Block a user