Skip to content
Open

Dev #25

Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
56 commits
Select commit Hold shift + click to select a range
6e1c55f
Create DiscoveryDevice.cs
julerobb1 Jan 9, 2026
3741474
Update PlatformManager.cs
julerobb1 Jan 9, 2026
ffffaee
Update EmulatorDisplay.cs
julerobb1 Jan 9, 2026
617b532
Update EmulatorConsole.cs
julerobb1 Jan 9, 2026
f5b4944
Added Llama proofing
julerobb1 Jan 9, 2026
cf2b1c2
Update ProcessorEmulator.csproj
julerobb1 Jan 9, 2026
4aa18ee
Update MainWindow.xaml
julerobb1 Jan 9, 2026
b685719
Update MainWindow.xaml.cs
julerobb1 Jan 9, 2026
a453749
Update MainWindow.xaml.cs
julerobb1 Jan 10, 2026
944f0e5
Bump .NET to 8 and add emulation features
julerobb1 Feb 5, 2026
0be76f4
Downgrade to .NET 5 and add MIPS emulation plumbing
julerobb1 Feb 5, 2026
85be0df
Update CP0.cs
julerobb1 Feb 5, 2026
94ba593
Update MediaroomBootManager.cs
julerobb1 Feb 5, 2026
2ca739b
Update XG1v4Emulator.cs
julerobb1 Feb 5, 2026
86a0880
Update UnicornChipsetEmulator.cs
julerobb1 Feb 5, 2026
30f79d7
Create MipsUart.cs
julerobb1 Feb 5, 2026
8661889
Update MipsCpuEmulator.cs
julerobb1 Feb 5, 2026
b3e1883
Update MipsBus.cs
julerobb1 Feb 5, 2026
5ced051
Update IChipsetEmulator.cs
julerobb1 Feb 5, 2026
8ebc102
Update IChipsetEmulator.cs
julerobb1 Feb 5, 2026
3ac83e9
Update RDKVEmulator.cs
julerobb1 Feb 5, 2026
9079d99
Update UnicornChipsetEmulator.cs
julerobb1 Feb 5, 2026
98b9b0c
Update UverseEmulator.cs
julerobb1 Feb 5, 2026
6816c9d
Initialize MIPS emulator and add console logging
julerobb1 Feb 5, 2026
8c473a4
Update MipsCpuEmulator.cs
julerobb1 Feb 5, 2026
0fef970
Create VirtualRegistry.cs
julerobb1 Feb 5, 2026
efb6ff5
I give up
julerobb1 Feb 5, 2026
2d14a33
Update BoltDemo.AssemblyInfo.cs
julerobb1 Feb 5, 2026
be1b634
Update BoltDemo.AssemblyInfoInputs.cache
julerobb1 Feb 5, 2026
75e7a15
Update CpuState.cs
julerobb1 Feb 5, 2026
bb595ee
Update HypervisorWindow.xaml.cs
julerobb1 Feb 5, 2026
2307ae0
Update MipsBus.cs
julerobb1 Feb 5, 2026
348ad4f
Update MipsCpuEmulator.cs
julerobb1 Feb 5, 2026
6cd19b0
Update ProcessorEmulator.csproj
julerobb1 Feb 5, 2026
6648b1d
Update CpuState.cs
julerobb1 Feb 5, 2026
dab710f
Update EmulatorConsole.cs
julerobb1 Feb 5, 2026
e955c15
Update MipsBus.cs
julerobb1 Feb 5, 2026
d412a2d
Update MipsCpuEmulator.cs
julerobb1 Feb 5, 2026
5a129cb
Create HypervisorWindow.cs
julerobb1 Feb 5, 2026
ddb55e7
Update HypervisorWindow.xaml.cs
julerobb1 Feb 5, 2026
fc122d9
Update ProcessorEmulator.csproj
julerobb1 Feb 5, 2026
187ac42
Update HypervisorWindow.xaml.cs
julerobb1 Feb 5, 2026
f9c3087
Update HypervisorWindow.cs
julerobb1 Feb 5, 2026
ba717d1
Update MainWindow.xaml
julerobb1 Feb 5, 2026
771d454
Update ProcessorEmulator.csproj
julerobb1 Feb 5, 2026
f5fa26d
Update Win7Chrome.cs
julerobb1 Feb 6, 2026
1465a1d
Update ProcessorEmulator.csproj
julerobb1 Feb 6, 2026
2decb70
Update .gitignore
julerobb1 Feb 6, 2026
f0c97b7
Update SyncScheduler.cs
julerobb1 Feb 6, 2026
7a47de2
Update ProcessorEmulator.csproj
julerobb1 Feb 6, 2026
c981748
Update Windows7ThemeManager.cs
julerobb1 Feb 6, 2026
3a5d5ea
Update RealHypervisorDisplay.cs
julerobb1 Feb 6, 2026
510fa6d
Update MainWindow.Themes.cs
julerobb1 Feb 6, 2026
7ee3358
Don' think these are cirtical but i'll submit anyways,
julerobb1 Feb 7, 2026
a508af0
Ambiguity Fixes
julerobb1 Feb 7, 2026
adb72d0
Update MainWindow.Themes.cs
julerobb1 Feb 7, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: 6.0.x
dotnet-version: 5.0.x

