Skip to content

Commit 0a0e183

Browse files
committed
Rename project to ModularSynthPanelGenerator
1 parent a04de56 commit 0a0e183

File tree

19 files changed

+94
-78
lines changed

19 files changed

+94
-78
lines changed

.github/build.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,4 +7,4 @@ set -o nounset
77

88
VERSION=$(jq --raw-output '.release.tag_name' "$GITHUB_EVENT_PATH")
99

10-
sed -i "s/(in-development)/$VERSION/" EurorackPanelGenerator.manifest
10+
sed -i "s/(in-development)/$VERSION/" ModularSynthPanelGenerator.manifest

.github/workflows/release.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,12 @@ jobs:
1515
- uses: vimtor/[email protected]
1616
with:
1717
files:
18-
EurorackPanelGenerator.manifest EurorackPanelGenerator.py config.py LICENSE.md commands/ lib/
18+
ModularSynthPanelGenerator.manifest ModularSynthPanelGenerator.py config.py LICENSE.md commands/ lib/
1919
resources/project-logo.png
20-
dest: build/EurorackPanelGenerator-${{ github.ref_name }}.zip
20+
dest: build/ModularSynthPanelGenerator-${{ github.ref_name }}.zip
2121
recursive: false
2222
- uses: skx/github-action-publish-binaries@master
2323
env:
2424
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
2525
with:
26-
args: build/EurorackPanelGenerator-${{ github.ref_name }}.zip
26+
args: build/ModularSynthPanelGenerator-${{ github.ref_name }}.zip

EurorackPanelGenerator.manifest renamed to ModularSynthPanelGenerator.manifest

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"type": "addin",
44
"author": "\"Cowboy\" Ben Alman",
55
"description": {
6-
"": "A Fusion Add-in for generating Eurorack panels"
6+
"": "A Fusion Add-in for generating modular synth panels"
77
},
88
"version": "(in-development)",
99
"runOnStartup": true,
File renamed without changes.

README.md

Lines changed: 46 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -1,41 +1,49 @@
1-
# Fusion Eurorack Panel Generator
1+
# Modular Synth Panel Generator
22

