Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
31 commits
Select commit Hold shift + click to select a range
2e7ced6
trying to make a 16 bit inputs and outputs
parshwa282011 Apr 24, 2025
668df02
Merge branch 'SebLague:main' into main
parshwa282011 Apr 25, 2025
4b4646e
Merge branch 'SebLague:main' into main
parshwa282011 Apr 27, 2025
7cbe789
RGBLED working + added 16 Bit Bus, and 16 Bit IN?OUT the 16 Bit merge…
Apr 27, 2025
bde3e55
ALL 16-BIT merge and Splits work now
Apr 27, 2025
7a80580
fixed a few bugs
May 5, 2025
253e3c4
Merge branch 'main' into merge
parshwa282011 May 5, 2025
c0925da
Merging for new updates
parshwa282011 May 5, 2025
0cba679
changed 0b11111111111111111111111111111111 to 0xFFFFFFFF as suggested
parshwa282011 May 5, 2025
0cf294e
Removing vscode files
parshwa282011 May 5, 2025
628175f
Create main.yml
parshwa282011 May 5, 2025
aa68418
My mistake i ment for this to be on test branch
parshwa282011 May 5, 2025
2365be1
Works with Ascii 8bit
May 7, 2025
dc74672
Made Ascii 8Bit work
parshwa282011 May 7, 2025
f0632ab
reworked key chip and text display chip
Jun 16, 2025
40630d9
port http server
Jun 18, 2025
7bfbd41
tons of updates also realistic internet interface
Jul 5, 2025
af63d5d
trying to make a 16 bit inputs and outputs
parshwa282011 Apr 24, 2025
9cf7592
RGBLED working + added 16 Bit Bus, and 16 Bit IN?OUT the 16 Bit merge…
Apr 27, 2025
6480791
ALL 16-BIT merge and Splits work now
Apr 27, 2025
5756e71
fixed a few bugs
May 5, 2025
8bbc087
changed 0b11111111111111111111111111111111 to 0xFFFFFFFF as suggested
parshwa282011 May 5, 2025
07a9bc9
Removing vscode files
parshwa282011 May 5, 2025
f0cafcc
Create main.yml
parshwa282011 May 5, 2025
8dfa717
My mistake i ment for this to be on test branch
parshwa282011 May 5, 2025
df89059
Works with Ascii 8bit
May 7, 2025
e7c4938
reworked key chip and text display chip
Jun 16, 2025
a89d39d
port http server
Jun 18, 2025
68993fe
tons of updates also realistic internet interface
Jul 5, 2025
3607bce
Merge pull request #7 from parshwa282011/squigglesdev-main
parshwa282011 Jul 5, 2025
729bb1f
finally merged all modding api
Jul 13, 2025
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
Binary file added .DS_Store
Binary file not shown.
5 changes: 5 additions & 0 deletions .vscode/extensions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"recommendations": [
"visualstudiotoolsforunity.vstuc"
]
}
10 changes: 10 additions & 0 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"version": "0.2.0",
"configurations": [
{
"name": "Attach to Unity",
"type": "vstuc",
"request": "attach"
}
]
}
70 changes: 70 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
{
"files.exclude": {
"**/.DS_Store": true,
"**/.git": true,
"**/.vs": true,
"**/.gitmodules": true,
"**/.vsconfig": true,
"**/*.booproj": true,
"**/*.pidb": true,
"**/*.suo": true,
"**/*.user": true,
"**/*.userprefs": true,
"**/*.unityproj": true,
"**/*.dll": true,
"**/*.exe": true,
"**/*.pdf": true,
"**/*.mid": true,
"**/*.midi": true,
"**/*.wav": true,
"**/*.gif": true,
"**/*.ico": true,
"**/*.jpg": true,
"**/*.jpeg": true,
"**/*.png": true,
"**/*.psd": true,
"**/*.tga": true,
"**/*.tif": true,
"**/*.tiff": true,
"**/*.3ds": true,
"**/*.3DS": true,
"**/*.fbx": true,
"**/*.FBX": true,
"**/*.lxo": true,
"**/*.LXO": true,
"**/*.ma": true,
"**/*.MA": true,
"**/*.obj": true,
"**/*.OBJ": true,
"**/*.asset": true,
"**/*.cubemap": true,
"**/*.flare": true,
"**/*.mat": true,
"**/*.meta": true,
"**/*.prefab": true,
"**/*.unity": true,
"build/": true,
"Build/": true,
"Library/": true,
"library/": true,
"obj/": true,
"Obj/": true,
"Logs/": true,
"logs/": true,
"ProjectSettings/": true,
"UserSettings/": true,
"temp/": true,
"Temp/": true
},
"files.associations": {
"*.asset": "yaml",
"*.meta": "yaml",
"*.prefab": "yaml",
"*.unity": "yaml",
},
"explorer.fileNesting.enabled": true,
"explorer.fileNesting.patterns": {
"*.sln": "*.csproj",
},
"dotnet.defaultSolution": "Digital-Logic-Sim.sln"
}
Binary file added Assets/.DS_Store
Binary file not shown.
4 changes: 2 additions & 2 deletions Assets/Build/DLS.unity
Original file line number Diff line number Diff line change
Expand Up @@ -242,9 +242,9 @@ MonoBehaviour:
m_EditorClassIdentifier:
openSaveDirectory: 0
openInMainMenu: 0
testProjectName: MainTest
testProjectName: abc
openA: 1
chipToOpenA: BuzzTest
chipToOpenA: abc
chipToOpenB: TEST MergeSplit
testVecA: {x: 100, y: 0.5333334}
testVecB: {x: 1.71, y: 0.0025}
Expand Down
Binary file added Assets/Scripts/.DS_Store
Binary file not shown.
31 changes: 16 additions & 15 deletions Assets/Scripts/DLS.asmdef
Original file line number Diff line number Diff line change
@@ -1,17 +1,18 @@
{
"name": "DLS",
"rootNamespace": "",
"references": [
"GUID:d4f8eab5cdd4a544c9923829818c11c0",
"GUID:2b65bcfb6aad3f1459e94b356ff58293"
],
"includePlatforms": [],
"excludePlatforms": [],
"allowUnsafeCode": false,
"overrideReferences": false,
"precompiledReferences": [],
"autoReferenced": true,
"defineConstraints": [],
"versionDefines": [],
"noEngineReferences": false
"name": "DLS",
"rootNamespace": "",
"references": [
"Assembly-Seb",
"DLS.Description",
"DLSModdingAPI"
],
"includePlatforms": [],
"excludePlatforms": [],
"allowUnsafeCode": false,
"overrideReferences": false,
"precompiledReferences": [],
"autoReferenced": true,
"defineConstraints": [],
"versionDefines": [],
"noEngineReferences": false
}
Binary file added Assets/Scripts/Description/.DS_Store
Binary file not shown.
38 changes: 34 additions & 4 deletions Assets/Scripts/Description/Helpers/ChipTypeHelper.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
using System;
using System.Collections.Generic;
using UnityEngine;

