11 |
12 | @interface UI_MockupTests : XCTestCase
13 |
14 | @end
15 |
16 | @implementation UI_MockupTests
17 |
18 | - (void)setUp {
19 | [super setUp];
20 | // Put setup code here. This method is called before the invocation of each test method in the class.
21 | }
22 |
23 | - (void)tearDown {
24 | // Put teardown code here. This method is called after the invocation of each test method in the class.
25 | [super tearDown];
26 | }
27 |
28 | - (void)testExample {
29 | // This is an example of a functional test case.
30 | XCTAssert(YES, @"Pass");
31 | }
32 |
33 | - (void)testPerformanceExample {
34 | // This is an example of a performance test case.
35 | [self measureBlock:^{
36 | // Put the code you want to measure the time of here.
37 | }];
38 | }
39 |
40 | @end
41 |
--------------------------------------------------------------------------------
/ECAD/LaenPCBOrder.dru:
--------------------------------------------------------------------------------
1 | description[de] = EAGLE Design Rules\n\nDie Standard-Design-Rules sind so gewählt, dass sie für \ndie meisten Anwendungen passen. Sollte ihre Platine \nbesondere Anforderungen haben, treffen Sie die erforderlichen\nEinstellungen hier und speichern die Design Rules unter \neinem neuen Namen ab.
2 | description[en] = Laen's PCB Order Design Rules\n
\nPlease make sure your boards conform to these design rules.
3 | layerSetup = (1*16)
4 | mtCopper = 0.0356mm 0.0356mm 0.0356mm 0.0356mm 0.0356mm 0.0356mm 0.0356mm 0.0356mm 0.0356mm 0.0356mm 0.0356mm 0.0356mm 0.0356mm 0.0356mm 0.0356mm 0.0356mm
5 | mtIsolate = 1.5011mm 0.1499mm 0.2007mm 0.1499mm 0.2007mm 0.1499mm 0.2007mm 0.1499mm 0.2007mm 0.1499mm 0.2007mm 0.1499mm 0.2007mm 0.1499mm 0.2007mm
6 | mdWireWire = 6mil
7 | mdWirePad = 6mil
8 | mdWireVia = 6mil
9 | mdPadPad = 6mil
10 | mdPadVia = 6mil
11 | mdViaVia = 6mil
12 | mdSmdPad = 6mil
13 | mdSmdVia = 6mil
14 | mdSmdSmd = 6mil
15 | mdViaViaSameLayer = 8mil
16 | mnLayersViaInSmd = 2
17 | mdCopperDimension = 15mil
18 | mdDrill = 6mil
19 | mdSmdStop = 0mil
20 | msWidth = 6mil
21 | msDrill = 13mil
22 | msMicroVia = 13mil
23 | msBlindViaRatio = 0.500000
24 | rvPadTop = 0.250000
25 | rvPadInner = 0.250000
26 | rvPadBottom = 0.250000
27 | rvViaOuter = 0.250000
28 | rvViaInner = 0.250000
29 | rvMicroViaOuter = 0.250000
30 | rvMicroViaInner = 0.250000
31 | rlMinPadTop = 7mil
32 | rlMaxPadTop = 20mil
33 | rlMinPadInner = 7mil
34 | rlMaxPadInner = 20mil
35 | rlMinPadBottom = 7mil
36 | rlMaxPadBottom = 20mil
37 | rlMinViaOuter = 7mil
38 | rlMaxViaOuter = 20mil
39 | rlMinViaInner = 7mil
40 | rlMaxViaInner = 20mil
41 | rlMinMicroViaOuter = 4mil
42 | rlMaxMicroViaOuter = 20mil
43 | rlMinMicroViaInner = 4mil
44 | rlMaxMicroViaInner = 20mil
45 | psTop = -1
46 | psBottom = -1
47 | psFirst = -1
48 | psElongationLong = 100
49 | psElongationOffset = 100
50 | mvStopFrame = 1.000000
51 | mvCreamFrame = 0.000000
52 | mlMinStopFrame = 3mil
53 | mlMaxStopFrame = 3mil
54 | mlMinCreamFrame = 0mil
55 | mlMaxCreamFrame = 0mil
56 | mlViaStopLimit = 0mil
57 | srRoundness = 0.000000
58 | srMinRoundness = 0mil
59 | srMaxRoundness = 0mil
60 | slThermalGap = 0.500000
61 | slMinThermalGap = 20mil
62 | slMaxThermalGap = 100mil
63 | slAnnulusIsolate = 20mil
64 | slThermalIsolate = 10mil
65 | slAnnulusRestring = 0
66 | slThermalRestring = 1
67 | slThermalsForVias = 0
68 | checkGrid = 0
69 | checkAngle = 0
70 | checkFont = 1
71 | checkRestrict = 1
72 | useDiameter = 13
73 | maxErrors = 50
74 |
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/.gitignore:
--------------------------------------------------------------------------------
1 | *-rescue.lib
2 | *.bak
3 | *.bck
4 | *.dsn
5 | *.kicad_pcb-bak
6 | *.kicad_pcb.orig
7 | *.rpt
8 | *.ses
9 | _autosave-*
10 | _saved_*.sch
11 |
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/Digikey Order.numbers:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/ECAD/io_daughterboard/Digikey Order.numbers
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/Stuffing Guide.rtf:
--------------------------------------------------------------------------------
1 | {\rtf1\ansi\ansicpg1252\cocoartf1404\cocoasubrtf470
2 | {\fonttbl\f0\fswiss\fcharset0 Helvetica;}
3 | {\colortbl;\red255\green255\blue255;}
4 | \margl1440\margr1440\vieww13440\viewh17040\viewkind1
5 | \pard\tx2160\tx2165\tx2880\tx3600\tx4320\tx5040\tx5760\tx6480\tx7200\tx7920\tx8640\sl360\slmult1\pardirnatural\partightenfactor0
6 |
7 | \f0\fs24 \cf0 J1 FPC-40\
8 | J2 FPC-6\
9 | L1 10uH\
10 | User button\
11 | \pard\tx2160\tx2165\tx2880\tx3600\tx4320\tx5040\tx5760\tx6480\tx7200\tx7920\tx8640\pardirnatural\partightenfactor0
12 | \cf0 System\
13 | \pard\tx2160\tx2165\tx2880\tx3600\tx4320\tx5040\tx5760\tx6480\tx7200\tx7920\tx8640\sl360\slmult1\pardirnatural\partightenfactor0
14 | \cf0 U6 STMPE811\
15 | U3 U4 U5 74HC244\
16 | \pard\tx2160\tx2165\tx2880\tx3600\tx4320\tx5040\tx5760\tx6480\tx7200\tx7920\tx8640\pardirnatural\partightenfactor0
17 | \cf0 U7 U8 U9\
18 | \pard\tx2160\tx2165\tx2880\tx3600\tx4320\tx5040\tx5760\tx6480\tx7200\tx7920\tx8640\sl360\slmult1\pardirnatural\partightenfactor0
19 | \cf0 U2 SPX3819\
20 | U1 FAN533\
21 | U10 U11 74LV1T34\
22 | D1 -|<- MBR0540\
23 | D2 -|<- 24V Zener\
24 | \
25 | C10 C11 1\'b5F 0805\
26 | C13 10nF\
27 | C14 1\'b5F\
28 | C15 C16 1nF\
29 | C1 C2 C3 C4 C5 100nF\
30 | \pard\tx2160\tx2165\tx2880\tx3600\tx4320\tx5040\tx5760\tx6480\tx7200\tx7920\tx8640\pardirnatural\partightenfactor0
31 | \cf0 C6 C7 C8 C9 C12\
32 | \pard\tx2160\tx2165\tx2880\tx3600\tx4320\tx5040\tx5760\tx6480\tx7200\tx7920\tx8640\sl360\slmult1\pardirnatural\partightenfactor0
33 | \cf0 \
34 | R13 4.3\
35 | R14 R28 1M\
36 | R15 R16 R19 R22 4.7K\
37 | R25 R31 100\
38 | R32 R33 R34 R35 100K\
39 | R1 R2 R3 R4 R5 10K\
40 | \pard\tx2160\tx2165\tx2880\tx3600\tx4320\tx5040\tx5760\tx6480\tx7200\tx7920\tx8640\pardirnatural\partightenfactor0
41 | \cf0 R6 R7 R8 R9 R10\
42 | R11 R17 R18 R20 R21\
43 | R23 R24 R26 R27 R29\
44 | R30\
45 | }
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/artwork/MVS Logo.xcf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/ECAD/io_daughterboard/artwork/MVS Logo.xcf
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/datasheets/3.3V Regulator/Exar-SPX3819M5-L-3-3_TR-datasheet.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/ECAD/io_daughterboard/datasheets/3.3V Regulator/Exar-SPX3819M5-L-3-3_TR-datasheet.pdf
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/datasheets/Capacitive Touch Connector/ER-CON06HT-1.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/ECAD/io_daughterboard/datasheets/Capacitive Touch Connector/ER-CON06HT-1.pdf
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/datasheets/Capacitive Touch Connector/ER-TPC050-1_Drawing.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/ECAD/io_daughterboard/datasheets/Capacitive Touch Connector/ER-TPC050-1_Drawing.pdf
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/datasheets/Capacitive Touch Connector/GSL1680.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/ECAD/io_daughterboard/datasheets/Capacitive Touch Connector/GSL1680.pdf
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/datasheets/Capacitive Touch Connector/en-xf2l.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/ECAD/io_daughterboard/datasheets/Capacitive Touch Connector/en-xf2l.pdf
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/datasheets/LCD Backlight Driver/FAN5333BSX-Fairchild.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/ECAD/io_daughterboard/datasheets/LCD Backlight Driver/FAN5333BSX-Fairchild.pdf
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/datasheets/LCD Backlight Driver/MBR0540-Fairchild.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/ECAD/io_daughterboard/datasheets/LCD Backlight Driver/MBR0540-Fairchild.pdf
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/datasheets/LCD Backlight Driver/MM3Z2V4T1-D.PDF:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/ECAD/io_daughterboard/datasheets/LCD Backlight Driver/MM3Z2V4T1-D.PDF
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/datasheets/LCD Connector/ER-TFT050-3_Datasheet.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/ECAD/io_daughterboard/datasheets/LCD Connector/ER-TFT050-3_Datasheet.pdf
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/datasheets/LCD Connector/FH12_05860557855_2d.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/ECAD/io_daughterboard/datasheets/LCD Connector/FH12_05860557855_2d.pdf
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/datasheets/LCD Connector/FH12_catalog.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/ECAD/io_daughterboard/datasheets/LCD Connector/FH12_catalog.pdf
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/datasheets/MIDI Level Shifters/sn74lv1t34.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/ECAD/io_daughterboard/datasheets/MIDI Level Shifters/sn74lv1t34.pdf
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/datasheets/Master Sockets/ssq_th.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/ECAD/io_daughterboard/datasheets/Master Sockets/ssq_th.pdf
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/datasheets/Master Sockets/ssw-1xx-xx-xxx-x-xx-xxx-xx-mkt.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/ECAD/io_daughterboard/datasheets/Master Sockets/ssw-1xx-xx-xxx-x-xx-xxx-xx-mkt.pdf
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/datasheets/Master Sockets/ssw-d.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/ECAD/io_daughterboard/datasheets/Master Sockets/ssw-d.pdf
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/datasheets/Power Barrel jack/21mmdcjackDatasheet.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/ECAD/io_daughterboard/datasheets/Power Barrel jack/21mmdcjackDatasheet.pdf
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/datasheets/Resistive Touch Controller/STMPE811.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/ECAD/io_daughterboard/datasheets/Resistive Touch Controller/STMPE811.pdf
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/datasheets/SPI Buffers/74HC_HCT244.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/ECAD/io_daughterboard/datasheets/SPI Buffers/74HC_HCT244.pdf
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/datasheets/Slave Headers/ePH.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/ECAD/io_daughterboard/datasheets/Slave Headers/ePH.pdf
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/datasheets/Tactile Buttons/4301x2xxx8x6.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/ECAD/io_daughterboard/datasheets/Tactile Buttons/4301x2xxx8x6.pdf
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/pcb/daughterfeet.pretty/B4B-PH-SM4-TB.kicad_mod:
--------------------------------------------------------------------------------
1 | (module B4B-PH-SM4-TB (layer F.Cu) (tedit 582E4748)
2 | (fp_text reference REF** (at -4.15 -2.775) (layer F.SilkS)
3 | (effects (font (size 1 1) (thickness 0.15)))
4 | )
5 | (fp_text value "JST B4B-PH-SM4-TB" (at 0.05 -5.525) (layer F.Fab)
6 | (effects (font (size 1 1) (thickness 0.15)))
7 | )
8 | (fp_line (start 5.975 3.1) (end 4 3.1) (layer F.SilkS) (width 0.4))
9 | (fp_line (start -5.975 -1.175) (end -5.975 -1.9) (layer F.SilkS) (width 0.4))
10 | (fp_line (start 5.975 -1.9) (end 5.975 -1.175) (layer F.SilkS) (width 0.4))
11 | (fp_line (start -5.975 3.1) (end -4 3.1) (layer F.SilkS) (width 0.4))
12 | (fp_line (start -5.975 -1.9) (end 5.975 -1.9) (layer F.SilkS) (width 0.4))
13 | (pad 0 connect rect (at 5.4 0.6) (size 1.6 3) (layers F.Cu F.Mask))
14 | (pad 4 smd rect (at -3 2.85) (size 1 5.5) (layers F.Cu F.Paste F.Mask))
15 | (pad 3 smd rect (at -1 2.85) (size 1 5.5) (layers F.Cu F.Paste F.Mask))
16 | (pad 2 smd rect (at 1 2.85) (size 1 5.5) (layers F.Cu F.Paste F.Mask))
17 | (pad 1 smd rect (at 3 2.85) (size 1 5.5) (layers F.Cu F.Paste F.Mask))
18 | (pad 0 connect rect (at -5.4 0.6) (size 1.6 3) (layers F.Cu F.Mask))
19 | )
20 |
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/pcb/daughterfeet.pretty/B6B-PH-SM4-TB.kicad_mod:
--------------------------------------------------------------------------------
1 | (module B6B-PH-SM4-TB (layer F.Cu) (tedit 582E45DB)
2 | (fp_text reference REF** (at -6.15 -2.775) (layer F.SilkS)
3 | (effects (font (size 1 1) (thickness 0.15)))
4 | )
5 | (fp_text value "JST B6B-PH-SM4-TB" (at 0.05 -5.525) (layer F.Fab)
6 | (effects (font (size 1 1) (thickness 0.15)))
7 | )
8 | (fp_line (start 7.975 3.1) (end 6 3.1) (layer F.SilkS) (width 0.4))
9 | (fp_line (start -7.975 -1.175) (end -7.975 -1.9) (layer F.SilkS) (width 0.4))
10 | (fp_line (start 7.975 -1.9) (end 7.975 -1.175) (layer F.SilkS) (width 0.4))
11 | (fp_line (start -7.975 3.1) (end -6 3.1) (layer F.SilkS) (width 0.4))
12 | (fp_line (start -7.975 -1.9) (end 7.975 -1.9) (layer F.SilkS) (width 0.4))
13 | (pad 6 smd rect (at -5 2.85) (size 1 5.5) (layers F.Cu F.Paste F.Mask))
14 | (pad 5 smd rect (at -3 2.85) (size 1 5.5) (layers F.Cu F.Paste F.Mask))
15 | (pad 0 connect rect (at 7.4 0.6) (size 1.6 3) (layers F.Cu F.Mask))
16 | (pad 4 smd rect (at -1 2.85) (size 1 5.5) (layers F.Cu F.Paste F.Mask))
17 | (pad 3 smd rect (at 1 2.85) (size 1 5.5) (layers F.Cu F.Paste F.Mask))
18 | (pad 2 smd rect (at 3 2.85) (size 1 5.5) (layers F.Cu F.Paste F.Mask))
19 | (pad 1 smd rect (at 5 2.85) (size 1 5.5) (layers F.Cu F.Paste F.Mask))
20 | (pad 0 connect rect (at -7.4 0.6) (size 1.6 3) (layers F.Cu F.Mask))
21 | )
22 |
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/pcb/daughterfeet.pretty/BARREL_JACK.kicad_mod:
--------------------------------------------------------------------------------
1 | (module BARREL_JACK (layer F.Cu) (tedit 58573BCC)
2 | (descr "DC Barrel Jack")
3 | (tags "Power Jack")
4 | (fp_text reference CON1 (at -2 6 180) (layer F.SilkS) hide
5 | (effects (font (size 1 1) (thickness 0.15)))
6 | )
7 | (fp_text value BARREL_JACK (at 0 -5.99948) (layer F.Fab)
8 | (effects (font (size 1 1) (thickness 0.15)))
9 | )
10 | (fp_text user "5V DC" (at 13.5 0 90) (layer F.SilkS)
11 | (effects (font (size 1 1) (thickness 0.15)))
12 | )
13 | (fp_text user + (at 10.5 -5.014776 90) (layer F.SilkS)
14 | (effects (font (size 1 1) (thickness 0.15)))
15 | )
16 | (fp_text user - (at 10.5 5 90) (layer F.SilkS)
17 | (effects (font (size 1 1) (thickness 0.15)))
18 | )
19 | (fp_line (start 10.5 1.5) (end 10.5 4) (layer F.SilkS) (width 0.4))
20 | (fp_line (start 10.5 -0.5) (end 10.5 -4) (layer F.SilkS) (width 0.4))
21 | (fp_arc (start 10.5 0) (end 11.5 -1) (angle 270) (layer F.SilkS) (width 0.4))
22 | (fp_circle (center 10.5 0) (end 10.5 0.5) (layer F.SilkS) (width 0.4))
23 | (fp_line (start -4.0005 -4.50088) (end -4.0005 4.50088) (layer F.SilkS) (width 0.15))
24 | (fp_line (start -7.50062 -4.50088) (end -7.50062 4.50088) (layer F.SilkS) (width 0.15))
25 | (fp_line (start -7.50062 4.50088) (end 7.00024 4.50088) (layer F.SilkS) (width 0.15))
26 | (fp_line (start 7.00024 4.50088) (end 7.00024 -4.50088) (layer F.SilkS) (width 0.15))
27 | (fp_line (start 7.00024 -4.50088) (end -7.50062 -4.50088) (layer F.SilkS) (width 0.15))
28 | (pad 1 thru_hole rect (at 6.20014 0) (size 3.50012 3.50012) (drill 1.1) (layers *.Cu *.Mask))
29 | (pad 2 thru_hole rect (at 0.20066 0) (size 3.50012 3.50012) (drill 1.1) (layers *.Cu *.Mask))
30 | (pad 3 thru_hole rect (at 3.2004 4.699) (size 3.50012 3.50012) (drill 1.1) (layers *.Cu *.Mask))
31 | (model Connect.3dshapes/JACK_ALIM.wrl
32 | (at (xyz 0 0 0))
33 | (scale (xyz 0.75 0.75 0.75))
34 | (rotate (xyz 0 0 0))
35 | )
36 | )
37 |
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/pcb/daughterfeet.pretty/Molex_PicoBlade_53047-0610_06x1.25mm_Straight.kicad_mod:
--------------------------------------------------------------------------------
1 | (module Molex_PicoBlade_53047-0610_06x1.25mm_Straight (layer F.Cu) (tedit 58326060)
2 | (descr "Molex PicoBlade, single row, top entry type, through hole, PN:53047-0610")
3 | (tags "connector molex picoblade")
4 | (fp_text reference REF** (at 3.125 2.5) (layer F.Fab)
5 | (effects (font (size 1 1) (thickness 0.15)))
6 | )
7 | (fp_text value Molex_PicoBlade_53047-0610_06x1.25mm_Straight (at 3.125 -3.25) (layer F.SilkS)
8 | (effects (font (size 1 1) (thickness 0.15)))
9 | )
10 | (fp_circle (center -1.1 0.725) (end -0.9 0.725) (layer F.Fab) (width 0.15))
11 | (fp_line (start -2 -2.55) (end -2 1.6) (layer F.CrtYd) (width 0.05))
12 | (fp_line (start -2 1.6) (end 8.25 1.6) (layer F.CrtYd) (width 0.05))
13 | (fp_line (start 8.25 1.6) (end 8.25 -2.55) (layer F.CrtYd) (width 0.05))
14 | (fp_line (start 8.25 -2.55) (end -2 -2.55) (layer F.CrtYd) (width 0.05))
15 | (fp_line (start -1.5 -2.075) (end -1.5 1.125) (layer F.Fab) (width 0.15))
16 | (fp_line (start -1.5 1.125) (end 7.75 1.125) (layer F.Fab) (width 0.15))
17 | (fp_line (start 7.75 1.125) (end 7.75 -2.075) (layer F.Fab) (width 0.15))
18 | (fp_line (start 7.75 -2.075) (end -1.5 -2.075) (layer F.Fab) (width 0.15))
19 | (fp_line (start -1.65 -2.225) (end -1.65 1.275) (layer F.SilkS) (width 0.15))
20 | (fp_line (start -1.65 1.275) (end 7.9 1.275) (layer F.SilkS) (width 0.15))
21 | (fp_line (start 7.9 1.275) (end 7.9 -2.225) (layer F.SilkS) (width 0.15))
22 | (fp_line (start 7.9 -2.225) (end -1.65 -2.225) (layer F.SilkS) (width 0.15))
23 | (fp_line (start 3.125 0.725) (end -1.1 0.725) (layer F.SilkS) (width 0.15))
24 | (fp_line (start -1.1 0.725) (end -1.1 0) (layer F.SilkS) (width 0.15))
25 | (fp_line (start -1.1 0) (end -1.3 0) (layer F.SilkS) (width 0.15))
26 | (fp_line (start -1.3 0) (end -1.3 -0.8) (layer F.SilkS) (width 0.15))
27 | (fp_line (start -1.3 -0.8) (end -1.1 -0.8) (layer F.SilkS) (width 0.15))
28 | (fp_line (start -1.1 -0.8) (end -1.1 -1.675) (layer F.SilkS) (width 0.15))
29 | (fp_line (start -1.1 -1.675) (end 3.125 -1.675) (layer F.SilkS) (width 0.15))
30 | (fp_line (start 3.125 0.725) (end 7.35 0.725) (layer F.SilkS) (width 0.15))
31 | (fp_line (start 7.35 0.725) (end 7.35 0) (layer F.SilkS) (width 0.15))
32 | (fp_line (start 7.35 0) (end 7.55 0) (layer F.SilkS) (width 0.15))
33 | (fp_line (start 7.55 0) (end 7.55 -0.8) (layer F.SilkS) (width 0.15))
34 | (fp_line (start 7.55 -0.8) (end 7.35 -0.8) (layer F.SilkS) (width 0.15))
35 | (fp_line (start 7.35 -0.8) (end 7.35 -1.675) (layer F.SilkS) (width 0.15))
36 | (fp_line (start 7.35 -1.675) (end 3.125 -1.675) (layer F.SilkS) (width 0.15))
37 | (fp_line (start -1.9 1.525) (end -1.9 0.525) (layer F.SilkS) (width 0.15))
38 | (fp_line (start -1.9 1.525) (end -0.9 1.525) (layer F.SilkS) (width 0.15))
39 | (pad 1 thru_hole rect (at 0 0) (size 0.85 0.85) (drill 0.5) (layers *.Cu *.Mask))
40 | (pad 2 thru_hole circle (at 1.25 0) (size 0.85 0.85) (drill 0.5) (layers *.Cu *.Mask))
41 | (pad 3 thru_hole circle (at 2.5 0) (size 0.85 0.85) (drill 0.5) (layers *.Cu *.Mask))
42 | (pad 4 thru_hole circle (at 3.75 0) (size 0.85 0.85) (drill 0.5) (layers *.Cu *.Mask))
43 | (pad 5 thru_hole circle (at 5 0) (size 0.85 0.85) (drill 0.5) (layers *.Cu *.Mask))
44 | (pad 6 thru_hole circle (at 6.25 0) (size 0.85 0.85) (drill 0.5) (layers *.Cu *.Mask))
45 | (model Connectors_Molex.3dshapes/Molex_PicoBlade_53047-0610.wrl
46 | (at (xyz 0.123031 0 0))
47 | (scale (xyz 1 1 1))
48 | (rotate (xyz 0 0 180))
49 | )
50 | )
51 |
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/pcb/daughterfeet.pretty/R_0603_HandSoldering_no_paste.kicad_mod:
--------------------------------------------------------------------------------
1 | (module R_0603_HandSoldering_no_paste (layer F.Cu) (tedit 583CB79E)
2 | (descr "Resistor SMD 0603, hand soldering")
3 | (tags "resistor 0603")
4 | (attr smd)
5 | (fp_text reference REF** (at 0 -1.9) (layer F.SilkS)
6 | (effects (font (size 1 1) (thickness 0.15)))
7 | )
8 | (fp_text value R_0603_HandSoldering (at 0 1.9) (layer F.Fab)
9 | (effects (font (size 1 1) (thickness 0.15)))
10 | )
11 | (fp_line (start -0.8 0.4) (end -0.8 -0.4) (layer F.Fab) (width 0.1))
12 | (fp_line (start 0.8 0.4) (end -0.8 0.4) (layer F.Fab) (width 0.1))
13 | (fp_line (start 0.8 -0.4) (end 0.8 0.4) (layer F.Fab) (width 0.1))
14 | (fp_line (start -0.8 -0.4) (end 0.8 -0.4) (layer F.Fab) (width 0.1))
15 | (fp_line (start -2 -0.8) (end 2 -0.8) (layer F.CrtYd) (width 0.05))
16 | (fp_line (start -2 0.8) (end 2 0.8) (layer F.CrtYd) (width 0.05))
17 | (fp_line (start -2 -0.8) (end -2 0.8) (layer F.CrtYd) (width 0.05))
18 | (fp_line (start 2 -0.8) (end 2 0.8) (layer F.CrtYd) (width 0.05))
19 | (fp_line (start 0.5 0.675) (end -0.5 0.675) (layer F.SilkS) (width 0.15))
20 | (fp_line (start -0.5 -0.675) (end 0.5 -0.675) (layer F.SilkS) (width 0.15))
21 | (pad 1 smd rect (at -1.1 0) (size 1.2 0.9) (layers F.Cu F.Mask))
22 | (pad 2 smd rect (at 1.1 0) (size 1.2 0.9) (layers F.Cu F.Mask))
23 | (model Resistors_SMD.3dshapes/R_0603_HandSoldering.wrl
24 | (at (xyz 0 0 0))
25 | (scale (xyz 1 1 1))
26 | (rotate (xyz 0 0 0))
27 | )
28 | )
29 |
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/pcb/daughterfeet.pretty/WS-TASV.kicad_mod:
--------------------------------------------------------------------------------
1 | (module WS-TASV (layer F.Cu) (tedit 5857448A)
2 | (fp_text reference REF** (at 0 -4) (layer F.Fab)
3 | (effects (font (size 1 1) (thickness 0.15)))
4 | )
5 | (fp_text value WS-TASV (at 0 4) (layer F.SilkS)
6 | (effects (font (size 1 1) (thickness 0.15)))
7 | )
8 | (fp_line (start 3 1) (end 3 -1) (layer F.SilkS) (width 0.4))
9 | (fp_line (start -3 -1) (end -3 1) (layer F.SilkS) (width 0.4))
10 | (fp_line (start 3 -3) (end -3 -3) (layer F.SilkS) (width 0.4))
11 | (fp_line (start -3 3) (end 3 3) (layer F.SilkS) (width 0.4))
12 | (pad 1 smd rect (at -3.975 -2.25) (size 1.55 1.3) (layers F.Cu F.Paste F.Mask))
13 | (pad 2 smd rect (at -3.975 2.25) (size 1.55 1.3) (layers F.Cu F.Paste F.Mask))
14 | (pad 3 smd rect (at 3.975 -2.25) (size 1.55 1.3) (layers F.Cu F.Paste F.Mask))
15 | (pad 4 smd rect (at 3.975 2.25) (size 1.55 1.3) (layers F.Cu F.Paste F.Mask))
16 | (model Buttons_Switches_SMD.3dshapes/SW_SPST_PTS645.wrl
17 | (at (xyz 0 0 0))
18 | (scale (xyz 1 1 1))
19 | (rotate (xyz 0 0 0))
20 | )
21 | )
22 |
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/pcb/daughterfeet.pretty/XF2L-0625.kicad_mod:
--------------------------------------------------------------------------------
1 | (module XF2L-0625 (layer F.Cu) (tedit 58433FB4)
2 | (fp_text reference REF** (at 3.8 -1.625) (layer F.SilkS)
3 | (effects (font (size 1 1) (thickness 0.15)))
4 | )
5 | (fp_text value XF2L-0625 (at 0 6.5) (layer F.Fab) hide
6 | (effects (font (size 1 1) (thickness 0.15)))
7 | )
8 | (fp_line (start -4.5 5.5) (end 4.5 5.5) (layer F.SilkS) (width 0.4))
9 | (fp_line (start 4.5 5.5) (end 4.5 0) (layer F.SilkS) (width 0.4))
10 | (fp_line (start 4 5.5) (end -4.5 5.5) (layer F.SilkS) (width 0.4))
11 | (fp_line (start -4.5 5.5) (end -4.5 0) (layer F.SilkS) (width 0.4))
12 | (pad 0 smd rect (at 2.79 1.7) (size 2 3) (layers F.Cu F.Paste F.Mask))
13 | (pad 3 smd rect (at 0.25 -0.625 180) (size 0.3 1.25) (layers F.Cu F.Paste F.Mask))
14 | (pad 1 smd rect (at 1.25 -0.625 180) (size 0.3 1.25) (layers F.Cu F.Paste F.Mask))
15 | (pad 2 smd rect (at 0.75 -0.625 180) (size 0.3 1.25) (layers F.Cu F.Paste F.Mask))
16 | (pad 4 smd rect (at -0.25 -0.625 180) (size 0.3 1.25) (layers F.Cu F.Paste F.Mask))
17 | (pad 5 smd rect (at -0.75 -0.625 180) (size 0.3 1.25) (layers F.Cu F.Paste F.Mask))
18 | (pad 6 smd rect (at -1.25 -0.625 180) (size 0.3 1.25) (layers F.Cu F.Paste F.Mask))
19 | (pad 0 smd rect (at -2.79 1.7) (size 2 3) (layers F.Cu F.Paste F.Mask))
20 | )
21 |
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/pcb/daughterfeet.pretty/b6b-ph-kl.kicad_mod:
--------------------------------------------------------------------------------
1 | (module b6b-ph-kl (layer F.Cu)
2 | (descr "JST PH series connector, B6B-PH-KL")
3 | (fp_text reference JP*** (at 0 -2.99974) (layer F.SilkS)
4 | (effects (font (thickness 0.3048)))
5 | )
6 | (fp_text value b6b-ph-kl (at 0 4.20116) (layer F.SilkS)
7 | (effects (font (thickness 0.3048)))
8 | )
9 | (fp_line (start 7.00024 -1.69926) (end -7.00024 -1.69926) (layer F.SilkS) (width 0.381))
10 | (fp_line (start -7.00024 2.79908) (end 7.00024 2.79908) (layer F.SilkS) (width 0.381))
11 | (fp_line (start 6.49986 2.30124) (end -6.49986 2.30124) (layer F.SilkS) (width 0.381))
12 | (fp_line (start 1.89738 2.30124) (end 1.89738 1.80086) (layer F.SilkS) (width 0.381))
13 | (fp_line (start 1.89738 1.80086) (end 2.0955 1.80086) (layer F.SilkS) (width 0.381))
14 | (fp_line (start 2.0955 1.80086) (end 2.0955 2.30124) (layer F.SilkS) (width 0.381))
15 | (fp_line (start 4.09702 1.80086) (end 4.09702 2.30124) (layer F.SilkS) (width 0.381))
16 | (fp_line (start 3.8989 1.80086) (end 4.09702 1.80086) (layer F.SilkS) (width 0.381))
17 | (fp_line (start 3.8989 2.30124) (end 3.8989 1.80086) (layer F.SilkS) (width 0.381))
18 | (fp_line (start -1.90246 1.80086) (end -1.90246 2.30124) (layer F.SilkS) (width 0.381))
19 | (fp_line (start -2.10058 1.80086) (end -1.90246 1.80086) (layer F.SilkS) (width 0.381))
20 | (fp_line (start -2.10058 2.30124) (end -2.10058 1.80086) (layer F.SilkS) (width 0.381))
21 | (fp_line (start -3.90398 1.80086) (end -3.90398 2.30124) (layer F.SilkS) (width 0.381))
22 | (fp_line (start -4.1021 1.80086) (end -3.90398 1.80086) (layer F.SilkS) (width 0.381))
23 | (fp_line (start -4.1021 2.30124) (end -4.1021 1.80086) (layer F.SilkS) (width 0.381))
24 | (fp_line (start -0.1016 2.30124) (end -0.1016 1.80086) (layer F.SilkS) (width 0.381))
25 | (fp_line (start -0.1016 1.80086) (end 0.09652 1.80086) (layer F.SilkS) (width 0.381))
26 | (fp_line (start 0.09652 1.80086) (end 0.09652 2.30124) (layer F.SilkS) (width 0.381))
27 | (fp_line (start 7.00024 -0.50038) (end 6.49986 -0.50038) (layer F.SilkS) (width 0.381))
28 | (fp_line (start 6.49986 0.8001) (end 7.00024 0.8001) (layer F.SilkS) (width 0.381))
29 | (fp_line (start -6.5024 0.8001) (end -7.00278 0.8001) (layer F.SilkS) (width 0.381))
30 | (fp_line (start -6.5024 -0.50038) (end -7.00278 -0.50038) (layer F.SilkS) (width 0.381))
31 | (fp_line (start -4.50342 -1.69926) (end -4.50342 -1.19888) (layer F.SilkS) (width 0.381))
32 | (fp_line (start -4.50342 -1.19888) (end -6.5024 -1.19888) (layer F.SilkS) (width 0.381))
33 | (fp_line (start -6.5024 -1.19888) (end -6.5024 2.30124) (layer F.SilkS) (width 0.381))
34 | (fp_line (start 6.49986 2.30124) (end 6.49986 -1.19888) (layer F.SilkS) (width 0.381))
35 | (fp_line (start 6.49986 -1.19888) (end 4.50088 -1.19888) (layer F.SilkS) (width 0.381))
36 | (fp_line (start 4.50088 -1.19888) (end 4.50088 -1.69926) (layer F.SilkS) (width 0.381))
37 | (fp_line (start -7.00278 -1.69926) (end -7.00278 2.79908) (layer F.SilkS) (width 0.381))
38 | (fp_line (start 7.00024 -1.69926) (end 7.00024 2.79908) (layer F.SilkS) (width 0.381))
39 | (fp_line (start -5.30352 -1.69926) (end -5.30352 -1.89992) (layer F.SilkS) (width 0.381))
40 | (fp_line (start -5.30352 -1.89992) (end -5.60324 -1.89992) (layer F.SilkS) (width 0.381))
41 | (fp_line (start -5.60324 -1.89992) (end -5.60324 -1.69926) (layer F.SilkS) (width 0.381))
42 | (pad 1 thru_hole rect (at -5.0038 0) (size 1.19888 1.69926) (drill 0.70104) (layers *.Cu *.Mask F.SilkS))
43 | (pad 3 thru_hole oval (at -1.00076 0) (size 1.19888 1.69926) (drill 0.70104) (layers *.Cu *.Mask F.SilkS))
44 | (pad 2 thru_hole oval (at -3.00228 0) (size 1.19888 1.69926) (drill 0.70104) (layers *.Cu *.Mask F.SilkS))
45 | (pad 4 thru_hole oval (at 0.99822 0) (size 1.19888 1.69926) (drill 0.70104) (layers *.Cu *.Mask F.SilkS))
46 | (pad 5 thru_hole oval (at 2.99974 0) (size 1.19888 1.69926) (drill 0.70104) (layers *.Cu *.Mask F.SilkS))
47 | (pad 6 thru_hole oval (at 5.00126 0) (size 1.19888 1.69926) (drill 0.70104) (layers *.Cu *.Mask F.SilkS))
48 | (model walter/conn_jst-ph/b6b-ph-kl.wrl
49 | (at (xyz 0 0 0))
50 | (scale (xyz 1 1 1))
51 | (rotate (xyz 0 0 0))
52 | )
53 | )
54 |
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/pcb/fp-lib-table:
--------------------------------------------------------------------------------
1 | (fp_lib_table
2 | (lib (name daughterfeet)(type KiCad)(uri "$(KIPRJMOD)/daughterfeet.pretty")(options "")(descr ""))
3 | )
4 |
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/pcb/gui_defaults.par:
--------------------------------------------------------------------------------
1 |
2 | (gui_defaults
3 | (windows
4 | (board_frame
5 | visible
6 | (bounds
7 | 0 23 2560 1413
8 | )
9 | )
10 | (color_manager
11 | not_visible
12 | (bounds
13 | 0 600 1110 126
14 | )
15 | )
16 | (layer_visibility
17 | not_visible
18 | (bounds
19 | 0 450 354 185
20 | )
21 | )
22 | (object_visibility
23 | not_visible
24 | (bounds
25 | 0 550 370 536
26 | )
27 | )
28 | (display_miscellanious
29 | not_visible
30 | (bounds
31 | 0 350 336 342
32 | )
33 | )
34 | (snapshots
35 | not_visible
36 | (bounds
37 | 0 250 214 267
38 | )
39 | )
40 | (select_parameter
41 | not_visible
42 | (bounds
43 | 583 352 356 464
44 | )
45 | )
46 | (route_parameter
47 | not_visible
48 | (bounds
49 | 0 100 356 567
50 | )
51 | )
52 | (manual_rules
53 | not_visible
54 | (bounds
55 | 0 2 356 205
56 | )
57 | )
58 | (route_details
59 | not_visible
60 | (bounds
61 | 0 2 356 248
62 | )
63 | )
64 | (move_parameter
65 | not_visible
66 | (bounds
67 | 0 50 412 146
68 | )
69 | )
70 | (clearance_matrix
71 | not_visible
72 | (bounds
73 | 0 150 760 304
74 | )
75 | )
76 | (via_rules
77 | not_visible
78 | (bounds
79 | 50 150 496 459
80 | )
81 | )
82 | (edit_vias
83 | not_visible
84 | (bounds
85 | 100 150 404 145
86 | )
87 | )
88 | (edit_net_rules
89 | not_visible
90 | (bounds
91 | 100 200 904 145
92 | )
93 | )
94 | (assign_net_rules
95 | not_visible
96 | (bounds
97 | 100 250 219 362
98 | )
99 | )
100 | (padstack_info
101 | not_visible
102 | (bounds
103 | 100 23 0 0
104 | )
105 | )
106 | (package_info
107 | not_visible
108 | (bounds
109 | 200 23 0 0
110 | )
111 | )
112 | (component_info
113 | not_visible
114 | (bounds
115 | 300 23 0 0
116 | )
117 | )
118 | (net_info
119 | not_visible
120 | (bounds
121 | 350 30 0 0
122 | )
123 | )
124 | (incompletes_info
125 | not_visible
126 | (bounds
127 | 400 23 0 0
128 | )
129 | )
130 | (violations_info
131 | not_visible
132 | (bounds
133 | 500 23 0 0
134 | )
135 | )
136 | )
137 | (colors
138 | (background
139 | 255 255 255
140 | )
141 | (hilight 1.0
142 | 0 255 0
143 | )
144 | (incompletes 1.0
145 | 51 255 255
146 | )
147 | (outline
148 | 100 150 255
149 | )
150 | (component_front
151 | 153 153 255
152 | )
153 | (component_back
154 | 255 153 153
155 | )
156 | (violations
157 | 255 0 255
158 | )
159 | (length_matching 1.0
160 | 0 255 0
161 | )
162 | (traces 1.0
163 | 255 0 0
164 | 0 0 255
165 | )
166 | (fixed_traces 1.0
167 | 255 0 0
168 | 0 0 255
169 | )
170 | (vias 1.0
171 | 102 153 0
172 | 102 153 0
173 | )
174 | (fixed_vias 1.0
175 | 200 200 0
176 | 200 200 0
177 | )
178 | (pins 1.0
179 | 150 50 0
180 | 160 80 0
181 | )
182 | (conduction 1.0
183 | 255 255 255
184 | 100 100 0
185 | )
186 | (keepout 1.0
187 | 0 110 110
188 | 0 100 160
189 | )
190 | (via_keepout 1.0
191 | 100 100 100
192 | 100 100 100
193 | )
194 | )
195 | (parameter
196 | (selection_layers
197 | all_visible
198 | )
199 | (selectable_items
200 | TRACES VIAS PINS FIXED UNFIXED
201 | )
202 | (via_snap_to_smd_center
203 | on
204 | )
205 | (route_mode
206 | dynamic
207 | )
208 | (shove_enabled
209 | on
210 | )
211 | (drag_components_enabled
212 | on
213 | )
214 | (hilight_routing_obstacle
215 | off
216 | )
217 | (pull_tight_region
218 | 2147483647
219 | )
220 | (pull_tight_accuracy
221 | 500
222 | )
223 | (clearance_compensation
224 | off
225 | )
226 | (ignore_conduction_areas
227 | on
228 | )
229 | (automatic_layer_dimming
230 | 0.7
231 | )
232 | (deselected_snapshot_attributes
233 | )
234 | )
235 | )
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/pcb/io_daughterboard.pro:
--------------------------------------------------------------------------------
1 | update=Thursday, November 17, 2016 'PMt' 11:30:31 PM
2 | version=1
3 | last_client=kicad
4 | [pcbnew]
5 | version=1
6 | LastNetListRead=
7 | UseCmpFile=1
8 | PadDrill=0.600000000000
9 | PadDrillOvalY=0.600000000000
10 | PadSizeH=1.500000000000
11 | PadSizeV=1.500000000000
12 | PcbTextSizeV=1.500000000000
13 | PcbTextSizeH=1.500000000000
14 | PcbTextThickness=0.300000000000
15 | ModuleTextSizeV=1.000000000000
16 | ModuleTextSizeH=1.000000000000
17 | ModuleTextSizeThickness=0.150000000000
18 | SolderMaskClearance=0.000000000000
19 | SolderMaskMinWidth=0.000000000000
20 | DrawSegmentWidth=0.200000000000
21 | BoardOutlineThickness=0.100000000000
22 | ModuleOutlineThickness=0.150000000000
23 | [cvpcb]
24 | version=1
25 | NetIExt=net
26 | [general]
27 | version=1
28 | [schematic_editor]
29 | version=1
30 | PageLayoutDescrFile=
31 | PlotDirectoryName=
32 | SubpartIdSeparator=0
33 | SubpartFirstId=65
34 | NetFmtName=
35 | SpiceForceRefPrefix=0
36 | SpiceUseNetNumbers=0
37 | LabSize=60
38 | [eeschema]
39 | version=1
40 | LibDir=
41 | [eeschema/libraries]
42 | LibName1=io_daughterboard-rescue
43 | LibName2=lib/bored
44 | LibName3=power
45 | LibName4=device
46 | LibName5=transistors
47 | LibName6=conn
48 | LibName7=linear
49 | LibName8=regul
50 | LibName9=74xx
51 | LibName10=cmos4000
52 | LibName11=adc-dac
53 | LibName12=memory
54 | LibName13=xilinx
55 | LibName14=microcontrollers
56 | LibName15=dsp
57 | LibName16=microchip
58 | LibName17=analog_switches
59 | LibName18=motorola
60 | LibName19=texas
61 | LibName20=intel
62 | LibName21=audio
63 | LibName22=interface
64 | LibName23=digital-audio
65 | LibName24=philips
66 | LibName25=display
67 | LibName26=cypress
68 | LibName27=siliconi
69 | LibName28=opto
70 | LibName29=atmel
71 | LibName30=contrib
72 | LibName31=valves
73 |
--------------------------------------------------------------------------------
/ECAD/io_daughterboard/pcb/lib/bored.dcm:
--------------------------------------------------------------------------------
1 | EESchema-DOCLIB Version 2.0
2 | #
3 | $CMP Button
4 | D Button
5 | K Switch
6 | $ENDCMP
7 | #
8 | #End Doc Library
9 |
--------------------------------------------------------------------------------
/ECAD/modules/DRILEGEND.CFG:
--------------------------------------------------------------------------------
1 | InputUserCfg = 1
2 | SymbolLayer = 144
3 | SymbolSize = 40
4 | SymbolWidth = 4
5 | TextSize = 70.0000
6 | TextRatio = 5
7 | IdxFnt = 0
8 | decMM = 2
9 | decMIL = 0
10 | SortHoles = 1
11 | TolPlated = 0.02
12 | TolNonPlated = 0.03
13 | PlatedStatusNot = NOT
14 | PlatedStatusBoth = BOTH
15 | PlatedStatusYes = YES
16 | VerticalChart = 1
17 | HighCellFactor = 1.10
18 | WideCellFactor = 1.10
19 | CellOutline = 4
20 | TitleOutline = 4
21 | TableOutline = 8
22 | SymbTitle = Sym
23 | ToolTitle = N°
24 | MMTitle = MM
25 | MilTitle = Mils
26 | MicTitle = Mic
27 | QtyTitle = Qty
28 | TypeTitle = Plated
29 | ToleTitle = Tol
30 | SymbRank = 1
31 | ToolRank = 2
32 | MMRank = 4
33 | MilRank = 3
34 | MicRank = 0
35 | QtyRank = 5
36 | TypeRank = 6
37 | ToleRank = 0
38 | OutputDrillRack = 0
39 | DrillRackFile = DRILLRACK.DRL
40 | Unit = 0
41 | OutputUserCfg = 1
42 | UserCfgFile = DRILEGEND.CFG
43 |
--------------------------------------------------------------------------------
/ECAD/modules/disembiggen.py:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env python
2 |
3 | from decimal import Decimal
4 | import fileinput
5 | import re
6 |
7 |
8 | # Pattern matches all XML attributes that are X coordinates,
9 | # e.g., x1="12.34"
10 | disembiggen_ = re.compile(r'\b(x\d?)="(.*?)"').sub
11 |
12 |
13 | # Decimal constants. We use decimal to prevent loss of precision
14 | # reading and writing numbers.
15 | d0_5 = Decimal('0.5')
16 | d3_5 = Decimal('3.5')
17 |
18 |
19 | # Replace any X coordinate with the corresponding coordinate on the
20 | # shrunken board. Undisembiggenated panels are 25 mm. Shrunken
21 | # panels are 21.5 mm.
22 | def unrighten(m):
23 | s = m.group(2)
24 | try:
25 | n = Decimal(s)
26 | except ValueError:
27 | return m.group(0)
28 | panel = n // 25
29 | if panel > 0:
30 | n -= (panel + d0_5) * d3_5
31 | return '%s="%s"' % (m.group(1), n)
32 | return m.group(0)
33 |
34 |
35 | # Find and replace all x coordinates in a single page of XML.
36 | def disembiggen(line):
37 | return disembiggen_(unrighten, line)
38 |
39 |
40 | for line in fileinput.input():
41 | line = line.rstrip('\n')
42 | print(disembiggen(line))
43 |
--------------------------------------------------------------------------------
/ECAD/modules/embiggen-filter.py:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env python
2 |
3 | from decimal import Decimal
4 | import fileinput
5 | import re
6 |
7 |
8 | # Pattern matches all XML attributes that are X coordinates,
9 | # e.g., x1="12.34"
10 | embiggen_ = re.compile(r'\b(x\d?)="(.*?)"').sub
11 |
12 | type_x = {'22.3',
13 | '22.8333375',
14 | '23.000003125',
15 | '23.33338125',
16 | '23.5',
17 | '24.5',
18 | '24.50005',
19 | '26'}
20 |
21 | cr_x = {'37.29', '38.75', '45.25', '46.71'}
22 | rd_x = {'57.79', '59.25', '65.75', '67.21'}
23 | dk_x = {'78.29', '79.75', '86.25', '36.79'}
24 |
25 | current_x = [0,
26 | 31.75 - 10.75,
27 | 52.25 - 10.75,
28 | 72.75 - 10.75,
29 | 93.25 - 10.75]
30 |
31 | desired_x = [0,
32 | 626/3 - 184,
33 | 700/3 - 184,
34 | 258 - 184,
35 | 559/2 - 184]
36 |
37 | delta = [b - a for (a, b) in zip(current_x, desired_x)]
38 |
39 | # cutoff_offset = 24+2/3 - 21
40 | # resonance_offset = 49+1/3 - 41.5
41 | # drive_offset = 74 - 62
42 | # keytrack_offset = 97.5 - 82.6
43 |
44 | # print('C', cutoff_offset)
45 | # print('R', resonance_offset)
46 | # print('D', drive_offset)
47 | # print('K', keytrack_offset)
48 | # print()
49 |
50 | cutoff_offset = delta[1]
51 | resonance_offset = delta[2]
52 | drive_offset = delta[3]
53 | keytrack_offset = delta[4]
54 |
55 | # print('C', cutoff_offset)
56 | # print('R', resonance_offset)
57 | # print('D', drive_offset)
58 | # print('K', keytrack_offset)
59 | # print()
60 |
61 | cr_offset = (cutoff_offset + resonance_offset) / 2
62 | rd_offset = (resonance_offset + drive_offset) / 2
63 | dk_offset = (drive_offset + keytrack_offset) / 2
64 |
65 | # Replace any X coordinate with the corresponding coordinate on the
66 | # enlarged board. Disembiggenated panels are 25 mm. Shrunken
67 | # panels are 21.5 mm.
68 | def unleften(m):
69 | s = m.group(2)
70 | try:
71 | x = float(s)
72 | except ValueError:
73 | return m.group(0)
74 |
75 | if s in type_x:
76 | return m.group(0)
77 | elif s in cr_x:
78 | x += cr_offset
79 | elif s in rd_x:
80 | x += rd_offset
81 | elif s in dk_x:
82 | x += dk_offset
83 | elif x < 22: # Type
84 | return m.group(0)
85 | elif x < 41: # Cutoff
86 | x += cutoff_offset
87 | elif x < 43:
88 | x += cr_offset
89 | elif x < 62: # Resonance
90 | x += resonance_offset
91 | elif x < 63:
92 | x += rd_offset
93 | elif x < 82: # Drive
94 | x += drive_offset
95 | elif x < 84:
96 | x += dk_offset
97 | elif x < 112:
98 | x += keytrack_offset
99 | else:
100 | return m.group(0)
101 | return '%s="%s"' % (m.group(1), x)
102 |
103 |
104 | # Find and replace all x coordinates in a single page of XML.
105 | def embiggen(line):
106 | return embiggen_(unleften, line)
107 |
108 |
109 | for line in fileinput.input(openhook=fileinput.hook_encoded('utf-8')):
110 | line = line.rstrip('\n')
111 | print(embiggen(line))
112 |
--------------------------------------------------------------------------------
/ECAD/modules/embiggen-normal.py:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env python
2 |
3 | from decimal import Decimal
4 | import fileinput
5 | import re
6 |
7 |
8 | # Pattern matches all XML attributes that are X coordinates,
9 | # e.g., x1="12.34"
10 | embiggen_ = re.compile(r'\b(x\d?)="(.*?)"').sub
11 |
12 | type_x = {'22.3',
13 | '22.8333375',
14 | '23.000003125',
15 | '23.33338125',
16 | '23.5',
17 | '24.5',
18 | '24.50005',
19 | '26'}
20 |
21 | cr_x = {'37.29', '38.75', '45.25', '46.71'}
22 | rd_x = {'57.79', '59.25', '65.75', '67.21'}
23 | dk_x = {'78.29', '79.75', '86.25', '36.79'}
24 |
25 | current_x = [0,
26 | 31.75 - 10.75,
27 | 52.25 - 10.75,
28 | 72.75 - 10.75,
29 | 93.25 - 10.75]
30 |
31 | desired_x = [21.5 * i for i in range(5)]
32 |
33 | delta = [b - a for (a, b) in zip(current_x, desired_x)]
34 |
35 | # cutoff_offset = 24+2/3 - 21
36 | # resonance_offset = 49+1/3 - 41.5
37 | # drive_offset = 74 - 62
38 | # keytrack_offset = 97.5 - 82.6
39 |
40 | # print('C', cutoff_offset)
41 | # print('R', resonance_offset)
42 | # print('D', drive_offset)
43 | # print('K', keytrack_offset)
44 | # print()
45 |
46 | cutoff_offset = delta[1]
47 | resonance_offset = delta[2]
48 | drive_offset = delta[3]
49 | keytrack_offset = delta[4]
50 |
51 | # print('C', cutoff_offset)
52 | # print('R', resonance_offset)
53 | # print('D', drive_offset)
54 | # print('K', keytrack_offset)
55 | # print()
56 |
57 | cr_offset = (cutoff_offset + resonance_offset) / 2
58 | rd_offset = (resonance_offset + drive_offset) / 2
59 | dk_offset = (drive_offset + keytrack_offset) / 2
60 |
61 | # Replace any X coordinate with the corresponding coordinate on the
62 | # enlarged board. Disembiggenated panels are 25 mm. Shrunken
63 | # panels are 21.5 mm.
64 | def unleften(m):
65 | s = m.group(2)
66 | try:
67 | x = float(s)
68 | except ValueError:
69 | return m.group(0)
70 |
71 | if s in type_x:
72 | return m.group(0)
73 | elif s in cr_x:
74 | x += cr_offset
75 | elif s in rd_x:
76 | x += rd_offset
77 | elif s in dk_x:
78 | x += dk_offset
79 | elif x < 22: # Type
80 | return m.group(0)
81 | elif x < 41: # Cutoff
82 | x += cutoff_offset
83 | elif x < 43:
84 | x += cr_offset
85 | elif x < 62: # Resonance
86 | x += resonance_offset
87 | elif x < 63:
88 | x += rd_offset
89 | elif x < 82: # Drive
90 | x += drive_offset
91 | elif x < 84:
92 | x += dk_offset
93 | elif x < 112:
94 | x += keytrack_offset
95 | else:
96 | return m.group(0)
97 | return '%s="%s"' % (m.group(1), x)
98 |
99 |
100 | # Find and replace all x coordinates in a single page of XML.
101 | def embiggen(line):
102 | return embiggen_(unleften, line)
103 |
104 |
105 | for line in fileinput.input(openhook=fileinput.hook_encoded('utf-8')):
106 | line = line.rstrip('\n')
107 | print(embiggen(line))
108 |
--------------------------------------------------------------------------------
/Firmware/Master/Graphics/Color Text Sample.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Firmware/Master/Graphics/Color Text Sample.png
--------------------------------------------------------------------------------
/Firmware/Master/Graphics/Color Text Sample.rtf:
--------------------------------------------------------------------------------
1 | {\rtf1\ansi\ansicpg1252\cocoartf1348\cocoasubrtf170
2 | {\fonttbl\f0\fnil\fcharset0 Lato-Light;}
3 | {\colortbl;\red255\green255\blue255;\red254\green209\blue100;\red14\green0\blue45;\red250\green170\blue14;
4 | \red211\green0\blue255;\red21\green164\blue217;\red252\green22\blue95;\red144\green232\blue7;\red154\green82\blue255;
5 | \red250\green166\blue14;}
6 | \margl1440\margr1440\vieww15780\viewh10300\viewkind0
7 | \pard\tx720\tx1440\tx2160\tx2880\tx3600\tx4320\tx5040\tx5760\tx6480\tx7200\tx7920\tx8640\sl336\slmult1\pardirnatural\qc
8 |
9 | \f0\fs24 \cf2 \cb3 \
10 | \
11 | \cf4 Grumpy wizards make \cf5 \cb3 toxic brew\cf4 \cb3 for the evil\cf2 \cf6 Queen\cf2 \cf4 and\cf2 \cf7 Jack\cf2 .\
12 |
13 | \fs28 \cf4 Grumpy wizards make \cf5 toxic brew\cf4 for the evil\cf2 \cf6 Queen\cf2 \cf4 and\cf2 \cf7 Jack\cf2 .\
14 | \pard\tx720\tx1440\tx2160\tx2880\tx3600\tx4320\tx5040\tx5760\tx6480\tx7200\tx7920\tx8640\sl336\slmult1\pardirnatural\qc
15 |
16 | \fs36 \cf4 \cb3 Grumpy wizards make \cf5 \cb3 toxic brew\cf4 \cb3 for the evil\cf2 \cb3 \cf6 Queen\cf2 \cf4 \cb3 and\cf2 \cb3 \cf7 Jack\cf2 .\
17 |
18 | \fs48 \cf8 \cb3 Grumpy\cf4 \cb3 wizards make \cf5 toxic brew\cf4 for the evil\cf2 \cf6 Queen\cf2 \cf4 and\cf2 \cf7 Jack\cf2 .\
19 | \pard\tx720\tx1440\tx2160\tx2880\tx3600\tx4320\tx5040\tx5760\tx6480\tx7200\tx7920\tx8640\pardirnatural\qc
20 |
21 | \fs28 \cf2 \
22 |
23 | \fs72 \cf9 Grumpy\cf10 wizards make\cf2 \cf5 toxic brew\cf2 \cf10 for the evil\cf2 \cf6 \cb3 Queen\cf2 \cb3 \cf10 and\cf2 \cf7 Jack\cf2 .\
24 |
25 | \fs36 \
26 |
27 | \fs96 \cf4 Grumpy wizards make \cf5 toxic brew\cf4 for the evil\cf2 \cf6 Queen\cf2 \cf4 and\cf2 \cf7 Jack\cf2 .}
--------------------------------------------------------------------------------
/Firmware/Master/Graphics/Color Text Sample.xcf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Firmware/Master/Graphics/Color Text Sample.xcf
--------------------------------------------------------------------------------
/Firmware/Master/Graphics/compile.py:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env python3
2 |
3 | from collections import defaultdict
4 | import itertools
5 | import PIL.Image
6 | import pprint
7 |
8 | # Simple Run-Length Encoding
9 | #
10 | # First byte determines run encoding.
11 | # 0 -> single pixel, RGB = next 3 bytes
12 | # 1..127 -> run of 1..127 pixels, RGB = next 3 bytes
13 | # 128..254 -> N = 2nd byte; run of (a - 128) << 8 | N pixels, RGB = next 3
14 | # 255-> N = 2nd byte; run of N pixels, each a different R G B.
15 |
16 | im = PIL.Image.open('Color Text Sample.png')
17 | data = im.getdata()
18 | pixels = (pix[:3] for pix in data)
19 | runs = ((len(list(run)), pix) for pix, run in itertools.groupby(pixels))
20 | lenruns = ((l, [run[1] for run in runs])
21 | for l, runs in itertools.groupby(runs, lambda lp: lp[0]))
22 |
23 | def dbg(*args):
24 | pass
25 |
26 | def emit_bytes(lenruns):
27 | for (count, runs) in lenruns:
28 | if count == 1 and len(runs) == 1:
29 | # Single pixel
30 | dbg('single', count, len(runs))
31 | yield 0
32 | dbg(' pix', runs[0])
33 | yield from runs[0]
34 | elif count == 1:
35 | # Run of different pixels
36 | dbg('mixed ', count, len(runs))
37 | yield 255
38 | assert 1 < len(runs) < 256
39 | yield len(runs)
40 | for pix in runs:
41 | yield from pix
42 | elif count < 128:
43 | # Short run of solid color
44 | dbg('short ', count, len(runs))
45 | assert len(runs) == 1
46 | yield count
47 | yield from runs[0]
48 | elif count <= 127 * 256:
49 | # Long run of solid color
50 | dbg('long ', count, len(runs))
51 | dbg(' ', runs[0])
52 | assert len(runs) == 1
53 | yield count >> 8 | 128
54 | yield count & 0xFF
55 | yield from runs[0]
56 | else:
57 | # Several long runs of solid color
58 | dbg('split ', count)
59 | assert len(runs) == 1
60 | while count:
61 | scount = min(count, 127 * 256 - 1)
62 | dbg('call', runs)
63 | yield from emit_bytes(((scount, runs),))
64 | dbg('return')
65 | count -= scount
66 |
67 | # Testing, write bin file
68 | bi = list(emit_bytes(lenruns))
69 | bb = bytes(bi)
70 | # bb = bytes(emit_bytes(lenruns))
71 | with open('foo.bin', 'wb') as out:
72 | out.write(bb)
73 |
74 | def isplit(s, n):
75 | z = []
76 | for i, x in enumerate(s):
77 | z.append(x)
78 | if i % n == n - 1:
79 | yield z
80 | z = []
81 | if z:
82 | yield z
83 |
84 | preamble = '''
85 | /* Automatically generated by compile.py. Do not edit. */
86 |
87 | #include
88 | '''.lstrip()
89 |
90 | postamble = '};'
91 |
92 | with open('foo.h', 'w') as out:
93 | print(preamble, file=out)
94 | print('#define IMG_WIDTH %d' % im.size[0], file=out)
95 | print('#define IMG_HEIGHT %d' % im.size[1], file=out)
96 | print(file=out)
97 | print('uint8_t img_data[] = {', file=out)
98 | for x in isplit(bi, 12):
99 | print(' ' + ', '.join('%3d' % i for i in x) + ',', file=out)
100 | print(postamble, file=out)
101 |
--------------------------------------------------------------------------------
/Firmware/Master/Graphics/show.py:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env python3
2 |
3 | import PIL.Image
4 |
5 | with open('foo.bin', 'rb') as infile:
6 | bb = infile.read()
7 |
8 | def dbg(*args):
9 | pass
10 |
11 | def bytes_to_pix(bb):
12 | i = 0
13 | while i < len(bb):
14 | op = bb[i]; i += 1
15 | if op == 0:
16 | dbg('single', op)
17 | pix = bb[i:i+3]; i += 3
18 | yield pix
19 | elif op < 128:
20 | dbg('short ', op)
21 | pix = bb[i:i+3]; i += 3
22 | for j in range(op):
23 | yield pix
24 | elif op < 255:
25 | op2 = bb[i]; i += 1
26 | count = (op & ~128) << 8 | op2
27 | dbg('long ', count)
28 | pix = bb[i:i+3]; i += 3
29 | for j in range(count):
30 | yield pix
31 | else:
32 | assert op == 255
33 | op2 = bb[i]; i += 1
34 | dbg('mixed', op2)
35 | for j in range(op2):
36 | pix = bb[i:i+3]; i += 3
37 | yield pix
38 |
39 |
40 | def pix_to_ints(pixen):
41 | for pix in pixen:
42 | yield tuple(pix)
43 |
44 | im = PIL.Image.new('RGBA', (800, 480))
45 |
46 | for i, pix in enumerate(pix_to_ints(bytes_to_pix(bb))):
47 | row = i // 800
48 | col = i % 800
49 | assert 0 <= pix[0] < 256
50 | assert 0 <= pix[1] < 256
51 | assert 0 <= pix[2] < 256, 'pix = %r' % (pix,)
52 | color = pix + (0xFF,)
53 | im.putpixel((col, row), color)
54 |
55 |
56 | im.show()
57 |
--------------------------------------------------------------------------------
/Firmware/Master/reference/README.md:
--------------------------------------------------------------------------------
1 | This is a spreadsheet in Apple Numbers format. (Proprietary, but I
2 | like it.)
3 |
4 | Each SPI bus's signals can be mapped to several pins. Those are
5 | recorded.
6 |
7 | The 144 pin chip does not bring out pins PH2 and above. Those are
8 | shaded red.
9 |
10 | Most of the pins are connected to a peripheral on the STM32F429IDISCOVERY
11 | board. The pins that are not used are shaded blue in the spreadsheet.
12 | Some, but not all, of the used pins are labeled in the Discovery column.
13 |
14 | The notes column shows how I plan to use the pins, especially the
15 | SPI slave select pins.
16 |
17 |
18 |
--------------------------------------------------------------------------------
/Firmware/Master/reference/STM32F429i-Discovery Pin Mapping.numbers:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Firmware/Master/reference/STM32F429i-Discovery Pin Mapping.numbers
--------------------------------------------------------------------------------
/Firmware/Master/reference/STM32F429i-Discovery Pin Mapping.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Firmware/Master/reference/STM32F429i-Discovery Pin Mapping.pdf
--------------------------------------------------------------------------------
/Firmware/Master/src/.gdbinit:
--------------------------------------------------------------------------------
1 | # # First Discovery board
2 | # target extended-remote /dev/cu.usbmodemBED9D9E1
3 |
4 | # # Second Discovery board
5 | target extended-remote /dev/cu.usbmodemBED6C011
6 |
7 | # Black Magic Probe Mini, v1
8 | # target extended-remote /dev/cu.usbmodemBDEAA9F1
9 |
10 | monitor swdp_scan
11 | attach 1
12 |
13 | # set target-async on
14 | set confirm off
15 | set mem inaccessible-by-default off
16 |
17 | define lc
18 | load
19 | continue
20 | end
21 | define lr
22 | load
23 | run
24 | end
25 |
--------------------------------------------------------------------------------
/Firmware/Master/src/Makefile:
--------------------------------------------------------------------------------
1 | LIBOPENCM3 = ../libopencm3
2 | ifeq '$(LIBOPENCM3)' ''
3 | $(error Please pass LIBOPENCM3 = the root of your libopencm3 tree)
4 | endif
5 |
6 | ########################################################################
7 | SOURCES := main.c anim.c button.c config.c console.c delay.c gpio.c \
8 | lcd-dma.c lcd-pwm.c midi.c modes.c sdram.c spi.c \
9 | spi-proto.c spi-responder.c state.c systick.c usb-midi.c
10 | CFILES := $(filter %.c, $(SOURCES))
11 | OFILES := $(CFILES:%.c=%.o)
12 |
13 | L3_INCDIR := $(LIBOPENCM3)/include
14 | L3_LIBDIR := $(LIBOPENCM3)/lib
15 |
16 | CC := arm-none-eabi-gcc
17 |
18 | DEFS := -DSTM32F4 -D_GNU_SOURCE
19 | FP_FLAGS := -mfloat-abi=hard -mfpu=fpv4-sp-d16
20 | ARCH_FLAGS := -mthumb -mcpu=cortex-m4 $(FP_FLAGS)
21 |
22 | CPPFLAGS := -MD -I$(L3_INCDIR) $(DEFS)
23 | CFLAGS := -std=gnu99 -g -Wall -Wundef -Werror \
24 | -fno-common -ffunction-sections -fdata-sections \
25 | $(CPPFLAGS) $(ARCH_FLAGS) \
26 | -O0
27 | LDFLAGS := -g --static -nostartfiles \
28 | -L$(L3_LIBDIR) \
29 | -T stm32f429i-discovery.ld \
30 | -Wl,-Map=master.map -Wl,--gc-sections \
31 | $(ARCH_FLAGS)
32 | LDLIBES := -lopencm3_stm32f4
33 | LDLIBS := -Wl,--start-group -lc -lgcc -lnosys -Wl,--end-group
34 |
35 |
36 | default: master.elf
37 |
38 | master.elf: $(OFILES)
39 | $(LINK.o) $^ $(LDLIBES) $(LDLIBS) -o $@
40 |
41 | clean:
42 | rm -f *.d *.o *.elf *.map TAGS
43 |
44 | tags:
45 | make-etags-SimplicityStudio $(LIBOPENCM3)/lib/stm32/f4/*.c $$(strings "$(LIBOPENCM3)/lib/libopencm3_stm32f4.a" | sed -n -E "s,^(\.\./common|\.\./\.\./usb)/.*\.c\$$,$(LIBOPENCM3)/lib/stm32/f4/&,p")
46 |
47 |
48 | ifeq '$(filter clean$ help,$(or $(MAKECMDGOALS),help))' ''
49 | -include $(CFILES:%.c=%.d)
50 | endif
51 |
52 | .PHONY: default clean tags
53 |
--------------------------------------------------------------------------------
/Firmware/Master/src/anim.h:
--------------------------------------------------------------------------------
1 | #ifndef ANIM_included
2 | #define ANIM_included
3 |
4 | #include
5 | #include
6 |
7 | typedef uint32_t packed_RGB;
8 |
9 | extern void anim_update(uint32_t msec);
10 |
11 | extern packed_RGB anim_module_color(size_t module_index);
12 | extern packed_RGB anim_knob_color(size_t module_index, size_t knob_index);
13 | extern uint8_t anim_choice_brightness(size_t module_index);
14 | extern uint8_t anim_assign_brightness(size_t module_index);
15 |
16 | #endif /* !ANIM_included */
17 |
--------------------------------------------------------------------------------
/Firmware/Master/src/button.c:
--------------------------------------------------------------------------------
1 | #include "button.h"
2 |
3 | #include "gpio.h"
4 | #include "midi.h"
5 |
6 | static const gpio_pin button_gpio = {
7 | .gp_port = GPIOA,
8 | .gp_pin = GPIO0,
9 | .gp_mode = GPIO_MODE_INPUT,
10 | .gp_pupd = GPIO_PUPD_NONE, // board has external pulldown resistor R22.
11 | };
12 |
13 | void button_setup(void)
14 | {
15 | /* Button pin */
16 | gpio_init_pin(&button_gpio);
17 | }
18 |
19 | void button_poll(void)
20 | {
21 | static uint32_t button_state = 0;
22 |
23 | /* This is a simple shift based debounce. It's simplistic because
24 | * although this implements debounce adequately it does not have any
25 | * noise suppression. It is also very wide (32-bits) because it can
26 | * be polled in a very tight loop (no debounce timer).
27 | */
28 | uint32_t old_button_state = button_state;
29 | button_state = (button_state << 1) | (GPIOA_IDR & 1);
30 | if (!button_state != !old_button_state) {
31 | static const uint8_t note_sequence[] = { 60, 64, 69, 62, 67 };
32 | static size_t i, j;
33 | uint8_t note = note_sequence[i];
34 | if (j == 5)
35 | note -= 36;
36 | if (button_state)
37 | MIDI_send_note_on(MIDI_default_channel, note, 96);
38 | else {
39 | MIDI_send_note_off(MIDI_default_channel, note, 96);
40 | i = (i + 1) % sizeof note_sequence;
41 | j = (j + 1) % 6;
42 | }
43 | }
44 | }
45 |
--------------------------------------------------------------------------------
/Firmware/Master/src/button.h:
--------------------------------------------------------------------------------
1 | #ifndef BUTTON_included
2 | #define BUTTON_included
3 |
4 | extern void button_setup(void);
5 | extern void button_poll(void);
6 |
7 | #endif /* !BUTTON_included */
8 |
--------------------------------------------------------------------------------
/Firmware/Master/src/console.c:
--------------------------------------------------------------------------------
1 | #include "console.h"
2 |
3 | #include
4 |
5 | #include
6 | #include
7 |
8 | #include "gpio.h"
9 |
10 | #define CONSOLE_UART USART1
11 | #define CONSOLE_BAUD 115200
12 |
13 | static const gpio_pin usart1_pins[] = {
14 | { // PA9 = TX
15 | .gp_port = GPIOA,
16 | .gp_pin = GPIO9,
17 | .gp_mode = GPIO_MODE_AF,
18 | .gp_pupd = GPIO_PUPD_NONE,
19 | .gp_af = GPIO_AF7,
20 | },
21 | { // PA10 = RX
22 | .gp_port = GPIOA,
23 | .gp_pin = GPIO10,
24 | .gp_mode = GPIO_MODE_AF,
25 | .gp_pupd = GPIO_PUPD_NONE,
26 | .gp_af = GPIO_AF7,
27 | },
28 | };
29 | const size_t usart1_pin_count = (&usart1_pins)[1] - usart1_pins;
30 |
31 | void console_setup(void)
32 | {
33 | // Clock
34 | rcc_periph_clock_enable(RCC_USART1);
35 |
36 | // GPIO
37 | gpio_init_pins(usart1_pins, usart1_pin_count);
38 |
39 | // USART
40 | usart_set_baudrate(CONSOLE_UART, CONSOLE_BAUD);
41 | usart_set_databits(CONSOLE_UART, 8);
42 | usart_set_stopbits(CONSOLE_UART, USART_STOPBITS_1);
43 | usart_set_mode(CONSOLE_UART, USART_MODE_TX_RX);
44 | usart_set_parity(CONSOLE_UART, USART_PARITY_NONE);
45 | usart_set_flow_control(CONSOLE_UART, USART_FLOWCONTROL_NONE);
46 | usart_enable(CONSOLE_UART);
47 | }
48 |
49 | static void console_putc(char c)
50 | {
51 | while (!(USART_SR(CONSOLE_UART) & USART_SR_TXE))
52 | continue;
53 | USART_DR(CONSOLE_UART) = (uint8_t)c;
54 | }
55 |
56 | static ssize_t console_write(void *cookie, const char *buf, size_t size)
57 | {
58 | for (size_t i = 0; i < size; i++) {
59 | char c = buf[i];
60 | if (c == '\n')
61 | console_putc('\r');
62 | console_putc(c);
63 | }
64 | return size;
65 | }
66 |
67 | void console_stdio_setup(void)
68 | {
69 | cookie_io_functions_t console_input_fns = {
70 | .read = NULL,
71 | .write = NULL,
72 | .seek = NULL,
73 | .close = NULL
74 | };
75 | cookie_io_functions_t console_output_fns = {
76 | .read = NULL,
77 | .write = console_write,
78 | .seek = NULL,
79 | .close = NULL
80 | };
81 | stdin = fopencookie(NULL, "r", console_input_fns);
82 | stdout = fopencookie(NULL, "w", console_output_fns);
83 | stderr = fopencookie(NULL, "w", console_output_fns);
84 | setlinebuf(stdout);
85 | setbuf(stderr, NULL);
86 | }
87 |
--------------------------------------------------------------------------------
/Firmware/Master/src/console.h:
--------------------------------------------------------------------------------
1 | #ifndef CONSOLE_included
2 | #define CONSOLE_included
3 |
4 | extern void console_setup(void);
5 | extern void console_stdio_setup(void);
6 |
7 | #endif /* !CONSOLE_included */
8 |
--------------------------------------------------------------------------------
/Firmware/Master/src/delay.c:
--------------------------------------------------------------------------------
1 | #include "delay.h"
2 |
3 | #include "systick.h"
4 |
5 | // If compiled with no optimization (-O0), delay_loop uses 19 cycles
6 | // per iteration. With optimization (-O3), it uses 4 cycles.
7 |
8 | #define FAST_CYCLES 4
9 | #define SLOW_CYCLES 19
10 | #define uSEC_per_SEC 1000000
11 |
12 | static uint32_t delay_scale;
13 |
14 | static inline void delay_loop(uint32_t count)
15 | {
16 | while (count--)
17 | __asm__ volatile ( "nop" );
18 | }
19 |
20 | void init_delay(uint32_t cpu_freq)
21 | {
22 | // Assume fast.
23 | delay_scale = cpu_freq / FAST_CYCLES / uSEC_per_SEC;
24 |
25 | // Test.
26 | uint32_t b = system_millis;
27 | delay_loop(1000 * delay_scale);
28 | uint32_t a = system_millis;
29 |
30 | if (a - b >= 2) {
31 | // Slow.
32 | delay_scale = cpu_freq / SLOW_CYCLES / uSEC_per_SEC;
33 | }
34 | }
35 |
36 | void delay_usec(uint32_t count)
37 | {
38 | delay_loop(count * delay_scale);
39 | }
40 |
--------------------------------------------------------------------------------
/Firmware/Master/src/delay.h:
--------------------------------------------------------------------------------
1 | #ifndef DELAY_included
2 | #define DELAY_included
3 |
4 | #include
5 |
6 | extern void init_delay(uint32_t cpu_freq);
7 |
8 | extern void delay_usec(uint32_t count);
9 |
10 | #endif /* !DELAY_included */
11 |
--------------------------------------------------------------------------------
/Firmware/Master/src/gpio.c:
--------------------------------------------------------------------------------
1 | #include "gpio.h"
2 |
3 | #include
4 | #include
5 |
6 | #include
7 |
8 | #define GPIO_PORT_COUNT 11
9 |
10 | static uint16_t gpio_pins_used[GPIO_PORT_COUNT];
11 |
12 | void gpio_init_pin(const gpio_pin *pin)
13 | {
14 | uint32_t port = pin->gp_port;
15 | uint16_t pinmask = pin->gp_pin;
16 | uint32_t index = ((uint32_t)port - (uint32_t)PERIPH_BASE_AHB1) >> 10;
17 | assert(index < GPIO_PORT_COUNT);
18 |
19 | if (!gpio_pins_used[index])
20 | rcc_periph_clock_enable((0x30 << 5) | index);
21 |
22 | assert(!(gpio_pins_used[index] & pinmask));
23 | gpio_pins_used[index] |= pinmask;
24 |
25 | gpio_mode_setup(port,
26 | pin->gp_mode,
27 | pin->gp_pupd,
28 | pinmask);
29 |
30 | if (pin->gp_mode == GPIO_MODE_OUTPUT) {
31 | if (pin->gp_level)
32 | gpio_set(port, pinmask);
33 | else
34 | gpio_clear(port, pinmask);
35 | }
36 |
37 | if (pin->gp_mode == GPIO_MODE_OUTPUT || pin->gp_mode == GPIO_MODE_AF)
38 | gpio_set_output_options(port,
39 | pin->gp_otype,
40 | pin->gp_ospeed,
41 | pinmask);
42 |
43 | if (pin->gp_mode == GPIO_MODE_AF)
44 | gpio_set_af(port,
45 | pin->gp_af,
46 | pinmask);
47 | }
48 |
49 | void gpio_init_pins(const gpio_pin *pins, size_t count)
50 | {
51 | for (size_t i = 0; i < count; i++)
52 | gpio_init_pin(&pins[i]);
53 | }
54 |
--------------------------------------------------------------------------------
/Firmware/Master/src/gpio.h:
--------------------------------------------------------------------------------
1 | #ifndef GPIO_included
2 | #define GPIO_included
3 |
4 | #include
5 |
6 | #include
7 |
8 | typedef struct gpio_pin {
9 | uint32_t gp_port; // GPIOA .. GPIOF
10 | uint16_t gp_pin; // GPIO0 .. GPIO15
11 | uint8_t gp_mode : 2; // GPIO_MODE_INPUT/OUTPUT/AF/ANALOG
12 | uint8_t gp_pupd : 2; // GPIO_PUPD_NONE/PULLUP/PULLDOWN
13 | uint8_t gp_af : 4; // GPIO_AF0 .. GPIO_AF15
14 | uint8_t gp_ospeed : 2; // GPIO_OSPEED_2/25/60/100MHZ
15 | uint8_t gp_otype : 1; // GPIO_OTYPE_PP/OD (push-pull, open drain)
16 | uint8_t gp_level : 1; // 0 or 1
17 | } gpio_pin;
18 |
19 | extern void gpio_init_pin(const gpio_pin *);
20 |
21 | extern void gpio_init_pins(const gpio_pin *, size_t count);
22 |
23 | #endif /* !GPIO_included */
24 |
--------------------------------------------------------------------------------
/Firmware/Master/src/lcd-dma.h:
--------------------------------------------------------------------------------
1 | #ifndef LCD_DMA_included
2 | #define LCD_DMA_included
3 |
4 | extern void lcd_dma_setup(void);
5 |
6 | #endif /* !LCD_DMA_included */
7 |
--------------------------------------------------------------------------------
/Firmware/Master/src/lcd-pwm.c:
--------------------------------------------------------------------------------
1 | #include "lcd-pwm.h"
2 |
3 | #include
4 | #include
5 |
6 | #include "gpio.h"
7 |
8 | // PWM brightness pin
9 | // Pin PF6
10 | // Timer TIM10, channel 1
11 | // Alt function AF3
12 |
13 | // Display On/Off pin
14 | // Pin PE4
15 |
16 |
17 | #define PWM_PORT GPIOF
18 | #define PWM_PIN GPIO6
19 | #define DISP_PORT GPIOE
20 | #define DISP_PIN GPIO4
21 |
22 | static const gpio_pin lcd_pwm_pins[] = {
23 | {
24 | .gp_port = PWM_PORT,
25 | .gp_pin = PWM_PIN,
26 | .gp_mode = GPIO_MODE_AF,
27 | .gp_af = GPIO_AF3,
28 | },
29 | {
30 | .gp_port = DISP_PORT,
31 | .gp_pin = DISP_PIN,
32 | .gp_mode = GPIO_MODE_OUTPUT,
33 | .gp_level = 0,
34 | },
35 | };
36 | static const size_t lcd_pwm_pin_count = (&lcd_pwm_pins)[1] - lcd_pwm_pins;
37 |
38 | void lcd_pwm_setup(void)
39 | {
40 | // enable clock
41 | rcc_periph_clock_enable(RCC_TIM10);
42 |
43 | // init GPIOs
44 | gpio_init_pins(lcd_pwm_pins, lcd_pwm_pin_count);
45 |
46 | // configure timer
47 | timer_reset(TIM10);
48 | // timer_set_mode(TIM10, TIM_CR1_CKD_INT, TIM_CR1_CMS_EDGE, TIM_CR1_DIR_UP);
49 | timer_set_oc_mode(TIM10, TIM_OC1, TIM_OCM_PWM1);
50 | timer_enable_oc_output(TIM10, TIM_OC1);
51 | timer_set_oc_value(TIM10, TIM_OC1, 0); // start out dark.
52 | // XXX FAN5333BSX datasheet says PWM frequency not to exceed 1 KHz.
53 | // 168 MHz / 65536 / 3 ~= 854 Hz.
54 | timer_set_period(TIM10, 65536 - 1);
55 | timer_set_prescaler(TIM10, 3 - 1);
56 | timer_enable_counter(TIM10);
57 | }
58 |
59 | void lcd_pwm_set_brightness(uint16_t brightness)
60 | {
61 | timer_set_oc_value(TIM10, TIM_OC1, brightness);
62 | if (brightness)
63 | gpio_set(DISP_PORT, DISP_PIN);
64 | else
65 | gpio_clear(DISP_PORT, DISP_PIN);
66 | }
67 |
--------------------------------------------------------------------------------
/Firmware/Master/src/lcd-pwm.h:
--------------------------------------------------------------------------------
1 | #ifndef LCD_PWM_included
2 | #define LCD_PWM_included
3 |
4 | #include
5 |
6 | extern void lcd_pwm_setup(void);
7 |
8 | extern void lcd_pwm_set_brightness(uint16_t brightness);
9 |
10 | #endif /* !LCD_PWM_included */
11 |
--------------------------------------------------------------------------------
/Firmware/Master/src/main.c:
--------------------------------------------------------------------------------
1 | #include
2 | #include
3 |
4 | #include
5 |
6 | #include "button.h"
7 | #include "console.h"
8 | #include "delay.h"
9 | #include "lcd-dma.h"
10 | #include "lcd-pwm.h"
11 | #include "midi.h"
12 | #include "sdram.h"
13 | #include "spi.h"
14 | #include "spi-proto.h"
15 | #include "spi-responder.h"
16 | #include "state.h"
17 | #include "systick.h"
18 | #include "usb-midi.h"
19 |
20 | #define REPORT_INTERVAL_MSEC 10000
21 |
22 | #define CPU_FREQ 168000000
23 | // #define CPU_FREQ 120000000
24 | // #define CPU_FREQ 48000000
25 |
26 | static void clock_setup(void)
27 | {
28 | if (CPU_FREQ == 168000000) {
29 | // CPU = 168 MHz, min SPI =~ 328 KHz
30 | rcc_clock_setup_hse_3v3(&rcc_hse_8mhz_3v3[RCC_CLOCK_3V3_168MHZ]);
31 | } else if (CPU_FREQ == 120000000) {
32 | // CPU = 120 MHz, min SPI =~ 234 KHz
33 | rcc_clock_setup_hse_3v3(&rcc_hse_8mhz_3v3[RCC_CLOCK_3V3_120MHZ]);
34 | } else if (CPU_FREQ == 48000000) {
35 | // CPU = 48 MHz, min SPI =~ 94 KHz
36 | rcc_clock_setup_hse_3v3(&rcc_hse_8mhz_3v3[RCC_CLOCK_3V3_48MHZ]);
37 | }
38 | }
39 |
40 | static void adjust_LCD_brightness(uint32_t now)
41 | {
42 | static bool done;
43 | if (done)
44 | return;
45 | static uint32_t t0;
46 | if (!t0) {
47 | t0 = now + 1;
48 | return;
49 | }
50 | uint32_t b0 = (now - t0);
51 | uint32_t b1 = b0 * (b0 + 1) >> 5;
52 | if (b1 > 65535) {
53 | b1 = 65535;
54 | done = true;
55 | }
56 | lcd_pwm_set_brightness(b1);
57 | }
58 |
59 | int main()
60 | {
61 | clock_setup();
62 | systick_setup(CPU_FREQ);
63 | lcd_pwm_setup(); // Do this early to keep the uninitialized screen dark.
64 | console_setup();
65 | console_stdio_setup();
66 | MIDI_setup();
67 | usb_midi_setup();
68 | button_setup();
69 | spi_setup();
70 | SPI_proto_setup();
71 | SPI_responder_setup();
72 | sdram_setup();
73 | lcd_dma_setup();
74 | init_delay(CPU_FREQ);
75 |
76 | printf("\n");
77 | printf("Minimum Viable Firmware\n");
78 |
79 | #ifndef NDEBUG
80 | verify_config();
81 | printf("OK\n");
82 | #endif
83 |
84 | uint32_t next_time = REPORT_INTERVAL_MSEC;
85 |
86 | while (1) {
87 | adjust_LCD_brightness(system_millis);
88 | usb_midi_poll();
89 | button_poll();
90 |
91 | if ((int32_t)(next_time - system_millis) > 0)
92 | continue;
93 | next_time += REPORT_INTERVAL_MSEC;
94 |
95 | SPI_proto_report_and_clear_stats();
96 | // USB_midi_report_and_clear_stats();
97 | }
98 | return 0;
99 | }
100 |
--------------------------------------------------------------------------------
/Firmware/Master/src/midi-defs.h:
--------------------------------------------------------------------------------
1 | #ifndef MIDI_DEFS_included
2 | #define MIDI_DEFS_included
3 |
4 | typedef enum MIDI_status_nybble {
5 | NoteOff = 0x80,
6 | NoteOn = 0x90,
7 | PolyPress = 0xA0,
8 | ControlChange = 0xB0,
9 | ProgramChange = 0xC0,
10 | ChannelPressure = 0xD0,
11 | PitchBend = 0xE0,
12 | SystemCommon = 0xF0,
13 | } MIDI_status_nybble;
14 |
15 | #endif /* !MIDI_DEFS_included */
16 |
--------------------------------------------------------------------------------
/Firmware/Master/src/modes.h:
--------------------------------------------------------------------------------
1 | #ifndef MODES_included
2 | #define MODES_included
3 |
4 | #include
5 | #include
6 | #include
7 |
8 | #define ASSIGN_TIMEOUT_MSEC 2500
9 | #define CONFIRM_TIMEOUT_MSEC 500
10 |
11 |
12 | // Query current/active modules and current/working knobs
13 |
14 | extern bool module_is_current(size_t module_index);
15 | extern bool module_is_active(size_t module_index);
16 | extern bool knob_is_current(size_t module_index, size_t knob_index);
17 | extern bool knob_is_working(size_t module_index, size_t knob_index);
18 |
19 |
20 | // Query assignment state
21 |
22 | extern bool source_is_assigned(size_t module_index);
23 |
24 | extern bool assignment_is_active(void);
25 | extern bool assignment_is_confirmed(void);
26 | extern bool module_is_active_assign_source(size_t module_index);
27 | extern bool knob_is_active_assign_dest(size_t module_index, size_t knob_index);
28 | extern bool knob_is_assign_dest(size_t module_index, size_t knob_index);
29 | extern uint32_t assignment_start_time(void);
30 |
31 | extern size_t active_source_mod_index(void);
32 | extern size_t active_dest_mod_index(void);
33 | extern size_t active_dest_knob_index(void);
34 |
35 |
36 | // Assignment mode control
37 |
38 | extern void begin_assignment(size_t src_mod_index);
39 | extern void confirm_assignment(size_t dest_mod_index, size_t dest_knob_index);
40 | extern void cancel_assignment(void);
41 |
42 |
43 | // Current module/knob control
44 |
45 | extern void set_current_knob(size_t module_index, size_t knob_index);
46 |
47 | #endif /* !MODES_included */
48 |
--------------------------------------------------------------------------------
/Firmware/Master/src/sdram.h:
--------------------------------------------------------------------------------
1 | #ifndef SDRAM_included
2 | #define SDRAM_included
3 |
4 | #define SDRAM_BASE_ADDRESS 0xd0000000
5 |
6 | void sdram_setup(void);
7 |
8 | // variable attribute to put global/static variables into SDRAM.
9 | // SDRAM is initialized to zero, so don't use with initialized variables.
10 | #define SDRAM_SECTION __attribute((section(".sdram")))
11 |
12 | #endif /* !SDRAM_included */
13 |
--------------------------------------------------------------------------------
/Firmware/Master/src/spi-proto.h:
--------------------------------------------------------------------------------
1 | #ifndef SPI_PROTO_included
2 | #define SPI_PROTO_included
3 |
4 | #include
5 | #include
6 | #include
7 |
8 | #include "config.h"
9 |
10 | static const int NO_GROUP = -1;
11 | static const int NO_BUS = -1;
12 |
13 | typedef enum ss_button_bit {
14 | SBB_CHOICE = 1 << 0,
15 | SBB_ASSIGN = 1 << 1,
16 | SBB_DEST_1 = 1 << 2,
17 | SBB_DEST_2 = 1 << 3,
18 | SBB_DEST_3 = 1 << 4,
19 | SBB_DEST_4 = 1 << 5,
20 | } ss_button_bit;
21 |
22 | typedef struct slave_state {
23 | bool ss_is_valid;
24 | uint8_t ss_buttons; // ss_button_bit
25 | uint8_t ss_analog_mask;
26 | uint8_t ss_analog_values[MAX_KNOBS];
27 | } slave_state;
28 |
29 | typedef void SPI_slave_state_handler(size_t module_index,
30 | slave_state const *,
31 | void *user_data);
32 |
33 | extern void SPI_proto_setup(void);
34 | extern void SPI_proto_register_slave_state_handler(SPI_slave_state_handler *,
35 | void *user_data);
36 | extern void SPI_proto_report_and_clear_stats(void);
37 |
38 | // Use these like this:
39 | //
40 | // for (i = 0; (g = active_spi_groups(i)) != NO_GROUP; i++) {
41 | // for (j = 0; (b = active_spi_buses(g, j)) != NO_BUS; j++) {
42 | // size_t m = spi_to_module(g, b);
43 | // do something with module m, group g, bus b.
44 | // }
45 | // }
46 |
47 | extern int active_spi_groups(uint8_t index);
48 | extern int active_spi_buses(uint8_t group, uint8_t index);
49 | extern size_t spi_to_module(int spi_group, int spi_bus);
50 |
51 | #endif /* !SPI_PROTO_included */
52 |
--------------------------------------------------------------------------------
/Firmware/Master/src/spi-responder.h:
--------------------------------------------------------------------------------
1 | #ifndef SPI_RESPONDER_included
2 | #define SPI_RESPONDER_included
3 |
4 | extern void SPI_responder_setup(void);
5 |
6 | #endif /* !SPI_RESPONDER_included */
7 |
--------------------------------------------------------------------------------
/Firmware/Master/src/spi.h:
--------------------------------------------------------------------------------
1 | #ifndef SPI_included
2 | #define SPI_included
3 |
4 | #include
5 | #include
6 |
7 | #define SPI_GROUP_COUNT 3
8 | #define SPI_BUS_RANGE 7 // bus numbers are [1 .. RANGE)
9 | #define SPI_BUS_COUNT 4 // four buses actually in use
10 |
11 | typedef void spi_completion_handler(void);
12 |
13 | extern void spi_setup(void);
14 | extern void spi_register_completion_handler(spi_completion_handler *);
15 |
16 | extern void spi_select_group(int group);
17 | extern void spi_deselect_group(int group);
18 |
19 | extern void spi_start_transfer(int spi,
20 | uint8_t const *tx_buf,
21 | uint8_t *rx_buf,
22 | size_t count);
23 |
24 | extern void spi_finish_transfer(int spi);
25 |
26 | #endif /* !SPI_included */
27 |
--------------------------------------------------------------------------------
/Firmware/Master/src/state.h:
--------------------------------------------------------------------------------
1 | #ifndef STATE_included
2 | #define STATE_included
3 |
4 | #include "config.h"
5 |
6 | typedef enum LED_pattern {
7 | LP_OFF,
8 | LP_ACTIVE,
9 | LP_CURRENT_DEST,
10 | LP_AVAIL_DEST,
11 | } LED_pattern;
12 |
13 | typedef struct choice_state {
14 | // const choice_config *cs_config;
15 | uint8_t cs_value;
16 | } choice_state;
17 |
18 | typedef struct knob_state {
19 | uint16_t ks_exported_value;
20 | uint16_t ks_actual_value;
21 | bool ks_should_export;
22 | } knob_state;
23 |
24 | typedef struct assign_state {
25 | uint8_t as_index;
26 | } assign_state;
27 |
28 | typedef struct module_state {
29 | bool ms_is_active;
30 | LED_pattern ms_LED_pattern;
31 | choice_state ms_choice;
32 | knob_state ms_knobs[MAX_KNOBS];
33 | assign_state ms_assign;
34 | } module_state;
35 |
36 | typedef struct synth_state {
37 | char *ss_preset_name;
38 | int ss_preset_number;
39 | uint8_t ss_MIDI_channel;
40 | module_state ss_modules[MODULE_COUNT];
41 | } synth_state;
42 |
43 | extern synth_state ss;
44 |
45 | extern void init_synth_state(void);
46 |
47 | #endif /* !STATE_included */
48 |
--------------------------------------------------------------------------------
/Firmware/Master/src/stm32f429i-discovery.ld:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of the libopencm3 project.
3 | *
4 | * Copyright (C) 2009 Uwe Hermann
5 | * Copyright (C) 2011 Stephen Caudle
6 | * Copyright (C) 2015 Piotr Esden-Tempski
7 | *
8 | * This library is free software: you can redistribute it and/or modify
9 | * it under the terms of the GNU Lesser General Public License as published by
10 | * the Free Software Foundation, either version 3 of the License, or
11 | * (at your option) any later version.
12 | *
13 | * This library is distributed in the hope that it will be useful,
14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 | * GNU Lesser General Public License for more details.
17 | *
18 | * You should have received a copy of the GNU Lesser General Public License
19 | * along with this library. If not, see .
20 | */
21 |
22 | /* Linker script for ST STM32F429IDISCOVERY (STM32F429ZI, 2048K flash, 256K RAM). */
23 |
24 | /* Define memory regions. */
25 | MEMORY
26 | {
27 | rom (rx) : ORIGIN = 0x08000000, LENGTH = 2048K
28 | ram (rwx) : ORIGIN = 0x10000000, LENGTH = 64K /* (kbob) CCM is faster */
29 | system_ram (rwx) : ORIGIN = 0x20000000, LENGTH = 128K
30 | sdram (rwx) : ORIGIN = 0xD0000000, LENGTH = 8M
31 | }
32 |
33 | SECTIONS
34 | {
35 | .system_ram (NOLOAD) : {
36 | *(.system_ram)
37 | } >system_ram
38 | .sdram (NOLOAD) : {
39 | *(.sdram)
40 | } >sdram
41 | }
42 | /* Include the common ld script. */
43 | INCLUDE libopencm3_stm32f4.ld
44 |
--------------------------------------------------------------------------------
/Firmware/Master/src/systick.c:
--------------------------------------------------------------------------------
1 | #include "systick.h"
2 |
3 | #include
4 |
5 | #include
6 |
7 | volatile uint32_t system_millis;
8 | static systick_handler *current_handler;
9 |
10 | // This is the systick_isr.
11 | void sys_tick_handler(void)
12 | {
13 | system_millis++;
14 | if (current_handler)
15 | (*current_handler)(system_millis);
16 | }
17 |
18 | void systick_setup(uint32_t cpu_freq)
19 | {
20 | // set tick rate to 1 KHz.
21 | systick_set_reload(cpu_freq / 1000);
22 | systick_set_clocksource(STK_CSR_CLKSOURCE_AHB);
23 | systick_counter_enable();
24 | systick_interrupt_enable();
25 | }
26 |
27 | extern void register_systick_handler(systick_handler *handler)
28 | {
29 | assert(!current_handler);
30 | current_handler = handler;
31 | }
32 |
33 |
--------------------------------------------------------------------------------
/Firmware/Master/src/systick.h:
--------------------------------------------------------------------------------
1 | #ifndef SYSTICK_included
2 | #define SYSTICK_included
3 |
4 | #include
5 |
6 | typedef void systick_handler(uint32_t millis);
7 |
8 | extern volatile uint32_t system_millis;
9 |
10 | extern void systick_setup(uint32_t cpu_freq);
11 |
12 | extern void register_systick_handler(systick_handler *);
13 |
14 | #endif /* !SYSTICK_included */
15 |
--------------------------------------------------------------------------------
/Firmware/Master/src/usb-midi.h:
--------------------------------------------------------------------------------
1 | #ifndef USB_MIDI_included
2 | #define USB_MIDI_included
3 |
4 | #include // XXX
5 | #include
6 | #include
7 |
8 | typedef void usb_midi_packet_handler(uint8_t *pkt, size_t size, void *user_data);
9 |
10 | extern void usb_midi_setup(void);
11 |
12 | extern void usb_midi_poll(void);
13 |
14 | extern void usb_midi_send_message(uint8_t const *msg, size_t size);
15 |
16 | extern void usb_midi_report_and_clear_stats(void);
17 |
18 | #endif /* !USB_MIDI_included */
19 |
--------------------------------------------------------------------------------
/Firmware/Slave/stats.txt:
--------------------------------------------------------------------------------
1 | LEDs off, no caps
2 |
3 | Hello from Slave: 3738978
4 |
5 | 0: n=3333 min=0 max=65531 mean=65483 dev=12.89
6 | 1: n=3333 min=0 max=65535 mean=65482 dev=15.19
7 |
8 | 0: n=3333 min=65432 max=65534 mean=65483 dev=13.16
9 | 1: n=3333 min=65415 max=65535 mean=65481 dev=13.88
10 |
11 | 0: n=3333 min=65408 max=65535 mean=65483 dev=13.23
12 | 1: n=3333 min=65408 max=65535 mean=65482 dev=14.46
13 |
14 | 0: n=3333 min=65428 max=65535 mean=65484 dev=13.00
15 | 1: n=3333 min=65414 max=65535 mean=65482 dev=14.25
16 |
17 | 0: n=2731 min=33762 max=65530 mean=44002 dev=14268.42
18 | 1: n=2731 min=30571 max=65534 mean=43253 dev=15158.56
19 |
20 | 0: n=2322 min=33415 max=34279 mean=33855 dev=91.85
21 | 1: n=2322 min=30572 max=30822 mean=30701 dev=30.31
22 |
23 | 0: n=2401 min=33780 max=34297 mean=33868 dev=83.49
24 | 1: n=2401 min=30563 max=30823 mean=30703 dev=30.66
25 |
26 | 0: n=2301 min=33447 max=34281 mean=33863 dev=89.75
27 | 1: n=2301 min=30571 max=30821 mean=30707 dev=31.19
28 |
29 | 0: n=3011 min=4 max=34106 mean=4617 dev=11548.28
30 | 1: n=3011 min=4 max=30803 mean=4168 dev=10437.96
31 |
32 | 0: n=3333 min=4 max=70 mean=7 dev=8.28
33 | 1: n=3333 min=4 max=128 mean=8 dev=11.13
34 |
35 | 0: n=3333 min=4 max=67 mean=7 dev=8.16
36 | 1: n=3333 min=4 max=127 mean=8 dev=11.31
37 |
38 | 0: n=3333 min=4 max=86 mean=7 dev=8.09
39 | 1: n=3333 min=4 max=106 mean=9 dev=11.58
40 |
41 |
42 | ----------------------------------
43 | LEDs Amber, no caps
44 |
45 | Hello from Slave: 3144479
46 |
47 | 0: n=3333 min=0 max=65535 mean=65485 dev=13.31
48 | 1: n=3333 min=0 max=65535 mean=65483 dev=14.36
49 |
50 | 0: n=3333 min=65407 max=65535 mean=65485 dev=13.34
51 | 1: n=3333 min=65404 max=65535 mean=65482 dev=14.45
52 |
53 | 0: n=3333 min=65404 max=65535 mean=65485 dev=13.16
54 | 1: n=3333 min=65405 max=65535 mean=65483 dev=13.80
55 |
56 | 0: n=3334 min=65404 max=65535 mean=65486 dev=13.11
57 | 1: n=3334 min=65401 max=65535 mean=65482 dev=14.31
58 |
59 | 0: n=2968 min=24713 max=65535 mean=47780 dev=18515.05
60 | 1: n=2968 min=25663 max=65535 mean=56509 dev=15757.36
61 |
62 | 0: n=2712 min=30341 max=31209 mean=30754 dev=85.28
63 | 1: n=2712 min=25711 max=25989 mean=25848 dev=30.89
64 |
65 | 0: n=2917 min=30426 max=31197 mean=30771 dev=72.69
66 | 1: n=2917 min=25713 max=25955 mean=25845 dev=30.61
67 |
68 | 0: n=2743 min=30343 max=31187 mean=30754 dev=76.50
69 | 1: n=2743 min=25698 max=25951 mean=25846 dev=29.74
70 |
71 | 0: n=3184 min=6 max=31202 mean=6443 dev=12449.11
72 | 1: n=3184 min=6 max=25941 mean=7310 dev=11590.15
73 |
74 | 0: n=3333 min=6 max=191 mean=13 dev=10.70
75 | 1: n=3333 min=6 max=148 mean=15 dev=12.70
76 |
77 | 0: n=3333 min=6 max=123 mean=13 dev=12.15
78 | 1: n=3333 min=6 max=169 mean=15 dev=14.08
79 |
80 | 0: n=3333 min=6 max=128 mean=13 dev=10.19
81 | 1: n=3333 min=6 max=151 mean=16 dev=14.97
82 |
83 |
--------------------------------------------------------------------------------
/Front Panel/archive/Lato-Light.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Front Panel/archive/Lato-Light.ttf
--------------------------------------------------------------------------------
/Front Panel/archive/bob-synth-0.2.zip:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Front Panel/archive/bob-synth-0.2.zip
--------------------------------------------------------------------------------
/Front Panel/archive/bob-synth-0.3.zip:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Front Panel/archive/bob-synth-0.3.zip
--------------------------------------------------------------------------------
/Front Panel/archive/bob-synth-0.4.zip:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Front Panel/archive/bob-synth-0.4.zip
--------------------------------------------------------------------------------
/Front Panel/archive/bob-synth-both-0.1.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Front Panel/archive/bob-synth-both-0.1.pdf
--------------------------------------------------------------------------------
/Front Panel/archive/bob-synth-cut-0.2.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Front Panel/archive/bob-synth-cut-0.2.pdf
--------------------------------------------------------------------------------
/Front Panel/archive/bob-synth-detail-all-0.3.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Front Panel/archive/bob-synth-detail-all-0.3.pdf
--------------------------------------------------------------------------------
/Front Panel/archive/bob-synth-detail-all-0.4.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Front Panel/archive/bob-synth-detail-all-0.4.pdf
--------------------------------------------------------------------------------
/Front Panel/archive/bob-synth-detail-allvec-0.3.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Front Panel/archive/bob-synth-detail-allvec-0.3.pdf
--------------------------------------------------------------------------------
/Front Panel/archive/bob-synth-detail-allvec-0.4.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Front Panel/archive/bob-synth-detail-allvec-0.4.pdf
--------------------------------------------------------------------------------
/Front Panel/archive/bob-synth-detail-art-0.3.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Front Panel/archive/bob-synth-detail-art-0.3.pdf
--------------------------------------------------------------------------------
/Front Panel/archive/bob-synth-detail-art-0.4.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Front Panel/archive/bob-synth-detail-art-0.4.pdf
--------------------------------------------------------------------------------
/Front Panel/archive/bob-synth-detail-both-0.1.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Front Panel/archive/bob-synth-detail-both-0.1.pdf
--------------------------------------------------------------------------------
/Front Panel/archive/bob-synth-detail-cut-0.3.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Front Panel/archive/bob-synth-detail-cut-0.3.pdf
--------------------------------------------------------------------------------
/Front Panel/archive/bob-synth-detail-cut-0.4.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Front Panel/archive/bob-synth-detail-cut-0.4.pdf
--------------------------------------------------------------------------------
/Front Panel/archive/bob-synth-detail-engrave-0.3.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Front Panel/archive/bob-synth-detail-engrave-0.3.pdf
--------------------------------------------------------------------------------
/Front Panel/archive/bob-synth-detail-engrave-0.4.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Front Panel/archive/bob-synth-detail-engrave-0.4.pdf
--------------------------------------------------------------------------------
/Front Panel/archive/bob-synth-detail-somevec-0.3.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Front Panel/archive/bob-synth-detail-somevec-0.3.pdf
--------------------------------------------------------------------------------
/Front Panel/archive/bob-synth-detail-somevec-0.4.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Front Panel/archive/bob-synth-detail-somevec-0.4.pdf
--------------------------------------------------------------------------------
/Front Panel/archive/bob-synth-engrave-0.2.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Front Panel/archive/bob-synth-engrave-0.2.pdf
--------------------------------------------------------------------------------
/Front Panel/archive/bob-synth-full-all-0.3.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Front Panel/archive/bob-synth-full-all-0.3.pdf
--------------------------------------------------------------------------------
/Front Panel/archive/bob-synth-full-all-0.4.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Front Panel/archive/bob-synth-full-all-0.4.pdf
--------------------------------------------------------------------------------
/Front Panel/archive/bob-synth-full-allvec-0.3.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Front Panel/archive/bob-synth-full-allvec-0.3.pdf
--------------------------------------------------------------------------------
/Front Panel/archive/bob-synth-full-allvec-0.4.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Front Panel/archive/bob-synth-full-allvec-0.4.pdf
--------------------------------------------------------------------------------
/Front Panel/archive/bob-synth-full-art-0.3.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Front Panel/archive/bob-synth-full-art-0.3.pdf
--------------------------------------------------------------------------------
/Front Panel/archive/bob-synth-full-art-0.4.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Front Panel/archive/bob-synth-full-art-0.4.pdf
--------------------------------------------------------------------------------
/Front Panel/archive/bob-synth-full-cut-0.3.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Front Panel/archive/bob-synth-full-cut-0.3.pdf
--------------------------------------------------------------------------------
/Front Panel/archive/bob-synth-full-cut-0.4.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Front Panel/archive/bob-synth-full-cut-0.4.pdf
--------------------------------------------------------------------------------
/Front Panel/archive/bob-synth-full-engrave-0.3.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Front Panel/archive/bob-synth-full-engrave-0.3.pdf
--------------------------------------------------------------------------------
/Front Panel/archive/bob-synth-full-engrave-0.4.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Front Panel/archive/bob-synth-full-engrave-0.4.pdf
--------------------------------------------------------------------------------
/Front Panel/archive/bob-synth-full-somevec-0.3.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Front Panel/archive/bob-synth-full-somevec-0.3.pdf
--------------------------------------------------------------------------------
/Front Panel/archive/bob-synth-full-somevec-0.4.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Front Panel/archive/bob-synth-full-somevec-0.4.pdf
--------------------------------------------------------------------------------
/Front Panel/archive/jupiter.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/Front Panel/archive/jupiter.ttf
--------------------------------------------------------------------------------
/Front Panel/render-all:
--------------------------------------------------------------------------------
1 | #!/bin/sh
2 |
3 | # VERSION=0.5
4 | PRE=bob-synth-
5 | POST="${VERSION+-${VERSION}}.pdf"
6 |
7 | all="--outline=all --engrave --cut"
8 |
9 | R="python synth-dsl.py"
10 | # R="echo $R"
11 |
12 | function render {
13 | echo $R "$@"
14 | $R "$@"
15 | }
16 |
17 | render -o "${PRE}full-art${POST}"
18 | render --flip --outline=all -o "${PRE}full-allvec${POST}"
19 | render --flip --outline=vec -o "${PRE}full-somevec${POST}"
20 | render --flip --engrave -o "${PRE}full-engrave${POST}"
21 | render --flip --cut -o "${PRE}full-cut${POST}"
22 | render --flip ${all} -o "${PRE}full-all${POST}"
23 |
24 | render --detail -o "${PRE}detail-art${POST}"
25 | render --detail --flip --outline=all -o "${PRE}detail-allvec${POST}"
26 | render --detail --flip --outline=vec -o "${PRE}detail-somevec${POST}"
27 | render --detail --flip --engrave -o "${PRE}detail-engrave${POST}"
28 | render --detail --flip --cut -o "${PRE}detail-cut${POST}"
29 | render --detail --flip ${all} -o "${PRE}detail-all${POST}"
30 |
--------------------------------------------------------------------------------
/MCAD/endcap.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/MCAD/endcap.pdf
--------------------------------------------------------------------------------
/MCAD/endcaps.py:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env python3.4
2 |
3 | from contextlib import contextmanager
4 | from math import cos, pi, sin
5 |
6 | from reportlab.lib.pagesizes import letter
7 | from reportlab.lib.units import inch, mm
8 | from reportlab.pdfgen import canvas
9 |
10 | ANGLE = 35
11 | CHASSIS_WIDTH = 135
12 | CHASSIS_HEIGHT = 24.5
13 | OVERHANG = 2
14 |
15 | WIDTH = CHASSIS_WIDTH + 2 * OVERHANG
16 | HEIGHT = CHASSIS_HEIGHT + 2 * OVERHANG
17 |
18 | RADIUS1 = 6.35 / 2
19 | RADIUS2 = 11 / 2
20 | SCREW_POS = [34, 100]
21 |
22 | @contextmanager
23 | def state(c):
24 | c.saveState()
25 | yield c
26 | c.restoreState()
27 |
28 | @contextmanager
29 | def path(c, stroke=1, fill=0):
30 | p = c.beginPath()
31 | yield p
32 | c.drawPath(p, stroke=stroke, fill=fill)
33 |
34 | def draw_outline(c):
35 | a = ANGLE * pi / 180
36 | y1 = HEIGHT * cos(a)
37 | p2 = (WIDTH * cos(a), y1 + WIDTH * sin(a))
38 | p3 = (p2[0] + HEIGHT * sin(a), p2[1] - y1)
39 | p4 = (p3[0], 0)
40 | c.setLineWidth(0.1)
41 | with path(c) as p:
42 | p.moveTo(0, 0)
43 | p.lineTo(0, y1)
44 | p.lineTo(*p2)
45 | p.lineTo(*p3)
46 | p.lineTo(*p4)
47 | p.lineTo(0, 0)
48 |
49 | @contextmanager
50 | def chassis_transform(c):
51 | a = ANGLE * pi / 180
52 | with state(c):
53 | c.translate(HEIGHT * sin(a), 0)
54 | c.rotate(ANGLE)
55 | c.translate(OVERHANG, OVERHANG)
56 | yield c
57 |
58 | def draw_chassis(c):
59 | with chassis_transform(c):
60 | c.setDash(2, 1)
61 | c.rect(0, 0, CHASSIS_WIDTH, CHASSIS_HEIGHT)
62 |
63 | def draw_holes(c):
64 | with chassis_transform(c):
65 | for x in SCREW_POS:
66 | with state(c):
67 | c.translate(x, CHASSIS_HEIGHT / 2)
68 | c.circle(0, 0, RADIUS1)
69 | c.circle(0, 0, RADIUS2)
70 | c.line(-15, 0, +15, 0)
71 | c.line(0, -15, 0, +15)
72 |
73 | def draw_endcap(c):
74 | with state(c):
75 | c.scale(mm, mm)
76 | c.translate(20, 20)
77 | draw_outline(c)
78 | draw_chassis(c)
79 | draw_holes(c)
80 |
81 | def draw_it_all(c):
82 | with state(c):
83 | draw_endcap(c)
84 | c.translate(8.5*inch, 11/2*inch)
85 | c.scale(-1, +1)
86 | draw_endcap(c)
87 |
88 | def render_document():
89 | output_file = 'endcap.pdf'
90 | pagesize = letter
91 | c = canvas.Canvas(output_file, pagesize=pagesize)
92 | draw_it_all(c)
93 | c.showPage()
94 | c.save()
95 |
96 | if __name__ == '__main__':
97 | render_document()
98 |
--------------------------------------------------------------------------------
/MCAD/endplug.scad:
--------------------------------------------------------------------------------
1 | eps = 0.1;
2 | X = [1, 0, 0];
3 | Y = [0, 1, 0];
4 | Z = [0, 0, 1];
5 |
6 | // left endplug
7 | L = 133;
8 | H = 20 - 3;
9 | T = 4 - 1.8;
10 | BZ = 12.5;
11 |
12 | // right endplug
13 | L = 133;
14 | T = 20;
15 | H = 20 - 3;
16 | BZ = 11;
17 |
18 | module centered_cube(dims, z=0) {
19 | translate([-dims[0]/2, -dims[1]/2, z])
20 | cube(dims);
21 | }
22 |
23 | module endplug() {
24 | difference() {
25 | centered_cube([L, 20-3, T]);
26 | for (x = [-33, +33])
27 | translate([x, BZ - H/2, T - 1.4])
28 | cylinder(d=4.9, h=3.4 + eps, $fs = 0.1);
29 | }
30 | }
31 |
32 | module washer() {
33 | $fs = 0.2;
34 | $fa = 6;
35 | difference() {
36 | cylinder(d=10, h=0.6);
37 | cylinder(d=5.4, h=5, center=true);
38 | }
39 | }
40 |
41 | endplug();
42 |
43 | // for (x = [-10, +10])
44 | // translate([x, -20, 0])
45 | // washer();
46 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # MinimumViableSynth
2 |
3 | A virtual analog synthesizer with lots of knobs and buttons.
4 |
5 | 
6 |
7 | This is a polyphonic, monotimbral, virtual analog synth. The audio
8 | engine runs as an Apple Audio Unit on a Macintosh. The control panel,
9 | shown here, will provide dedicated controls for most of the synth's
10 | functions.
11 |
12 | 
13 |
14 | The end goal is a self contained keyboard synth with knobs and buttons
15 | with the classic connections: audio out, MIDI in/out, USB MIDI in/out.
16 | I am getting there in three phases.
17 |
18 | * **Phase 1** (complete 2015-01-01): Softsynth. The audio engine
19 | runs as an Audio Unit on a Mac. It accepts MIDI messages and
20 | produces beautiful polyphonic analog sounds. Or gritty,
21 | disturbing analog sounds. It plugs in to DAW software (I use
22 | Logic Pro X).
23 |
24 | * **Phase 2** (in progress): Knobs and buttons. I am designing and
25 | building a front panel (see above) with knobs, buttons, and an LCD
26 | touchscreen. The goal is to make it as easy as possible to
27 | understand what the synth is doing at any time.
28 |
29 | * **Phase 3** (future): Stand-alone. Build an enclosure that houses
30 | a keyboard, the knob and button panel, I/O jacks, and a processor
31 | (TBD) that can run the audio engine. I'm looking at FPGAs...
32 |
33 |
34 | ## Why?
35 |
36 | Learn stuff. Music theory, DSP, PCB layout, CAD and machining, more.
37 |
38 |
39 | ## Status
40 |
41 | Check out synth-notes.txt for my thoughts as I worked things out.
42 |
43 |
44 | #### January 7, 2017:
45 |
46 | I built 8 slave modules: the LFOs, the Controllers module, the
47 | oscillators, the noise source, mixer, and filter. I've since killed
48 | the filter module, and one of the oscillators' LED has burnt out its
49 | red component. I have parts and tools to repair those; just haven't
50 | done it yet.
51 |
52 | I have working UI for the knobs and buttons. Specifically, routing
53 | between modulators and targets works, complete with lighting effects.
54 |
55 | I made an enclosure from aluminum sheet and melamine end blocks, as
56 | illustrated above. It is flimsy, though, so that needs to be re-done.
57 |
58 | I had the master, slaves, and LCD panel connected via a breadboard.
59 | The breadboard wiring got flaky, so I stopped to design a PCB. The
60 | PCB snaps onto the back of the Discovery board, It routes video to the
61 | LCD touch screen, SPI to the slaves, and serial MIDI to a future MIDI
62 | I/O board.
63 |
64 | I am currently designing the graphics for the LCD panel.
65 |
66 | (Over a year since the last update. Oops.)
67 |
68 |
69 | #### December 17, 2015:
70 |
71 | Three slave modules have been built. (LFO1, LFO2, Controllers.) All
72 | the slave module PCBs are fabricated.
73 |
74 | The master-slave communications are working over SPI. The master
75 | generates MIDI events.
76 | [I can push a button on a slave and hear its effect on the audio
77 | engine.](https://www.youtube.com/watch?v=dZsXk2Zf6Bg)
78 |
79 | I blew up one of the LFO modules, probably with static discharge. I
80 | repaired it (swapped in a new Teensy LC), and it works now. It was an
81 | ugly repair.
82 |
83 | Current tasks:
84 |
85 | + generating more MIDI events
86 | + experimenting with the LED animation
87 | + soldering up the rest of the slave modules
88 | + designing backing plates for the new slave modules
89 |
90 |
91 | #### August 14, 2015:
92 |
93 | The audio engine has been stable since January, though it does not
94 | exactly match the front panel's feature set.
95 |
96 | The front panel was fabricated in July. I used a sheet of acrylic,
97 | painted the underside black, then engraved the artwork through the
98 | paint with a laser cutter. Then the same laser cutter cut all the
99 | holes for the controls. It looks sharp, but not mass produced.
100 | I got the work done at [InHaus Fabrication](http://inhausfabrication.com/).
101 |
102 | There is a master microcontroller, an STM32F429, and each module has a
103 | slave controller, a Teensy-LC. Each slave directly drives a few
104 | knobs, buttons, and LEDs. The master will coordinate all the slaves
105 | and provide the MIDI over USB interface. I am currently writing SPI
106 | drivers for master-slave communication.
107 |
--------------------------------------------------------------------------------
/datasheets/820.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/datasheets/820.pdf
--------------------------------------------------------------------------------
/datasheets/B260009.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/datasheets/B260009.pdf
--------------------------------------------------------------------------------
/datasheets/Matrix_61.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/datasheets/Matrix_61.gif
--------------------------------------------------------------------------------
/datasheets/TL1220.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/datasheets/TL1220.pdf
--------------------------------------------------------------------------------
/datasheets/WS2812.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/datasheets/WS2812.pdf
--------------------------------------------------------------------------------
/image/Synth Panel.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/image/Synth Panel.png
--------------------------------------------------------------------------------
/image/Synth_Panel.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/image/Synth_Panel.png
--------------------------------------------------------------------------------
/image/Synth_Panel_color.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/image/Synth_Panel_color.png
--------------------------------------------------------------------------------
/image/assembly.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kbob/MinimumViableSynth/cad05a63c0aa68dd3780eeb255455a4d2f5725da/image/assembly.gif
--------------------------------------------------------------------------------