3-
[![Latest release](https://img.shields.io/github/v/release/cowboy/fusion-eurorack-panel-generator.svg?style=flat)][latest-release]
3+
[![Latest release](https://img.shields.io/github/v/release/cowboy/ModularSynthPanelGenerator.svg?style=flat)][latest-release]
44
[![CC BY-NC-SA 4.0][cc-by-nc-sa-shield]][cc-by-nc-sa]
55
[![Code of Conduct](https://img.shields.io/badge/code%20of-conduct-ff69b4.svg?style=flat)][coc]
66

77
## Description
88

99
<img align="right" src="resources/project-logo-readme.png">
1010

11-
TL;DR: This is a Eurorack panel generator [add-in][addins] for [Autodesk Fusion][fusion]
11+
TL;DR: This is a modular synth panel generator [add-in][addins] for [Autodesk Fusion][fusion]
1212

13-
If you're like me and you like making DIY Eurorack modules but absolutely hate milling aluminum panels because little
14-
bits of metal go flying everywhere and it's impossible to get all the holes to line up just right and it's just so damn
13+
If you're like me and you like making DIY synth modules but absolutely hate milling aluminum panels because little bits
14+
of metal go flying everywhere and it's impossible to get all the holes to line up just right and it's just so damn
1515
tedious, maybe this thing will help you out.
1616

17-
I've been 3D printing DIY Eurorack module panels for a while now, but until I made this add-in, I'd been copying and
18-
pasting some manual template components over and over again, which resulted in a very large and very slow Fusion project
19-
file.
17+
I've been 3D printing DIY Eurorack module panels for a while now, but until I made this add-in, I'd been manually
18+
copying and pasting "template" components over and over again, which resulted in a number of very large and very slow
19+
Fusion project files.
2020

2121
## Features
2222

2323
With this add-in, you can...
2424

25-
- generate [3U][intellijel-spec], [1U (Intellijel)][intellijel-spec], and [1U Tile (Pulp Logic)][pulplogic-spec]
26-
compatible Eurorack panels, suitable for 3D printing (or CNC?)
25+
- generate modular synth panels (currently Eurorack and 1U formats are supported), suitable for 3D printing (or CNC?)
2726
- choose any width from 2 to 9000 HP
2827
- set a custom panel thickness
29-
- choose from two different reinforcement types, which each thicken the center area of the panel, while leaving the
30-
panel thickness in the mounting screw area unchanged:
28+
- choose multiple reinforcement types, each of which thicken the center area of the panel, while leaving the panel
29+
thickness in the mounting screw area unchanged:
3130
- `Shell`: This creates a hollow shell, adding strength while leaving space inside for jacks and switches. Generally
3231
useful for 4 HP and larger panels.
3332
- `Solid`: This adds strength to larger blanks, or very narrow modules where the shell approach wouldn't leave enough
3433
space for components.
3534
- save custom default values for easy recall
36-
- easily edit generated sketches to change the HP (or other) values or features to change extrusions, after-the-fact
35+
- easily edit generated sketches and features to change dimensions, after-the-fact
3736

38-
Additional Notes:
37+
### Currently supported modular synth panel formats
38+
39+
| Format name | Reference Specification |
40+
| ----------------------------- | ----------------------------------------------------------- |
41+
| 3U Eurorack | [Doepfer - A-100 Construction Details][doepfer-spec] |
42+
| 1U (Intellijel) | [Intellijel - 1U Technical Specifications][intellijel-spec] |
43+
| 1U Tile (Pulp Logic) | [Pulp Logic - About 1U Tiles][pulplogic-spec] |
44+
| &lt;Your favorite format?&gt; | [Contributions welcome!](#contributing) |
45+
46+
### Additional Notes
3947

4048
- I print with PETG using a 0.4mm nozzle and 0.2mm layer height on a Bambu X1C, without issues.
4149
- When using reinforcements, it'll probably be easiest if you print with the panel face down. 😛
@@ -79,8 +87,8 @@ You have a few options:
7987

8088
**Option 1:** You just want to use the add-in
8189

82-
1. Download the `EurorackPanelGenerator-vX.Y.Z.zip` file from the [latest release][latest-release] page. Note that the
83-
`X.Y.Z` part will change based on the release version.
90+
1. Download the `ModularSynthPanelGenerator-vX.Y.Z.zip` file from the [latest release][latest-release] page. Note that
91+
the `X.Y.Z` part will change based on the release version.
8492
2. Unzip it. You can unzip anywhere, but the [Installing, Linking, and Removing Scripts and Add-Ins][addins-installing]
8593
documentation page has suggestions.
8694

@@ -95,12 +103,12 @@ You have a few options:
95103
1. In Fusion open the `Scripts and Add-Ins` dialog by pressing `Shift + S` or going to
96104
`Utilities -> Add-Ins -> Scripts and Add-Ins` in the top menu of the Design workspace.
97105
2. Click the `+` (plus) icon at the top of the `Scripts and Add-Ins` dialog and select `Script or add-in from device`.
98-
3. Choose the folder created after unzipping / cloning. It will be named something like `EurorackPanelGenerator` or
99-
`EurorackPanelGenerator-vX.Y.Z` and will contain `lib`, `commands` and `resources` folders, as well as files like
100-
`EurorackPanelGenerator.manifest` and `EurorackPanelGenerator.py` (you may not be able to see some of the folder
101-
contents in the `+` file dialog).
102-
4. Verify that you see the `EurorackPanelGenerator` add-in in the `Scripts and Add-Ins` dialog list.
103-
5. Enable the `Run` option for the `EurorackPanelGenerator` add-in.
106+
3. Choose the folder created after unzipping / cloning. It will be named something like `ModularSynthPanelGenerator` or
107+
`ModularSynthPanelGenerator-vX.Y.Z` and will contain `lib`, `commands` and `resources` folders, as well as files like
108+
`ModularSynthPanelGenerator.manifest` and `ModularSynthPanelGenerator.py` (you may not be able to see some of the
109+
folder contents in the `+` file dialog).
110+
4. Verify that you see the `ModularSynthPanelGenerator` add-in in the `Scripts and Add-Ins` dialog list.
111+
5. Enable the `Run` option for the `ModularSynthPanelGenerator` add-in.
104112

105113
When done correctly, the Design workspace `Solid -> Create` menu should have a `Eurorack Panel Generator` option.
106114

@@ -126,8 +134,8 @@ Useful links:
126134
Development environment notes:
127135

128136
- Launch the editor ([Visual Studio Code][vscode]) from inside Fusion by opening the `Scripts and Add-Ins` dialog
129-
(`Shift + S`), right-clicking on the `EurorackPanelGenerator` and clicking `Edit in code editor`. This allows you to
130-
attach the vscode debugger to the running process as well as reload after you've made changes.
137+
(`Shift + S`), right-clicking on the `ModularSynthPanelGenerator` and clicking `Edit in code editor`. This allows you
138+
to attach the vscode debugger to the running process as well as reload after you've made changes.
131139
- I've tried to leave the boilerplate files generated by Fusion's `Create script or add-in` relatively untouched, so
132140
that the code can be as modular as possible. Unused boilerplate has been removed where possible.
133141
- There are `# type: ignore` comments throughout the code to get
@@ -155,25 +163,20 @@ Development environment notes:
155163

156164
Files of interest:
157165

158-
| File | Description |
159-
| ----------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------- |
160-
| [commands/commandDialog](/commands/commandDialog) | Boilerplate command code generated by Fusion. You likely won't be touching these files. |
161-
| [lib/eurorackPanelUtils/eurorack_panel_command.py](/lib/eurorackPanelUtils/eurorack_panel_command.py) | Most of the command code that would have gone into the boilerplate command `entry` file. This is where the main dialog is initialized and updated. |
162-
| [lib/eurorackPanelUtils/eurorack_panel_options.py](/lib/eurorackPanelUtils/eurorack_panel_options.py) | `EurorackPanelOptions` class with add-in options and some constants, including convenience getters/setters for the ui dialog imputs. |
163-
| [lib/eurorackPanelUtils/eurorack_panel.py](/lib/eurorackPanelUtils/eurorack_panel.py) | Code that actually generates the panel, including the sketch and extrusions. |
164-
| [lib/generalUtils/debug_utils.py](/lib/generalUtils/debug_utils.py) | Debugging utilities |
165-
| [lib/generalUtils/extrude_utils.py](/lib/generalUtils/extrude_utils.py) | Extrusion utilities |
166-
| [lib/generalUtils/persist_utils.py](/lib/generalUtils/persist_utils.py) | `Persistable` class for persisting defaults to disk |
167-
| [lib/generalUtils/sketch_utils.py](/lib/generalUtils/sketch_utils.py) | Sketch utilities |
168-
| [lib/generalUtils/value_utils.py](/lib/generalUtils/value_utils.py) | Value normalization utilities |
166+
| File | Description |
167+
| ----------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------- |
168+
| [commands/commandDialog](/commands/commandDialog) | Boilerplate command code generated by Fusion. You likely won't be touching these files. |
169+
| [lib/panelUtils/panel_command.py](/lib/panelUtils/panel_command.py) | Most of the command code that would have gone into the boilerplate command `entry.py` file. This is where the main dialog is initialized and updated. |
170+
| [lib/panelUtils/panel_options.py](/lib/panelUtils/panel_options.py) | `PanelOptions` class with panel options and constants, including convenience getters/setters for ui dialog imputs. |
171+
| [lib/panelUtils/panel_generate.py](/lib/panelUtils/panel_generate.py) | Code that actually generates the panel, including the sketch and extrusions. |
172+
| [lib/generalUtils/debug_utils.py](/lib/generalUtils/debug_utils.py) | Debugging utilities |
173+
| [lib/generalUtils/extrude_utils.py](/lib/generalUtils/extrude_utils.py) | Extrusion utilities |
174+
| [lib/generalUtils/persist_utils.py](/lib/generalUtils/persist_utils.py) | `Persistable` class for persisting defaults to disk |
175+
| [lib/generalUtils/sketch_utils.py](/lib/generalUtils/sketch_utils.py) | Sketch utilities |
176+
| [lib/generalUtils/value_utils.py](/lib/generalUtils/value_utils.py) | Value normalization utilities |
169177

170178
_(More to come, but in the meantime, if you give this a try and have any issues, please let me know)_
171179

172-
## References
173-
174-
- [Intellijel - 1U Technical Specifications][intellijel-spec]
175-
- [Pulp Logic - About 1U Tiles][pulplogic-spec]
176-
177180
## Support the project
178181

179182
This add-in is free. However, if you want to support the project you can do so by
@@ -198,11 +201,12 @@ License][cc-by-nc-sa].
198201
[addins]: https://help.autodesk.com/view/fusion360/ENU/?guid=GUID-9701BBA7-EC0E-4016-A9C8-964AA4838954
199202
[addins-installing]:
200203
https://help.autodesk.com/view/fusion360/ENU/?guid=GUID-9701BBA7-EC0E-4016-A9C8-964AA4838954#Installing
201-
[latest-release]: https://github.com/cowboy/fusion-eurorack-panel-generator/releases/latest
204+
[latest-release]: https://github.com/cowboy/ModularSynthPanelGenerator/releases/latest
202205
[cc-by-nc-sa]: http://creativecommons.org/licenses/by-nc-sa/4.0/
203206
[cc-by-nc-sa-image]: https://licensebuttons.net/l/by-nc-sa/4.0/88x31.png
204207
[cc-by-nc-sa-shield]: https://img.shields.io/badge/License-CC%20BY--NC--SA%204.0-lightgrey.svg
205-
[coc]: https://github.com/cowboy/fusion-eurorack-panel-generator/blob/main/CODE_OF_CONDUCT.md
208+
[coc]: https://github.com/cowboy/ModularSynthPanelGenerator/blob/main/CODE_OF_CONDUCT.md
206209
[vscode]: https://code.visualstudio.com/
210+
[doepfer-spec]: https://www.doepfer.de/a100_man/a100m_e.htm
207211
[pulplogic-spec]: https://pulplogic.com/1u_tiles/
208212
[intellijel-spec]: https://intellijel.com/support/1u-technical-specifications/

commands/commandDialog/entry.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
import os
33
from ...lib import fusionAddInUtils as futil
44
from ... import config
5-
from ...lib.eurorackPanelUtils.eurorack_panel_command import command_created, CMD_NAME, CMD_Description
5+
from ...lib.panelUtils.panel_command import command_created, CMD_NAME, CMD_Description
66
app = adsk.core.Application.get()
77
ui = app.userInterface
88

1.34 KB
Loading
3.38 KB
Loading

lib/eurorackPanelUtils/__init__.py

Lines changed: 0 additions & 3 deletions
This file was deleted.

lib/generalUtils/persist_utils.py

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
class Persistable():
99
def __init__(self, persistFile: str, defaults: dict):
1010
self.persistFile = join(persistDir, persistFile)
11-
self.defaults = defaults
11+
self._defaults = defaults
1212
self.restoreDefaults()
1313

1414
def saveDefaults(self):
@@ -17,7 +17,7 @@ def saveDefaults(self):
1717
mkdir(persistDir)
1818
with open(self.persistFile, 'w') as persistFile:
1919
data = {}
20-
for key in self.defaults.keys():
20+
for key in self._defaults.keys():
2121
data[key] = getattr(self, key)
2222
json.dump(data, persistFile, indent=2)
2323
futil.log(f'saved defaults file {self.persistFile}')
@@ -41,10 +41,17 @@ def __loadDefaults(self):
4141
return False
4242

4343
def restoreDefaults(self):
44-
data = self.defaults | (self.__loadDefaults() or {})
44+
data = self._defaults | (self.__loadDefaults() or {})
4545
for key, value in data.items():
4646
setattr(self, key, value)
4747

48+
# Ensure invalid values loaded from persistFile don't break things
49+
def ensureDefaultKeyIsValid(self, keyName, obj):
50+
key = getattr(self, keyName)
51+
if not key in obj:
52+
futil.log(f'Warning: {keyName} "{key}" invalid, restoring default value "{self._defaults[keyName]}"')
53+
setattr(self, keyName, self._defaults[keyName])
54+
4855
def eraseDefaults(self):
4956
try:
5057
if exists(self.persistFile):

0 commit comments

Comments
 (0)