namespace DLS.Description
{
Expand All @@ -16,21 +17,44 @@ public static class ChipTypeHelper
{ ChipType.TriStateBuffer, "3-STATE BUFFER" },
// ---- Memory ----
{ ChipType.dev_Ram_8Bit, "dev.RAM-8" },
{ ChipType.Rom_256x2x8, $"ROM 256{mulSymbol}x2x8" },
{ ChipType.Rom_256x16, $"ROM 256{mulSymbol}16" },
{ ChipType.Rom_256x32, $"ROM 256{mulSymbol}32" },
// ---- Split / Merge ----
{ ChipType.Split_4To1Bit, "4-1BIT" },
{ ChipType.Split_8To1Bit, "8-1BIT" },
{ ChipType.Split_8To4Bit, "8-4BIT" },
{ ChipType.Split_16To1Bit, "16-1BIT" },
{ ChipType.Split_16To4Bit, "16-4BIT" },
{ ChipType.Split_16To8Bit, "16-8BIT" },
{ ChipType.Merge_4To8Bit, "4-8BIT" },
{ ChipType.Merge_1To8Bit, "1-8BIT" },
{ ChipType.Merge_1To4Bit, "1-4BIT" },
{ ChipType.Merge_1To16Bit, "1-16BIT" },
{ ChipType.Merge_4To16Bit, "4-16BIT" },
{ ChipType.Merge_8To16Bit, "8-16BIT" },

// ---- Displays -----
{ ChipType.DisplayRGB, "RGB DISPLAY" },
{ ChipType.DisplayDot, "DOT DISPLAY" },
{ ChipType.SevenSegmentDisplay, "7-SEGMENT" },
{ ChipType.DisplayLED, "LED" },
{ ChipType.DisplayRGBLED, "RGBLED" },
{ ChipType.DisplayUTF, "Text Display"},

// ---- Ports ----
{ChipType.PortIn_1Bit, "PORT-IN-1"},
{ChipType.PortIn_4Bit, "PORT-IN-4"},
{ChipType.PortIn_8Bit, "PORT-IN-8"},
{ChipType.PortIn_16Bit, "PORT-IN-16"},
{ChipType.PortOut_1Bit, "PORT-OUT-1"},
{ChipType.PortOut_4Bit, "PORT-OUT-4"},
{ChipType.PortOut_8Bit, "PORT-OUT-8"},
{ChipType.PortOut_16Bit, "PORT-OUT-16"},

{ ChipType.Complex_Internet_Interface, "Complex Internet Interface" },

// ---- Buzzer ----
{ ChipType.Buzzer, "BUZZER" },

// ---- Not really chips (but convenient to treat them as such anyway) ----
Expand All @@ -43,24 +67,25 @@ public static class ChipTypeHelper
{ ChipType.Out_4Bit, "OUT-4" },
{ ChipType.Out_8Bit, "OUT-8" },
{ ChipType.Key, "KEY" },

// ---- Buses ----
{ ChipType.Bus_1Bit, "BUS-1" },
{ ChipType.Bus_4Bit, "BUS-4" },
{ ChipType.Bus_8Bit, "BUS-8" },
{ ChipType.BusTerminus_1Bit, "BUS-TERMINUS-1" },
{ ChipType.BusTerminus_4Bit, "BUS-TERMINUS-4" },
{ ChipType.BusTerminus_8Bit, "BUS-TERMINUS-8" }
{ ChipType.BusTerminus_8Bit, "BUS-TERMINUS-8" },
};

