Jonatan Gezelius преди 2 години
родител
ревизия
6636e2482a
променени са 6 файла, в които са добавени 526 реда и са изтрити 334 реда
  1. 7 4
      .vscode/c_cpp_properties.json
  2. 4 0
      .vscode/settings.json
  3. 67 0
      res/KnobPenis.svg
  4. 55 0
      res/KnobPenis2.svg
  5. 237 237
      res/SSI2164-Mixer1.svg
  6. 156 93
      src/SSI2164-Mixer1.cpp

+ 7 - 4
src/.vscode/c_cpp_properties.json → .vscode/c_cpp_properties.json

@@ -4,18 +4,21 @@
             "name": "Win32",
             "includePath": [
                 "${workspaceFolder}/**",
-                "C:\\Users\\JONGE\\Documents\\Synth\\VCVPlugins\\Rack-SDK\\include"
+                "${vcpkgRoot}/x64-windows/include",
+                "${vcpkgRoot}/x86-windows/include",
+                "../../Rack-SDK/include",
+                "../../Rack-SDK/dep/include"
             ],
             "defines": [
                 "_DEBUG",
                 "UNICODE",
                 "_UNICODE"
             ],
-            "windowsSdkVersion": "10.0.19041.0",
-            "compilerPath": "cl.exe",
+            "compilerPath": "C:/msys64/mingw64/bin/gcc.exe",
             "cStandard": "c17",
             "cppStandard": "c++17",
-            "intelliSenseMode": "windows-msvc-x64"
+            "intelliSenseMode": "windows-gcc-x64",
+            "configurationProvider": "ms-vscode.makefile-tools"
         }
     ],
     "version": 4

+ 4 - 0
.vscode/settings.json

@@ -0,0 +1,4 @@
+{
+    "editor.formatOnSave": false,
+    "editor.formatOnPaste": false
+}

+ 67 - 0
res/KnobPenis.svg

@@ -0,0 +1,67 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+   width="19"
+   height="19"
+   viewBox="0 0 5.0270833 5.0270833"
+   version="1.1"
+   id="svg5"
+   inkscape:version="1.2.2 (732a01da63, 2022-12-09)"
+   sodipodi:docname="KnobPenis.svg"
+   xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+   xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+   xmlns="http://www.w3.org/2000/svg"
+   xmlns:svg="http://www.w3.org/2000/svg">
+  <sodipodi:namedview
+     id="namedview7"
+     pagecolor="#ffffff"
+     bordercolor="#000000"
+     borderopacity="0.25"
+     inkscape:showpageshadow="2"
+     inkscape:pageopacity="0.0"
+     inkscape:pagecheckerboard="0"
+     inkscape:deskcolor="#d1d1d1"
+     inkscape:document-units="mm"
+     showgrid="true"
+     inkscape:zoom="58.553984"
+     inkscape:cx="10.725146"
+     inkscape:cy="7.0191637"
+     inkscape:window-width="3840"
+     inkscape:window-height="2066"
+     inkscape:window-x="-11"
+     inkscape:window-y="-11"
+     inkscape:window-maximized="1"
+     inkscape:current-layer="layer1">
+    <inkscape:grid
+       type="xygrid"
+       id="grid695" />
+  </sodipodi:namedview>
+  <defs
+     id="defs2" />
+  <g
+     inkscape:label="Layer 1"
+     inkscape:groupmode="layer"
+     id="layer1"
+     transform="translate(-27.256329,-56.898489)">
+    <circle
+       style="fill:#784421;stroke-width:0.264583"
+       id="path416"
+       cy="60.730282"
+       cx="28.670656"
+       r="0.96246654" />
+    <circle
+       style="fill:#784421;stroke-width:0.264583"
+       id="path526"
+       cx="30.604628"
+       cy="60.639908"
+       r="0.95342928" />
+    <ellipse
+       style="fill:#d38d5f;stroke-width:0.264583"
+       id="path528"
+       cx="29.619568"
+       cy="58.981575"
+       rx="0.60097677"
+       ry="1.9023399" />
+  </g>
+</svg>

+ 55 - 0
res/KnobPenis2.svg

@@ -0,0 +1,55 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+   width="24"
+   height="24"
+   viewBox="0 0 6.3499999 6.35"
+   version="1.1"
+   id="svg708"
+   sodipodi:docname="KnobPenis2.svg"
+   inkscape:version="1.2.2 (732a01da63, 2022-12-09)"
+   xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+   xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+   xmlns="http://www.w3.org/2000/svg"
+   xmlns:svg="http://www.w3.org/2000/svg">
+  <sodipodi:namedview
+     id="namedview710"
+     pagecolor="#ffffff"
+     bordercolor="#000000"
+     borderopacity="0.25"
+     inkscape:showpageshadow="2"
+     inkscape:pageopacity="0.0"
+     inkscape:pagecheckerboard="0"
+     inkscape:deskcolor="#d1d1d1"
+     inkscape:document-units="px"
+     showgrid="true"
+     inkscape:zoom="29.276992"
+     inkscape:cx="12.842849"
+     inkscape:cy="12.313423"
+     inkscape:window-width="2011"
+     inkscape:window-height="1065"
+     inkscape:window-x="4041"
+     inkscape:window-y="99"
+     inkscape:window-maximized="0"
+     inkscape:current-layer="layer1">
+    <inkscape:grid
+       type="xygrid"
+       id="grid712"
+       originx="3.175"
+       originy="3.175" />
+  </sodipodi:namedview>
+  <defs
+     id="defs705" />
+  <g
+     inkscape:label="Layer 1"
+     inkscape:groupmode="layer"
+     id="layer1">
+    <circle
+       style="fill:none;stroke:#000000;stroke-width:0.258466;stroke-dasharray:none;stroke-opacity:1"
+       id="path921"
+       cx="3.1749997"
+       cy="3.1749997"
+       r="3.0457668" />
+  </g>
+</svg>