- name: Restore dependencies
run: dotnet restore ProcessorEmulator.csproj
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:
- name: Setup .NET SDK
uses: actions/setup-dotnet@v3
with:
dotnet-version: '6.0.x'
dotnet-version: '5.0.x'

- name: Restore dependencies
run: dotnet restore Processor-Emulator.sln
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/dotnet-desktop-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
- uses: actions/checkout@v4
- uses: actions/setup-dotnet@v3
with:
dotnet-version: '6.0.x'
dotnet-version: '5.0.x'
# Restore NuGet packages before building
- name: Restore packages
run: dotnet restore ProcessorEmulator.csproj
Expand All @@ -29,7 +29,7 @@ jobs:
- uses: actions/checkout@v4
- uses: actions/setup-dotnet@v3
with:
dotnet-version: '6.0.x'
dotnet-version: '5.0.x'
# Restore NuGet packages before building
- name: Restore packages
run: dotnet restore ProcessorEmulator.csproj
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -25,3 +25,4 @@ MipsBranchTest/obj/Debug/net6.0-windows/MipsBranchTest.csproj.FileListAbsolute.t
*.ps1
/.vscode
.geminiignore
duplicate_definitions_report.md
2 changes: 1 addition & 1 deletion App.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

namespace ProcessorEmulator
{
public partial class App : Application
public partial class App : System.Windows.Application
{
private static string StartupLogPath => System.IO.Path.Combine(System.IO.Path.GetTempPath(), "ProcessorEmulator_startup.log");
private static void Log(string line)
Expand Down
1 change: 1 addition & 0 deletions AppThemeManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
using System.Linq;
using System.Windows;
using System.Runtime.Versioning;
using Application = System.Windows.Application;

namespace ProcessorEmulator
{
Expand Down
110 changes: 110 additions & 0 deletions ArmHypervisor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -162,6 +162,11 @@ private void ExecuteInstruction()
{
executed = ExecuteLoadStore(instruction);
}
// Load/Store Multiple Instructions (bits 27-25 = 100)
else if ((instruction & 0x0E000000) == 0x08000000)
{
executed = ExecuteLoadStoreMultiple(instruction);
}
// Branch Instructions (bits 27-25 = 101)
else if ((instruction & 0x0E000000) == 0x0A000000)
{
Expand Down Expand Up @@ -210,15 +215,41 @@ private bool ExecuteDataProcessing(uint instruction)
result = (uint)addResult;
carryOut = addResult > 0xFFFFFFFF;
break;
case 0x8: // TST
result = rnValue & operand2;
setFlags = true;
rd = 16; // Don't write to any register
break;
case 0x9: // TEQ
result = rnValue ^ operand2;
setFlags = true;
rd = 16; // Don't write to any register
break;
case 0xA: // CMP (SUB but don't store result)
result = rnValue - operand2;
carryOut = rnValue >= operand2;
setFlags = true; // CMP always sets flags
rd = 16; // Don't write to any register
break;
case 0xB: // CMN
long cmnResult = (long)rnValue + operand2;
result = (uint)cmnResult;
carryOut = cmnResult > 0xFFFFFFFF;
setFlags = true;
rd = 16; // Don't write to any register
break;
case 0xC: // ORR
result = rnValue | operand2;
break;
case 0xD: // MOV
result = operand2;
break;
case 0xE: // BIC
result = rnValue & ~operand2;
break;
case 0xF: // MVN
result = ~operand2;
break;
default:
Debug.WriteLine($"[HV] Unhandled data processing opcode: 0x{opcode:X}");
return false;
Expand Down Expand Up @@ -297,6 +328,79 @@ private bool ExecuteLoadStore(uint instruction)
return true;
}

private bool ExecuteLoadStoreMultiple(uint instruction)
{
bool isLoad = (instruction & 0x00100000) != 0; // L bit
bool writeBack = (instruction & 0x00200000) != 0; // W bit
bool increment = (instruction & 0x00800000) != 0; // U bit
bool preIndex = (instruction & 0x01000000) != 0; // P bit
uint rn = (instruction >> 16) & 0xF; // Base register
uint regList = instruction & 0xFFFF;

uint address = registers[rn];
int regCount = 0;
for (int i = 0; i < 16; i++)
{
if ((regList & (1 << i)) != 0)
{
regCount++;
}
}

if (!increment) // Decrement
{
address -= (uint)(regCount * 4);
}
if (preIndex)
{
if (increment)
{
address += 4;
}
else
{
// address is already correct
}
}

for (int i = 0; i < 16; i++)
{
if ((regList & (1 << i)) != 0)
{
if (isLoad)
{
registers[i] = ReadMemory32(address);
Debug.WriteLine($"[HV] LDM: R{i} = 0x{registers[i]:X8} from [0x{address:X8}]");
}
else
{
WriteMemory32(address, registers[i]);
Debug.WriteLine($"[HV] STM: [0x{address:X8}] = 0x{registers[i]:X8}");
}
address += 4;
}
}

if (writeBack)
{
if (increment)
{
registers[rn] += (uint)(regCount * 4);
}
else
{
registers[rn] -= (uint)(regCount * 4);
}
}

if (!isLoad || (regList & (1 << 15)) == 0)
{
registers[15] += 4;
}

return true;
}

private bool ExecuteBranch(uint instruction)
{
bool isLink = (instruction & 0x01000000) != 0; // L bit
Expand Down Expand Up @@ -452,6 +556,12 @@ private string DecodeInstruction(uint instruction)

return isLoad ? $"LDR R{rd}, [R{rn}]" : $"STR R{rd}, [R{rn}]";
}
else if ((instruction & 0x0E000000) == 0x08000000) // Load/Store Multiple
{
bool isLoad = (instruction & 0x00100000) != 0;
uint rn = (instruction >> 16) & 0xF;
return isLoad ? $"LDM R{rn}" : $"STM R{rn}";
}
else if ((instruction & 0x0E000000) == 0x0A000000) // Branch
{
bool isLink = (instruction & 0x01000000) != 0;
Expand Down
22 changes: 2 additions & 20 deletions BoltDemo_Standalone/obj/BoltDemo.csproj.nuget.dgspec.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
"auditLevel": "low",
"auditMode": "direct"
},
"SdkAnalysisLevel": "9.0.300"
"SdkAnalysisLevel": "10.0.100"
},
"frameworks": {
"net6.0": {
Expand All @@ -54,30 +54,12 @@
],
"assetTargetFallback": true,
"warn": true,
"downloadDependencies": [
{
"name": "Microsoft.AspNetCore.App.Ref",
"version": "[6.0.36, 6.0.36]"
},
{
"name": "Microsoft.NETCore.App.Host.win-x64",
"version": "[6.0.36, 6.0.36]"
},
{
"name": "Microsoft.NETCore.App.Ref",
"version": "[6.0.36, 6.0.36]"
},
{
"name": "Microsoft.WindowsDesktop.App.Ref",
"version": "[6.0.36, 6.0.36]"
}
],
"frameworkReferences": {
"Microsoft.NETCore.App": {
"privateAssets": "all"
}
},
"runtimeIdentifierGraphPath": "C:\\Program Files\\dotnet\\sdk\\9.0.300\\RuntimeIdentifierGraph.json"
"runtimeIdentifierGraphPath": "C:\\Program Files\\dotnet\\sdk\\10.0.102\\RuntimeIdentifierGraph.json"
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion BoltDemo_Standalone/obj/BoltDemo.csproj.nuget.g.props
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<NuGetPackageRoot Condition=" '$(NuGetPackageRoot)' == '' ">$(UserProfile)\.nuget\packages\</NuGetPackageRoot>
<NuGetPackageFolders Condition=" '$(NuGetPackageFolders)' == '' ">C:\Users\juler\.nuget\packages\</NuGetPackageFolders>
<NuGetProjectStyle Condition=" '$(NuGetProjectStyle)' == '' ">PackageReference</NuGetProjectStyle>
<NuGetToolVersion Condition=" '$(NuGetToolVersion)' == '' ">6.14.0</NuGetToolVersion>
<NuGetToolVersion Condition=" '$(NuGetToolVersion)' == '' ">7.0.0</NuGetToolVersion>
</PropertyGroup>
<ItemGroup Condition=" '$(ExcludeRestorePackageImports)' != 'true' ">
<SourceRoot Include="C:\Users\juler\.nuget\packages\" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
[assembly: System.Reflection.AssemblyCompanyAttribute("BoltDemo")]
[assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")]
[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")]
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+804bf781e2247bc2d60c687463eb00bdc6855b4e")]
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+510fa6da2e9fa243e5b3fbb3a35ffc6d705bb3be")]
[assembly: System.Reflection.AssemblyProductAttribute("BoltDemo")]
[assembly: System.Reflection.AssemblyTitleAttribute("BoltDemo")]
[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")]
Expand Down
Original file line number Diff line number Diff line change
@@ -1 +1 @@
c8b6793e0acd9d438065242c46ec4e0309651be119b1a9ed9ffd903db716a9c8
86cc116b25dfe63cfdc820e94796b6d487fe6cc62d57683ae144a2c8144611c9
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
is_global = true
build_property.TargetFramework = net6.0
build_property.TargetFrameworkIdentifier = .NETCoreApp
build_property.TargetFrameworkVersion = v6.0
build_property.TargetPlatformMinVersion =
build_property.UsingMicrosoftNETSdkWeb =
build_property.ProjectTypeGuids =
Expand Down
14 changes: 7 additions & 7 deletions BoltDemo_Standalone/obj/Debug/net6.0/BoltDemo.GlobalUsings.g.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
// <auto-generated/>
global using global::System;
global using global::System.Collections.Generic;
global using global::System.IO;
global using global::System.Linq;
global using global::System.Net.Http;
global using global::System.Threading;
global using global::System.Threading.Tasks;
global using System;
global using System.Collections.Generic;
global using System.IO;
global using System.Linq;
global using System.Net.Http;
global using System.Threading;
global using System.Threading.Tasks;
Binary file modified BoltDemo_Standalone/obj/Debug/net6.0/BoltDemo.assets.cache
Binary file not shown.
28 changes: 5 additions & 23 deletions BoltDemo_Standalone/obj/project.assets.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,11 @@
"project": {
"version": "1.0.0",
"restore": {
"projectUniqueName": "c:\\Users\\juler\\Documents\\GitHub\\Processor-Emulator\\BoltDemo_Standalone\\BoltDemo.csproj",
"projectUniqueName": "C:\\Users\\juler\\Documents\\GitHub\\Processor-Emulator\\BoltDemo_Standalone\\BoltDemo.csproj",
"projectName": "BoltDemo",
"projectPath": "c:\\Users\\juler\\Documents\\GitHub\\Processor-Emulator\\BoltDemo_Standalone\\BoltDemo.csproj",
"projectPath": "C:\\Users\\juler\\Documents\\GitHub\\Processor-Emulator\\BoltDemo_Standalone\\BoltDemo.csproj",
"packagesPath": "C:\\Users\\juler\\.nuget\\packages\\",
"outputPath": "c:\\Users\\juler\\Documents\\GitHub\\Processor-Emulator\\BoltDemo_Standalone\\obj\\",
"outputPath": "C:\\Users\\juler\\Documents\\GitHub\\Processor-Emulator\\BoltDemo_Standalone\\obj\\",
"projectStyle": "PackageReference",
"configFilePaths": [
"C:\\Users\\juler\\AppData\\Roaming\\NuGet\\NuGet.Config"
Expand All @@ -44,7 +44,7 @@
"auditLevel": "low",
"auditMode": "direct"
},
"SdkAnalysisLevel": "9.0.300"
"SdkAnalysisLevel": "10.0.100"
},
"frameworks": {
"net6.0": {
Expand All @@ -60,30 +60,12 @@
],
"assetTargetFallback": true,
"warn": true,
"downloadDependencies": [
{
"name": "Microsoft.AspNetCore.App.Ref",
"version": "[6.0.36, 6.0.36]"
},
{
"name": "Microsoft.NETCore.App.Host.win-x64",
"version": "[6.0.36, 6.0.36]"
},
{
"name": "Microsoft.NETCore.App.Ref",
"version": "[6.0.36, 6.0.36]"
},
{
"name": "Microsoft.WindowsDesktop.App.Ref",
"version": "[6.0.36, 6.0.36]"
}
],
"frameworkReferences": {
"Microsoft.NETCore.App": {
"privateAssets": "all"
}
},
"runtimeIdentifierGraphPath": "C:\\Program Files\\dotnet\\sdk\\9.0.300\\RuntimeIdentifierGraph.json"
"runtimeIdentifierGraphPath": "C:\\Program Files\\dotnet\\sdk\\10.0.102\\RuntimeIdentifierGraph.json"
}
}
}
Expand Down
9 changes: 2 additions & 7 deletions BoltDemo_Standalone/obj/project.nuget.cache
Original file line number Diff line number Diff line change
@@ -1,13 +1,8 @@
{
"version": 2,
"dgSpecHash": "9EVy3SwQS1o=",
"dgSpecHash": "VrZ3Gz65KCg=",
"success": true,
"projectFilePath": "C:\\Users\\juler\\Documents\\GitHub\\Processor-Emulator\\BoltDemo_Standalone\\BoltDemo.csproj",
"expectedPackageFiles": [
"C:\\Users\\juler\\.nuget\\packages\\microsoft.netcore.app.ref\\6.0.36\\microsoft.netcore.app.ref.6.0.36.nupkg.sha512",
"C:\\Users\\juler\\.nuget\\packages\\microsoft.windowsdesktop.app.ref\\6.0.36\\microsoft.windowsdesktop.app.ref.6.0.36.nupkg.sha512",
"C:\\Users\\juler\\.nuget\\packages\\microsoft.aspnetcore.app.ref\\6.0.36\\microsoft.aspnetcore.app.ref.6.0.36.nupkg.sha512",
"C:\\Users\\juler\\.nuget\\packages\\microsoft.netcore.app.host.win-x64\\6.0.36\\microsoft.netcore.app.host.win-x64.6.0.36.nupkg.sha512"
],
"expectedPackageFiles": [],
"logs": []
}
Loading
Loading