public static string GetName(ChipType type) => Names[type];

public static bool IsBusType(ChipType type) => IsBusOriginType(type) || IsBusTerminusType(type);

public static bool IsBusOriginType(ChipType type) => type is ChipType.Bus_1Bit or ChipType.Bus_4Bit or ChipType.Bus_8Bit;
public static bool IsBusOriginType(ChipType type) => type is ChipType.Bus_1Bit or ChipType.Bus_4Bit or ChipType.Bus_8Bit or ChipType.Bus_16Bit;

public static bool IsBusTerminusType(ChipType type) => type is ChipType.BusTerminus_1Bit or ChipType.BusTerminus_4Bit or ChipType.BusTerminus_8Bit;
public static bool IsBusTerminusType(ChipType type) => type is ChipType.BusTerminus_1Bit or ChipType.BusTerminus_4Bit or ChipType.BusTerminus_8Bit or ChipType.BusTerminus_16Bit;

public static bool IsRomType(ChipType type) => type == ChipType.Rom_256x16;
public static bool IsRomType(ChipType type) => type is ChipType.Rom_256x2x8 or ChipType.Rom_256x16 or ChipType.Rom_256x32;

public static ChipType GetCorrespondingBusTerminusType(ChipType type)
{
Expand Down Expand Up @@ -108,5 +133,10 @@ public static (bool isInput, bool isOutput, PinBitCount numBits) IsInputOrOutput
_ => (false, false, PinBitCount.Bit1)
};
}
public static bool IsPortChip(ChipType type)
{
return type is ChipType.PortIn_1Bit or ChipType.PortIn_4Bit or ChipType.PortIn_8Bit or ChipType.PortIn_16Bit
|| type is ChipType.PortOut_1Bit or ChipType.PortOut_4Bit or ChipType.PortOut_8Bit or ChipType.PortOut_16Bit;
}
}
}
Binary file added Assets/Scripts/Description/Types/.DS_Store
Binary file not shown.
2 changes: 2 additions & 0 deletions Assets/Scripts/Description/Types/ChipDescription.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
using System;
using System.Collections.Generic;
using UnityEngine;

