This commit is contained in:
Joel Beckmeyer 2017-04-26 19:57:44 -04:00
commit 0b29c9e2b5
12 changed files with 39 additions and 10 deletions

BIN
Homework6_Daniel_Joel.zip Normal file

Binary file not shown.

View File

@ -175,6 +175,14 @@
<ItemGroup>
<None Include="..\..\readme.md" />
</ItemGroup>
<ItemGroup>
<Image Include="..\..\Screenshots\circuit0.JPG" />
<Image Include="..\..\Screenshots\circuit1.JPG" />
<Image Include="..\..\Screenshots\circuit2.JPG" />
<Image Include="..\..\Screenshots\circuit3.JPG" />
<Image Include="..\..\Screenshots\circuit4.JPG" />
<Image Include="..\..\Screenshots\circuit5.JPG" />
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>

View File

@ -98,4 +98,24 @@
<Filter>Resource Files</Filter>
</None>
</ItemGroup>
<ItemGroup>
<Image Include="..\..\Screenshots\circuit0.JPG">
<Filter>Resource Files</Filter>
</Image>
<Image Include="..\..\Screenshots\circuit1.JPG">
<Filter>Resource Files</Filter>
</Image>
<Image Include="..\..\Screenshots\circuit2.JPG">
<Filter>Resource Files</Filter>
</Image>
<Image Include="..\..\Screenshots\circuit3.JPG">
<Filter>Resource Files</Filter>
</Image>
<Image Include="..\..\Screenshots\circuit4.JPG">
<Filter>Resource Files</Filter>
</Image>
<Image Include="..\..\Screenshots\circuit5.JPG">
<Filter>Resource Files</Filter>
</Image>
</ItemGroup>
</Project>

BIN
Screenshots/circuit0.JPG Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 34 KiB

BIN
Screenshots/circuit1.JPG Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 36 KiB

BIN
Screenshots/circuit2.JPG Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 38 KiB

BIN
Screenshots/circuit3.JPG Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 36 KiB

BIN
Screenshots/circuit4.JPG Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 37 KiB

BIN
Screenshots/circuit5.JPG Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 35 KiB

View File

@ -37,4 +37,3 @@ bool operator<(const Event &e1, const Event &e2) {
}
return e1.evTime > e2.evTime;
}

View File

@ -18,14 +18,7 @@ int main() {
cout << "Please enter filename: ";
getline(cin, fileName);
cout << "What time do you want to simulate to (default 60ns)? ";
if (cin.peek() == '\n') {
len = 60;
}
else if (!(cin >> len)) {
cout << "Invalid input; using 60.\n";
len = 60;
}
canOpen = e.parseCircuit(fileName);
// 2. Parse the vector file to initialize the simulation Queue with initial
@ -38,10 +31,19 @@ int main() {
// third, create and queue any future Wire state changes as new Events
// fourth, apply e's effects
if(canOpen) {
cout << "What time do you want to simulate to (default 60ns)? ";
if (cin.peek() == '\n') {
len = 60;
}
else if (!(cin >> len)) {
cout << "Invalid input; using 60.\n";
len = 60;
}
e.simulate(len);
// 4. Print the results of the simulation
e.print(len);
system("pause");
}
system("pause");
return 0;
}

BIN
src/termproject.pdf Normal file

Binary file not shown.