+ 237 - 237
res/SSI2164-Mixer1.svg

@@ -1,237 +1,237 @@
-<?xml version="1.0" encoding="UTF-8" standalone="no"?>
-<!-- Created with Inkscape (http://www.inkscape.org/) -->
-
-<svg
-   width="185.7636mm"
-   height="128.5mm"
-   viewBox="0 0 185.76361 128.50002"
-   version="1.1"
-   id="svg8"
-   inkscape:version="1.1 (c68e22c387, 2021-05-23)"
-   sodipodi:docname="SSI2164-Mixer1.svg"
-   xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
-   xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
-   xmlns="http://www.w3.org/2000/svg"
-   xmlns:svg="http://www.w3.org/2000/svg"
-   xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
-   xmlns:cc="http://creativecommons.org/ns#"
-   xmlns:dc="http://purl.org/dc/elements/1.1/">
-  <defs
-     id="defs2" />
-  <sodipodi:namedview
-     id="base"
-     pagecolor="#ffffff"
-     bordercolor="#666666"
-     borderopacity="1.0"
-     inkscape:pageopacity="0.0"
-     inkscape:pageshadow="2"
-     inkscape:zoom="0.49497475"
-     inkscape:cx="639.42656"
-     inkscape:cy="220.21326"
-     inkscape:document-units="mm"
-     inkscape:current-layer="layer1"
-     showgrid="false"
-     units="mm"
-     inkscape:snap-bbox="true"
-     inkscape:snap-page="true"
-     inkscape:bbox-nodes="false"
-     inkscape:snap-bbox-edge-midpoints="false"
-     inkscape:window-width="1600"
-     inkscape:window-height="900"
-     inkscape:window-x="4292"
-     inkscape:window-y="9"
-     inkscape:window-maximized="0"
-     inkscape:snap-bbox-midpoints="true"
-     inkscape:snap-nodes="false"
-     inkscape:pagecheckerboard="0" />
-  <metadata
-     id="metadata5">
-    <rdf:RDF>
-      <cc:Work
-         rdf:about="">
-        <dc:format>image/svg+xml</dc:format>
-        <dc:type
-           rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
-      </cc:Work>
-    </rdf:RDF>
-  </metadata>
-  <g
-     inkscape:label="Layer 1"
-     inkscape:groupmode="layer"
-     id="layer1"
-     transform="translate(0,-168.49997)"
-     style="display:inline">
-    <rect
-       style="display:inline;opacity:1;vector-effect:none;fill:#e6e6e6;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1.60309;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal"
-       id="rect420"
-       width="185.7636"
-       height="128.5"
-       x="5.9211732e-17"
-       y="168.49997" />
-    <g
-       aria-label="2164 Mixer"
-       id="text16740"
-       style="font-size:10.5833px;line-height:1.25;stroke-width:0.264583">
-      <path
-         d="m 112.68046,215.72999 h 3.64318 v 0.8785 h -4.89891 v -0.8785 q 0.59427,-0.61494 1.61746,-1.64847 1.02836,-1.03869 1.29191,-1.33841 0.50126,-0.56328 0.69763,-0.95085 0.20154,-0.39274 0.20154,-0.76997 0,-0.61495 -0.43408,-1.00252 -0.42892,-0.38758 -1.12138,-0.38758 -0.49092,0 -1.03869,0.17054 -0.5426,0.17053 -1.16272,0.51676 v -1.0542 q 0.63045,-0.25321 1.17822,-0.3824 0.54777,-0.12919 1.00252,-0.12919 1.19889,0 1.91202,0.59944 0.71314,0.59945 0.71314,1.60197 0,0.47542 -0.18087,0.90433 -0.1757,0.42375 -0.64596,1.00252 -0.12919,0.14986 -0.82165,0.86816 -0.69246,0.71313 -1.95336,1.99987 z"
-         id="path18790" />
-      <path
-         d="m 118.69558,215.72999 h 1.70531 v -5.88592 l -1.85517,0.37207 v -0.95085 l 1.84484,-0.37207 h 1.04386 v 6.83677 h 1.70532 v 0.8785 h -4.44416 z"
-         id="path18792" />
-      <path
-         d="m 127.60973,212.33486 q -0.70279,0 -1.1162,0.48059 -0.40825,0.48059 -0.40825,1.31775 0,0.83198 0.40825,1.31774 0.41341,0.48059 1.1162,0.48059 0.7028,0 1.11104,-0.48059 0.41341,-0.48576 0.41341,-1.31774 0,-0.83716 -0.41341,-1.31775 -0.40824,-0.48059 -1.11104,-0.48059 z m 2.07222,-3.27111 v 0.95085 q -0.39274,-0.18604 -0.79581,-0.28422 -0.39791,-0.0982 -0.79065,-0.0982 -1.03353,0 -1.58129,0.69763 -0.54261,0.69763 -0.62012,2.1084 0.30489,-0.44959 0.76481,-0.6873 0.45992,-0.24288 1.01285,-0.24288 1.16272,0 1.83451,0.70797 0.67696,0.70279 0.67696,1.91719 0,1.18855 -0.7028,1.90685 -0.70279,0.7183 -1.87068,0.7183 -1.33841,0 -2.04638,-1.02319 -0.70796,-1.02836 -0.70796,-2.97655 0,-1.82934 0.86816,-2.91454 0.86816,-1.09037 2.3306,-1.09037 0.39274,0 0.79065,0.0775 0.40307,0.0775 0.83715,0.23254 z"
-         id="path18794" />
-      <path
-         d="m 134.84958,209.80273 -2.63549,4.11859 h 2.63549 z m -0.27389,-0.90951 h 1.31258 v 5.0281 h 1.10071 v 0.86817 h -1.10071 v 1.819 h -1.03869 v -1.819 h -3.48298 v -1.00769 z"
-         id="path18796" />
-      <path
-         d="m 141.98607,208.89322 h 1.55545 l 1.96887,5.25031 1.9792,-5.25031 h 1.55546 v 7.71527 h -1.01803 v -6.77476 l -1.98953,5.29165 h -1.04903 l -1.98954,-5.29165 v 6.77476 h -1.01285 z"
-         id="path18798" />
-      <path
-         d="m 151.07593,210.82075 h 0.95084 v 5.78774 h -0.95084 z m 0,-2.25309 h 0.95084 v 1.20406 h -0.95084 z"
-         id="path18800" />
-      <path
-         d="m 158.82737,210.82075 -2.09289,2.81635 2.20141,2.97139 h -1.12138 l -1.68464,-2.27376 -1.68465,2.27376 h -1.12137 l 2.24791,-3.02823 -2.05671,-2.75951 h 1.12137 l 1.53479,2.06188 1.53478,-2.06188 z"
-         id="path18802" />
-      <path
-         d="m 164.9045,213.47691 v 0.46508 h -4.37182 q 0.062,0.98185 0.58911,1.49862 0.53227,0.51159 1.47795,0.51159 0.54776,0 1.05936,-0.13436 0.51676,-0.13436 1.02319,-0.40307 v 0.89917 q -0.5116,0.21704 -1.04903,0.33072 -0.53743,0.11369 -1.09037,0.11369 -1.38492,0 -2.19624,-0.80615 -0.80615,-0.80615 -0.80615,-2.18074 0,-1.42109 0.76481,-2.25308 0.76998,-0.83716 2.07222,-0.83716 1.16788,0 1.84484,0.75448 0.68213,0.7493 0.68213,2.04121 z m -0.95085,-0.27905 q -0.0103,-0.78032 -0.43924,-1.2454 -0.42375,-0.46509 -1.12655,-0.46509 -0.79581,0 -1.2764,0.44959 -0.47542,0.44958 -0.54777,1.26606 z"
-         id="path18804" />
-      <path
-         d="m 169.81891,211.70958 q -0.1602,-0.093 -0.3514,-0.13436 -0.18604,-0.0465 -0.41341,-0.0465 -0.80615,0 -1.24023,0.5271 -0.42891,0.52193 -0.42891,1.50378 v 3.0489 h -0.95602 v -5.78774 h 0.95602 v 0.89917 q 0.29972,-0.5271 0.78031,-0.78032 0.48059,-0.25838 1.16788,-0.25838 0.0982,0 0.21704,0.0155 0.11886,0.0103 0.26355,0.0362 z"
-         id="path18806" />
-    </g>
-  </g>
-  <g
-     inkscape:groupmode="layer"
-     id="layer2"
-     inkscape:label="components"
-     transform="translate(0,1.0517578e-5)"
-     style="display:none">
-    <circle
-       style="display:inline;opacity:1;vector-effect:none;fill:#ff0000;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal"
-       id="path4954"
-       inkscape:label="ch1_aux1"
-       r="4"
-       cy="38.579716"
-       cx="12.567305" />
-    <circle
-       style="display:inline;vector-effect:none;fill:#ff0000;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal"
-       id="path4954-4"
-       inkscape:label="ch1_aux2"
-       r="4"
-       cy="49.177582"
-       cx="12.294399" />
-    <circle
-       style="display:inline;vector-effect:none;fill:#ff0000;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal"
-       id="path4954-4-1"
-       inkscape:label="ch1_pan"
-       r="4"
-       cy="59.066551"
-       cx="12.294397" />
-    <circle
-       style="display:inline;vector-effect:none;fill:#ff0000;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal"
-       id="path4954-4-4"
-       inkscape:label="ch1_mute"
-       r="4"
-       cy="68.688263"
-       cx="12.561668" />
-    <circle
-       style="display:inline;vector-effect:none;fill:#ff0000;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal"
-       id="path4954-9"
-       inkscape:label="ch1_fad"
-       r="4"
-       cy="101.82968"
-       cx="13.363477" />
-    <circle
-       r="4"
-       cy="17.876768"
-       cx="12.840212"
-       id="circle4956"
-       style="display:inline;opacity:1;vector-effect:none;fill:#00ff00;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal"
-       inkscape:label="ch1_in" />
-    <circle
-       r="4"
-       cy="28.330561"
-       cx="12.294398"
-       id="circle4956-1"
-       style="display:inline;vector-effect:none;fill:#00ff00;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal"
-       inkscape:label="ch1_pan" />
-    <circle
-       r="4"
-       cy="28.063299"
-       cx="141.11832"
-       id="circle4956-8"
-       style="display:inline;vector-effect:none;fill:#00ff00;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal"
-       inkscape:label="aux1_return" />
-    <circle
-       r="4"
-       cy="27.79603"
-       cx="159.82718"
-       id="circle4956-7"
-       style="display:inline;vector-effect:none;fill:#00ff00;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal"
-       inkscape:label="aux2_return_l" />
-    <circle
-       r="4"
-       cy="27.261494"
-       cx="173.45793"
-       id="circle4956-2"
-       style="display:inline;vector-effect:none;fill:#00ff00;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal"
-       inkscape:label="aux2_return_r" />
-    <circle
-       style="display:inline;opacity:1;vector-effect:none;fill:#0000ff;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal"
-       id="circle4958"
-       cx="173.19629"
-       cy="112.98891"
-       r="4"
-       inkscape:label="master_out_r" />
-    <circle
-       style="display:inline;vector-effect:none;fill:#0000ff;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal"
-       id="circle4958-9"
-       cx="156.88721"
-       cy="113.05501"
-       r="4"
-       inkscape:label="master_out_l" />
-    <circle
-       style="display:inline;vector-effect:none;fill:#0000ff;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal"
-       id="circle4958-4"
-       cx="160.09445"
-       cy="13.096209"
-       r="4"
-       inkscape:label="aux2_send_l" />
-    <circle
-       style="display:inline;vector-effect:none;fill:#0000ff;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal"
-       id="circle4958-8"
-       cx="172.65611"
-       cy="13.096205"
-       r="4"
-       inkscape:label="aux2_send_r" />
-    <circle
-       style="display:inline;vector-effect:none;fill:#0000ff;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal"
-       id="circle4958-97"
-       cx="141.11832"
-       cy="13.363472"
-       r="4"
-       inkscape:label="aux1_send" />
-    <circle
-       inkscape:label="master_led_l"
-       r="4"
-       cy="77.125618"
-       cx="156.09103"
-       id="circle66"
-       style="display:inline;opacity:1;vector-effect:none;fill:#ff00ff;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal" />
-    <circle
-       inkscape:label="blink"
-       r="4"
-       cy="77.775436"
-       cx="171.85431"
-       id="circle66-8"
-       style="display:inline;vector-effect:none;fill:#ff00ff;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal" />
-    <circle
-       inkscape:label="ch1_level"
-       r="4"
-       cy="77.775421"
-       cx="12.561669"
-       id="circle66-7"
-       style="display:inline;vector-effect:none;fill:#ff00ff;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal" />
-  </g>
-</svg>
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+   width="185.7636mm"
+   height="128.5mm"
+   viewBox="0 0 185.76361 128.50002"
+   version="1.1"
+   id="svg8"
+   inkscape:version="1.1 (c68e22c387, 2021-05-23)"
+   sodipodi:docname="SSI2164-Mixer1.svg"
+   xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+   xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+   xmlns="http://www.w3.org/2000/svg"
+   xmlns:svg="http://www.w3.org/2000/svg"
+   xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+   xmlns:cc="http://creativecommons.org/ns#"
+   xmlns:dc="http://purl.org/dc/elements/1.1/">
+  <defs
+     id="defs2" />
+  <sodipodi:namedview
+     id="base"
+     pagecolor="#ffffff"
+     bordercolor="#666666"
+     borderopacity="1.0"
+     inkscape:pageopacity="0.0"
+     inkscape:pageshadow="2"
+     inkscape:zoom="0.49497475"
+     inkscape:cx="639.42656"
+     inkscape:cy="220.21326"
+     inkscape:document-units="mm"
+     inkscape:current-layer="layer1"
+     showgrid="false"
+     units="mm"
+     inkscape:snap-bbox="true"
+     inkscape:snap-page="true"
+     inkscape:bbox-nodes="false"
+     inkscape:snap-bbox-edge-midpoints="false"
+     inkscape:window-width="1600"
+     inkscape:window-height="900"
+     inkscape:window-x="4292"
+     inkscape:window-y="9"
+     inkscape:window-maximized="0"
+     inkscape:snap-bbox-midpoints="true"
+     inkscape:snap-nodes="false"
+     inkscape:pagecheckerboard="0" />
+  <metadata
+     id="metadata5">
+    <rdf:RDF>
+      <cc:Work
+         rdf:about="">
+        <dc:format>image/svg+xml</dc:format>
+        <dc:type
+           rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+      </cc:Work>
+    </rdf:RDF>
+  </metadata>
+  <g
+     inkscape:label="Layer 1"
+     inkscape:groupmode="layer"
+     id="layer1"
+     transform="translate(0,-168.49997)"
+     style="display:inline">
+    <rect
+       style="display:inline;opacity:1;vector-effect:none;fill:#e6e6e6;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1.60309;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal"
+       id="rect420"
+       width="185.7636"
+       height="128.5"
+       x="5.9211732e-17"
+       y="168.49997" />
+    <g
+       aria-label="2164 Mixer"
+       id="text16740"
+       style="font-size:10.5833px;line-height:1.25;stroke-width:0.264583">
+      <path
+         d="m 112.68046,215.72999 h 3.64318 v 0.8785 h -4.89891 v -0.8785 q 0.59427,-0.61494 1.61746,-1.64847 1.02836,-1.03869 1.29191,-1.33841 0.50126,-0.56328 0.69763,-0.95085 0.20154,-0.39274 0.20154,-0.76997 0,-0.61495 -0.43408,-1.00252 -0.42892,-0.38758 -1.12138,-0.38758 -0.49092,0 -1.03869,0.17054 -0.5426,0.17053 -1.16272,0.51676 v -1.0542 q 0.63045,-0.25321 1.17822,-0.3824 0.54777,-0.12919 1.00252,-0.12919 1.19889,0 1.91202,0.59944 0.71314,0.59945 0.71314,1.60197 0,0.47542 -0.18087,0.90433 -0.1757,0.42375 -0.64596,1.00252 -0.12919,0.14986 -0.82165,0.86816 -0.69246,0.71313 -1.95336,1.99987 z"
+         id="path18790" />
+      <path
+         d="m 118.69558,215.72999 h 1.70531 v -5.88592 l -1.85517,0.37207 v -0.95085 l 1.84484,-0.37207 h 1.04386 v 6.83677 h 1.70532 v 0.8785 h -4.44416 z"
+         id="path18792" />
+      <path
+         d="m 127.60973,212.33486 q -0.70279,0 -1.1162,0.48059 -0.40825,0.48059 -0.40825,1.31775 0,0.83198 0.40825,1.31774 0.41341,0.48059 1.1162,0.48059 0.7028,0 1.11104,-0.48059 0.41341,-0.48576 0.41341,-1.31774 0,-0.83716 -0.41341,-1.31775 -0.40824,-0.48059 -1.11104,-0.48059 z m 2.07222,-3.27111 v 0.95085 q -0.39274,-0.18604 -0.79581,-0.28422 -0.39791,-0.0982 -0.79065,-0.0982 -1.03353,0 -1.58129,0.69763 -0.54261,0.69763 -0.62012,2.1084 0.30489,-0.44959 0.76481,-0.6873 0.45992,-0.24288 1.01285,-0.24288 1.16272,0 1.83451,0.70797 0.67696,0.70279 0.67696,1.91719 0,1.18855 -0.7028,1.90685 -0.70279,0.7183 -1.87068,0.7183 -1.33841,0 -2.04638,-1.02319 -0.70796,-1.02836 -0.70796,-2.97655 0,-1.82934 0.86816,-2.91454 0.86816,-1.09037 2.3306,-1.09037 0.39274,0 0.79065,0.0775 0.40307,0.0775 0.83715,0.23254 z"
+         id="path18794" />
+      <path
+         d="m 134.84958,209.80273 -2.63549,4.11859 h 2.63549 z m -0.27389,-0.90951 h 1.31258 v 5.0281 h 1.10071 v 0.86817 h -1.10071 v 1.819 h -1.03869 v -1.819 h -3.48298 v -1.00769 z"
+         id="path18796" />
+      <path
+         d="m 141.98607,208.89322 h 1.55545 l 1.96887,5.25031 1.9792,-5.25031 h 1.55546 v 7.71527 h -1.01803 v -6.77476 l -1.98953,5.29165 h -1.04903 l -1.98954,-5.29165 v 6.77476 h -1.01285 z"
+         id="path18798" />
+      <path
+         d="m 151.07593,210.82075 h 0.95084 v 5.78774 h -0.95084 z m 0,-2.25309 h 0.95084 v 1.20406 h -0.95084 z"
+         id="path18800" />
+      <path
+         d="m 158.82737,210.82075 -2.09289,2.81635 2.20141,2.97139 h -1.12138 l -1.68464,-2.27376 -1.68465,2.27376 h -1.12137 l 2.24791,-3.02823 -2.05671,-2.75951 h 1.12137 l 1.53479,2.06188 1.53478,-2.06188 z"
+         id="path18802" />
+      <path
+         d="m 164.9045,213.47691 v 0.46508 h -4.37182 q 0.062,0.98185 0.58911,1.49862 0.53227,0.51159 1.47795,0.51159 0.54776,0 1.05936,-0.13436 0.51676,-0.13436 1.02319,-0.40307 v 0.89917 q -0.5116,0.21704 -1.04903,0.33072 -0.53743,0.11369 -1.09037,0.11369 -1.38492,0 -2.19624,-0.80615 -0.80615,-0.80615 -0.80615,-2.18074 0,-1.42109 0.76481,-2.25308 0.76998,-0.83716 2.07222,-0.83716 1.16788,0 1.84484,0.75448 0.68213,0.7493 0.68213,2.04121 z m -0.95085,-0.27905 q -0.0103,-0.78032 -0.43924,-1.2454 -0.42375,-0.46509 -1.12655,-0.46509 -0.79581,0 -1.2764,0.44959 -0.47542,0.44958 -0.54777,1.26606 z"
+         id="path18804" />
+      <path
+         d="m 169.81891,211.70958 q -0.1602,-0.093 -0.3514,-0.13436 -0.18604,-0.0465 -0.41341,-0.0465 -0.80615,0 -1.24023,0.5271 -0.42891,0.52193 -0.42891,1.50378 v 3.0489 h -0.95602 v -5.78774 h 0.95602 v 0.89917 q 0.29972,-0.5271 0.78031,-0.78032 0.48059,-0.25838 1.16788,-0.25838 0.0982,0 0.21704,0.0155 0.11886,0.0103 0.26355,0.0362 z"
+         id="path18806" />
+    </g>
+  </g>
+  <g
+     inkscape:groupmode="layer"
+     id="layer2"
+     inkscape:label="components"
+     transform="translate(0,1.0517578e-5)"
+     style="display:none">
+    <circle
+       style="display:inline;opacity:1;vector-effect:none;fill:#ff0000;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal"
+       id="path4954"
+       inkscape:label="ch1_aux1"
+       r="4"
+       cy="38.579716"
+       cx="12.567305" />
+    <circle
+       style="display:inline;vector-effect:none;fill:#ff0000;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal"
+       id="path4954-4"
+       inkscape:label="ch1_aux2"
+       r="4"
+       cy="49.177582"
+       cx="12.294399" />
+    <circle
+       style="display:inline;vector-effect:none;fill:#ff0000;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal"
+       id="path4954-4-1"
+       inkscape:label="ch1_pan"
+       r="4"
+       cy="59.066551"
+       cx="12.294397" />
+    <circle
+       style="display:inline;vector-effect:none;fill:#ff0000;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal"
+       id="path4954-4-4"
+       inkscape:label="ch1_mute"
+       r="4"
+       cy="68.688263"
+       cx="12.561668" />
+    <circle
+       style="display:inline;vector-effect:none;fill:#ff0000;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal"
+       id="path4954-9"
+       inkscape:label="ch1_fad"
+       r="4"
+       cy="101.82968"
+       cx="13.363477" />
+    <circle
+       r="4"
+       cy="17.876768"
+       cx="12.840212"
+       id="circle4956"
+       style="display:inline;opacity:1;vector-effect:none;fill:#00ff00;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal"
+       inkscape:label="ch1_in" />
+    <circle
+       r="4"
+       cy="28.330561"
+       cx="12.294398"
+       id="circle4956-1"
+       style="display:inline;vector-effect:none;fill:#00ff00;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal"
+       inkscape:label="ch1_pan" />
+    <circle
+       r="4"
+       cy="28.063299"
+       cx="141.11832"
+       id="circle4956-8"
+       style="display:inline;vector-effect:none;fill:#00ff00;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal"
+       inkscape:label="aux1_return" />
+    <circle
+       r="4"
+       cy="27.79603"
+       cx="159.82718"
+       id="circle4956-7"
+       style="display:inline;vector-effect:none;fill:#00ff00;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal"
+       inkscape:label="aux2_return_l" />
+    <circle
+       r="4"
+       cy="27.261494"
+       cx="173.45793"
+       id="circle4956-2"
+       style="display:inline;vector-effect:none;fill:#00ff00;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal"
+       inkscape:label="aux2_return_r" />
+    <circle
+       style="display:inline;opacity:1;vector-effect:none;fill:#0000ff;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal"
+       id="circle4958"
+       cx="173.19629"
+       cy="112.98891"
+       r="4"
+       inkscape:label="master_out_r" />
+    <circle
+       style="display:inline;vector-effect:none;fill:#0000ff;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal"
+       id="circle4958-9"
+       cx="156.88721"
+       cy="113.05501"
+       r="4"
+       inkscape:label="master_out_l" />
+    <circle
+       style="display:inline;vector-effect:none;fill:#0000ff;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal"
+       id="circle4958-4"
+       cx="160.09445"
+       cy="13.096209"
+       r="4"
+       inkscape:label="aux2_send_l" />
+    <circle
+       style="display:inline;vector-effect:none;fill:#0000ff;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal"
+       id="circle4958-8"
+       cx="172.65611"
+       cy="13.096205"
+       r="4"
+       inkscape:label="aux2_send_r" />
+    <circle
+       style="display:inline;vector-effect:none;fill:#0000ff;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal"
+       id="circle4958-97"
+       cx="141.11832"
+       cy="13.363472"
+       r="4"
+       inkscape:label="aux1_send" />
+    <circle
+       inkscape:label="master_led_l"
+       r="4"
+       cy="77.125618"
+       cx="156.09103"
+       id="circle66"
+       style="display:inline;opacity:1;vector-effect:none;fill:#ff00ff;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal" />
+    <circle
+       inkscape:label="blink"
+       r="4"
+       cy="77.775436"
+       cx="171.85431"
+       id="circle66-8"
+       style="display:inline;vector-effect:none;fill:#ff00ff;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal" />
+    <circle
+       inkscape:label="ch1_level"
+       r="4"
+       cy="77.775421"
+       cx="12.561669"
+       id="circle66-7"
+       style="display:inline;vector-effect:none;fill:#ff00ff;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;paint-order:normal" />
+  </g>
+</svg>

+ 156 - 93
src/SSI2164-Mixer1.cpp

@@ -1,101 +1,164 @@
 #include "plugin.hpp"
 #include <componentlibrary.hpp>
 
-
-struct SSI2164_Mixer1 : Module {
-	enum ParamId {
-		CH1_AUX1_PARAM,
-		CH1_AUX2_PARAM,
-		CH1_PAN_PARAM,
-		CH1_MUTE_PARAM,
-		CH1_FAD_PARAM,
-		PARAMS_LEN
-	};
-	enum InputId {
-		CH1_IN_INPUT,
-		CH1_PAN_INPUT,
-		AUX2_RETURN_R_INPUT,
-		AUX2_RETURN_L_INPUT,
-		AUX1_RETURN_INPUT,
-		INPUTS_LEN
-	};
-	enum OutputId {
-		AUX2_SEND_L_OUTPUT,
-		AUX1_SEND_OUTPUT,
-		AUX2_SEND_R_OUTPUT,
-		MASTER_OUT_L_OUTPUT,
-		MASTER_OUT_R_OUTPUT,
-		OUTPUTS_LEN
-	};
-	enum LightId {
-		CH1_LEVEL_LIGHT,
-		MASTER_LED_L_LIGHT,
-		MASTER_LED_R_LIGHT,
-		LIGHTS_LEN
-	};
-
-	SSI2164_Mixer1() {
-		config(PARAMS_LEN, INPUTS_LEN, OUTPUTS_LEN, LIGHTS_LEN);
-		configParam(CH1_AUX1_PARAM, 0.f, 1.f, 0.f, "Aux 1");
-		configParam(CH1_AUX2_PARAM, 0.f, 1.f, 0.f, "Aux 2");
-		configParam(CH1_PAN_PARAM, 0.f, 1.f, 0.5f, "Pan", "R/L", 2.f);
-		configParam(CH1_MUTE_PARAM, 0.f, 1.f, 0.f, "Mute");
-		configParam(CH1_FAD_PARAM, 0.f, 1.f, 0.f, "Fader");
-		configInput(CH1_IN_INPUT, "Ch1");
-		configInput(CH1_PAN_INPUT, "Ch1 Pan CV");
-
-		configOutput(AUX1_SEND_OUTPUT, "Aux 1 Send");
-		configInput(AUX1_RETURN_INPUT, "Aux 1 Return");
-
-		configOutput(AUX2_SEND_L_OUTPUT, "Aux 2 Send L");
-		configOutput(AUX2_SEND_R_OUTPUT, "Aux 2 Send R");
-		configInput(AUX2_RETURN_L_INPUT, "Aux 2 Return L");
-		configInput(AUX2_RETURN_R_INPUT, "Aux 2 Return R");
-
-		configOutput(MASTER_OUT_L_OUTPUT, "Master L");
-		configOutput(MASTER_OUT_R_OUTPUT, "Master R");
-	}
-
-	void process(const ProcessArgs& args) override {
-	}
+struct SSI2164_Mixer1 : Module
+{
+  enum ParamId
+  {
+    CH1_AUX1_PARAM,
+    CH1_AUX2_PARAM,
+    CH1_PAN_PARAM,
+    CH1_MUTE_PARAM,
+    CH1_FAD_PARAM,
+    PARAMS_LEN
+  };
+  enum InputId
+  {
+    CH1_IN_INPUT,
+    CH1_PAN_INPUT,
+    AUX2_RETURN_R_INPUT,
+    AUX2_RETURN_L_INPUT,
+    AUX1_RETURN_INPUT,
+    INPUTS_LEN
+  };
+  enum OutputId
+  {
+    AUX2_SEND_L_OUTPUT,
+    AUX1_SEND_OUTPUT,
+    AUX2_SEND_R_OUTPUT,
+    MASTER_OUT_L_OUTPUT,
+    MASTER_OUT_R_OUTPUT,
+    OUTPUTS_LEN
+  };
+  enum LightId
+  {
+    CH1_LEVEL_LIGHT,
+    MASTER_LED_L_LIGHT,
+    MASTER_LED_R_LIGHT,
+    LIGHTS_LEN
+  };
+
+  SSI2164_Mixer1()
+  {
+    config(PARAMS_LEN, INPUTS_LEN, OUTPUTS_LEN, LIGHTS_LEN);
+    configParam(CH1_AUX1_PARAM, 0.f, 1.f, 0.f, "Aux 1");
+    configParam(CH1_AUX2_PARAM, 0.f, 1.f, 0.f, "Aux 2");
+    configParam(CH1_PAN_PARAM, 0.f, 2100.f, .0f, "Pan", "mV");
+    configParam(CH1_MUTE_PARAM, 0.f, 1.f, 0.f, "Mute");
+    configParam(CH1_FAD_PARAM, 0.f, 1.f, 0.f, "Fader");
+    configInput(CH1_IN_INPUT, "Ch1");
+    configInput(CH1_PAN_INPUT, "Ch1 Pan CV");
+
+    configOutput(AUX1_SEND_OUTPUT, "Aux 1 Send");
+    configInput(AUX1_RETURN_INPUT, "Aux 1 Return");
+
+    configOutput(AUX2_SEND_L_OUTPUT, "Aux 2 Send L");
+    configOutput(AUX2_SEND_R_OUTPUT, "Aux 2 Send R");
+    configInput(AUX2_RETURN_L_INPUT, "Aux 2 Return L");
+    configInput(AUX2_RETURN_R_INPUT, "Aux 2 Return R");
+
+    configOutput(MASTER_OUT_L_OUTPUT, "Master L");
+    configOutput(MASTER_OUT_R_OUTPUT, "Master R");
+  }
+
+  void process(const ProcessArgs &args) override
+  {
+
+    float ssi2164_cv = .0f, ssi2164_in = .0f, ssi2164_out = .0f;
+    float ch1_in = inputs[CH1_IN_INPUT].getVoltage();
+
+    float master_l = .0f;
+    float master_r = .0f;
+    float aux1_out = .0f;
+
+    ssi2164_cv += 2.1 - params[CH1_FAD_PARAM].getValue() * 2.1;
+    ssi2164_in += ch1_in;
+    if (ssi2164_cv < 2)
+      ssi2164_out = ssi2164_in * pow(2, -5.0505 * ssi2164_cv);
+    else
+      ssi2164_out = 0;
+    aux1_out += ssi2164_out;
+
+    master_l += ch1_in * params[CH1_FAD_PARAM].getValue();
+    master_r += ch1_in * pow(100, params[CH1_FAD_PARAM].getValue()) / 100;
+
+    // https://www.dr-lex.be/info-stuff/volumecontrols.html
+    outputs[MASTER_OUT_L_OUTPUT].setVoltage(master_l);
+    outputs[MASTER_OUT_R_OUTPUT].setVoltage(master_r);
+
+    outputs[AUX1_SEND_OUTPUT].setVoltage(aux1_out);
+  }
 };
 
-
-struct SSI2164_Mixer1Widget : ModuleWidget {
-	SSI2164_Mixer1Widget(SSI2164_Mixer1* module) {
-		setModule(module);
-		setPanel(createPanel(asset::plugin(pluginInstance, "res/SSI2164-Mixer1.svg")));
-
-		addChild(createWidget<ScrewSilver>(Vec(RACK_GRID_WIDTH, 0)));
-		addChild(createWidget<ScrewSilver>(Vec(box.size.x - 2 * RACK_GRID_WIDTH, 0)));
-		addChild(createWidget<ScrewSilver>(Vec(RACK_GRID_WIDTH, RACK_GRID_HEIGHT - RACK_GRID_WIDTH)));
-		addChild(createWidget<ScrewSilver>(Vec(box.size.x - 2 * RACK_GRID_WIDTH, RACK_GRID_HEIGHT - RACK_GRID_WIDTH)));
-
-		addInput(createInputCentered<PJ301MPort>(mm2px(Vec(12, 17)), module, SSI2164_Mixer1::CH1_IN_INPUT));
-		addInput(createInputCentered<PJ301MPort>(mm2px(Vec(12, 28)), module, SSI2164_Mixer1::CH1_PAN_INPUT));
-		addParam(createParamCentered<RoundBlackKnob>(mm2px(Vec(12, 38)), module, SSI2164_Mixer1::CH1_AUX1_PARAM));
-		addParam(createParamCentered<RoundBlackKnob>(mm2px(Vec(12, 49)), module, SSI2164_Mixer1::CH1_AUX2_PARAM));
-		addParam(createParamCentered<RoundBlackKnob>(mm2px(Vec(12, 59)), module, SSI2164_Mixer1::CH1_PAN_PARAM));
-		addParam(createParamCentered<VCVLatch>(mm2px(Vec(12, 68)), module, SSI2164_Mixer1::CH1_MUTE_PARAM));
-		addChild(createLightCentered<MediumLight<RedLight>>(mm2px(Vec(12, 77)), module, SSI2164_Mixer1::CH1_LEVEL_LIGHT));
-		addParam(createParamCentered<VCVSlider>(mm2px(Vec(12, 101)), module, SSI2164_Mixer1::CH1_FAD_PARAM));
-
-
-		addOutput(createOutputCentered<PJ301MPort>(mm2px(Vec(141, 13)), module, SSI2164_Mixer1::AUX1_SEND_OUTPUT));
-		addInput(createInputCentered<PJ301MPort>(mm2px(Vec(141, 27)), module, SSI2164_Mixer1::AUX1_RETURN_INPUT));
-
-		addInput(createInputCentered<PJ301MPort>(mm2px(Vec(160, 27)), module, SSI2164_Mixer1::AUX2_RETURN_L_INPUT));
-		addInput(createInputCentered<PJ301MPort>(mm2px(Vec(172, 27)), module, SSI2164_Mixer1::AUX2_RETURN_R_INPUT));
-		addOutput(createOutputCentered<PJ301MPort>(mm2px(Vec(160, 13)), module, SSI2164_Mixer1::AUX2_SEND_L_OUTPUT));
-		addOutput(createOutputCentered<PJ301MPort>(mm2px(Vec(172, 13)), module, SSI2164_Mixer1::AUX2_SEND_R_OUTPUT));
-
-		addOutput(createOutputCentered<PJ301MPort>(mm2px(Vec(160, 113)), module, SSI2164_Mixer1::MASTER_OUT_L_OUTPUT));
-		addOutput(createOutputCentered<PJ301MPort>(mm2px(Vec(172, 113)), module, SSI2164_Mixer1::MASTER_OUT_R_OUTPUT));
-
-		addChild(createLightCentered<MediumLight<RedLight>>(mm2px(Vec(160, 77)), module, SSI2164_Mixer1::MASTER_LED_L_LIGHT));
-		addChild(createLightCentered<MediumLight<RedLight>>(mm2px(Vec(172, 77)), module, SSI2164_Mixer1::MASTER_LED_R_LIGHT));
-	}
+struct KnobPenis : RoundKnob
+{
+  KnobPenis()
+  {
+    setSvg(contextGet()->window->loadSvg(
+        asset::plugin(pluginInstance, "res/KnobPenis.svg")));
+    box.size = Vec(19, 19);
+  }
 };
 
+struct SSI2164_Mixer1Widget : ModuleWidget
+{
+  SSI2164_Mixer1Widget(SSI2164_Mixer1 *module)
+  {
+    setModule(module);
+    setPanel(
+        createPanel(asset::plugin(pluginInstance, "res/SSI2164-Mixer1.svg")));
+
+    addChild(createWidget<ThemedScrew>(Vec(RACK_GRID_WIDTH, 0)));
+    addChild(
+        createWidget<ScrewSilver>(Vec(box.size.x - 2 * RACK_GRID_WIDTH, 0)));
+    addChild(createWidget<ThemedScrew>(
+        Vec(RACK_GRID_WIDTH, RACK_GRID_HEIGHT - RACK_GRID_WIDTH)));
+    addChild(createWidget<ScrewSilver>(Vec(
+        box.size.x - 2 * RACK_GRID_WIDTH, RACK_GRID_HEIGHT - RACK_GRID_WIDTH)));
+
+    addInput(createInputCentered<ThemedPJ301MPort>(
+        mm2px(Vec(12, 17)), module, SSI2164_Mixer1::CH1_IN_INPUT));
+    addInput(createInputCentered<ThemedPJ301MPort>(
+        mm2px(Vec(12, 28)), module, SSI2164_Mixer1::CH1_PAN_INPUT));
+    addParam(createParamCentered<RoundBlackKnob>(
+        mm2px(Vec(12, 38)), module, SSI2164_Mixer1::CH1_AUX1_PARAM));
+    addParam(createParamCentered<RoundBlackKnob>(
+        mm2px(Vec(12, 49)), module, SSI2164_Mixer1::CH1_AUX2_PARAM));
+    addParam(createParamCentered<KnobPenis>(mm2px(Vec(12, 59)), module,
+                                            SSI2164_Mixer1::CH1_PAN_PARAM));
+    addParam(createParamCentered<VCVLatch>(mm2px(Vec(12, 68)), module,
+                                           SSI2164_Mixer1::CH1_MUTE_PARAM));
+    addChild(createLightCentered<MediumLight<RedLight>>(
+        mm2px(Vec(12, 77)), module, SSI2164_Mixer1::CH1_LEVEL_LIGHT));
+
+    addParam(createParamCentered<VCVSlider>(mm2px(Vec(12, 101)), module,
+                                            SSI2164_Mixer1::CH1_FAD_PARAM));
+
+    addOutput(createOutputCentered<ThemedPJ301MPort>(
+        mm2px(Vec(141, 13)), module, SSI2164_Mixer1::AUX1_SEND_OUTPUT));
+    addInput(createInputCentered<ThemedPJ301MPort>(
+        mm2px(Vec(141, 27)), module, SSI2164_Mixer1::AUX1_RETURN_INPUT));
+
+    addInput(createInputCentered<ThemedPJ301MPort>(
+        mm2px(Vec(160, 27)), module, SSI2164_Mixer1::AUX2_RETURN_L_INPUT));
+    addInput(createInputCentered<ThemedPJ301MPort>(
+        mm2px(Vec(172, 27)), module, SSI2164_Mixer1::AUX2_RETURN_R_INPUT));
+    addOutput(createOutputCentered<ThemedPJ301MPort>(
+        mm2px(Vec(160, 13)), module, SSI2164_Mixer1::AUX2_SEND_L_OUTPUT));
+    addOutput(createOutputCentered<ThemedPJ301MPort>(
+        mm2px(Vec(172, 13)), module, SSI2164_Mixer1::AUX2_SEND_R_OUTPUT));
+
+    addOutput(createOutputCentered<ThemedPJ301MPort>(
+        mm2px(Vec(160, 113)), module, SSI2164_Mixer1::MASTER_OUT_L_OUTPUT));
+    addOutput(createOutputCentered<ThemedPJ301MPort>(
+        mm2px(Vec(172, 113)), module, SSI2164_Mixer1::MASTER_OUT_R_OUTPUT));
+
+    addChild(createLightCentered<MediumLight<RedLight>>(
+        mm2px(Vec(160, 77)), module, SSI2164_Mixer1::MASTER_LED_L_LIGHT));
+    addChild(createLightCentered<MediumLight<RedLight>>(
+        mm2px(Vec(172, 77)), module, SSI2164_Mixer1::MASTER_LED_R_LIGHT));
+  }
+};
 
-Model* modelSSI2164_Mixer1 = createModel<SSI2164_Mixer1, SSI2164_Mixer1Widget>("SSI2164-Mixer1");
+Model *modelSSI2164_Mixer1 =
+    createModel<SSI2164_Mixer1, SSI2164_Mixer1Widget>("SSI2164-Mixer1");