namespace DLS.Description
Expand All @@ -11,6 +12,7 @@ public class ChipDescription

// ---- Data ----
public string DLSVersion;
public List<string> DependsOnModIDs = new();
public string Name;
public NameDisplayLocation NameLocation;
public ChipType ChipType;
Expand Down
1 change: 1 addition & 0 deletions Assets/Scripts/Description/Types/ProjectDescription.cs
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,7 @@ public class ChipCollection
[JsonIgnore] string displayName_open;
public bool IsToggledOpen;
public string Name;
public List<string> DependsOnModIDs = new();

public ChipCollection(string name, params string[] chips)
{
Expand Down
26 changes: 26 additions & 0 deletions Assets/Scripts/Description/Types/SubTypes/ChipTypes.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ namespace DLS.Description
public enum ChipType
{
Custom,
Modded,

// ---- Basic Chips ----
Nand,
Expand All @@ -12,21 +13,31 @@ public enum ChipType

// ---- Memory ----
dev_Ram_8Bit,
Rom_256x2x8,
Rom_256x16,
Rom_256x32,

// ---- Displays ----
SevenSegmentDisplay,
DisplayRGB,
DisplayDot,
DisplayLED,
DisplayRGBLED,
DisplayUTF,

// ---- Merge / Split ----
Merge_1To4Bit,
Merge_1To8Bit,
Merge_4To8Bit,
Merge_1To16Bit,
Merge_4To16Bit,
Merge_8To16Bit,
Split_4To1Bit,
Split_8To4Bit,
Split_8To1Bit,
Split_16To1Bit,
Split_16To4Bit,
Split_16To8Bit,

// ---- In / Out Pins ----
In_1Bit,
Expand All @@ -45,6 +56,21 @@ public enum ChipType
BusTerminus_4Bit,
Bus_8Bit,
BusTerminus_8Bit,
Bus_16Bit,
BusTerminus_16Bit,

// ---- PORT Chips ----

PortIn_1Bit,
PortIn_4Bit,
PortIn_8Bit,
PortIn_16Bit,
PortOut_1Bit,
PortOut_4Bit,
PortOut_8Bit,
PortOut_16Bit,

Complex_Internet_Interface,

// ---- Audio ----
Buzzer
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
using System.Collections.Generic;
using UnityEngine;

namespace DLS.Description
Expand All @@ -9,12 +10,14 @@ public struct DisplayDescription
public int SubChipID;
public Vector2 Position;
public float Scale;
public List<string> DependsOnModIDs;

public DisplayDescription(int subChipID, Vector2 position, float scale)
{
SubChipID = subChipID;
Position = position;
Scale = scale;
DependsOnModIDs = new();
}
}
}
13 changes: 12 additions & 1 deletion Assets/Scripts/Description/Types/SubTypes/PinDescription.cs
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,24 @@ public PinDescription(string name, int id, Vector2 position, PinBitCount bitCoun
Colour = colour;
ValueDisplayMode = valueDisplayMode;
}

public PinDescription(string name, int id)
{
Name = name;
ID = id;
Position = Vector2.zero;
BitCount = PinBitCount.Bit1;
Colour = PinColour.Red;
ValueDisplayMode = PinValueDisplayMode.Off;
}
}

public enum PinBitCount
{
Bit1 = 1,
Bit4 = 4,
Bit8 = 8
Bit8 = 8,
Bit16 = 16
}

public enum PinColour
Expand Down
8 changes: 8 additions & 0 deletions Assets/Scripts/External.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading