Compare commits
112 Commits
Author | SHA1 | Date |
---|---|---|
King Kévin | 4eb4a1993d | |
King Kévin | 13c5469ba2 | |
King Kévin | 2b563d3e59 | |
King Kévin | c91917f370 | |
King Kévin | 7f3c5024ad | |
King Kévin | c5b8e17fe7 | |
King Kévin | 49b61c90fd | |
King Kévin | 1e3a18c7b2 | |
King Kévin | 08382b5221 | |
King Kévin | bfec7d2523 | |
King Kévin | b12dc32618 | |
King Kévin | b7281faf20 | |
King Kévin | f45d075096 | |
King Kévin | 23dd01b03b | |
King Kévin | a9610657e4 | |
King Kévin | c241c9cfb4 | |
King Kévin | 61112471f2 | |
King Kévin | dc836b816f | |
King Kévin | b3956df5d2 | |
King Kévin | 6861b06fe4 | |
King Kévin | 55c48fbaf9 | |
King Kévin | 7cd047cf24 | |
King Kévin | f41d5e6557 | |
King Kévin | 0f2fca2479 | |
King Kévin | 6731d4e397 | |
King Kévin | efa7388363 | |
King Kévin | a822a1ae14 | |
King Kévin | 2b838e7a54 | |
King Kévin | 6e35891b90 | |
King Kévin | 5755d3a790 | |
King Kévin | 0355594851 | |
King Kévin | f9abdbdb4d | |
King Kévin | b165245ded | |
King Kévin | 338657f927 | |
King Kévin | 64cb5285b1 | |
King Kévin | beb1722f2f | |
King Kévin | 48cad88a56 | |
King Kévin | 4f25a52ca6 | |
King Kévin | 23c5dc43a1 | |
King Kévin | 9f8f01dd5d | |
King Kévin | 23b70f5697 | |
King Kévin | 37636fa6cd | |
King Kévin | d81381e0c0 | |
King Kévin | c5e6291beb | |
King Kévin | 51c6af4add | |
King Kévin | bde94d7b85 | |
King Kévin | 2988c900c8 | |
King Kévin | 94d78ddd39 | |
King Kévin | 2223168ef2 | |
King Kévin | 2b26e45092 | |
King Kévin | 11d7172ab9 | |
King Kévin | a668a7953b | |
King Kévin | 9dc2d6bbe9 | |
King Kévin | d67ac812a0 | |
King Kévin | 223f4ffdf8 | |
King Kévin | 1a37524a59 | |
King Kévin | a8b1bac321 | |
King Kévin | 5080e79de8 | |
King Kévin | 891291cc64 | |
King Kévin | e01867bf73 | |
King Kévin | f3cc67efa1 | |
King Kévin | 7a951854e2 | |
King Kévin | e5c06db27a | |
King Kévin | 9adee74626 | |
King Kévin | 97f117f52a | |
King Kévin | 578567b95d | |
King Kévin | 7b095612d8 | |
King Kévin | 89bf8ee2da | |
King Kévin | 34454bc0ad | |
King Kévin | f7c22b3bac | |
King Kévin | 4428bf9740 | |
King Kévin | a4b46c4b3b | |
King Kévin | 71377ef17d | |
King Kévin | 6b8b118f57 | |
King Kévin | 748d9caa8a | |
King Kévin | f90cc17564 | |
King Kévin | 38c017df0e | |
King Kévin | 6ca314ab20 | |
King Kévin | 43b39e512e | |
King Kévin | d1c82f8293 | |
King Kévin | 51960b929f | |
King Kévin | f7c3d5492d | |
King Kévin | 27d79fde82 | |
King Kévin | a793fce99f | |
King Kévin | 1fa95afea2 | |
King Kévin | 166e92724d | |
King Kévin | 8bc6a95643 | |
King Kévin | bc0fad1f42 | |
King Kévin | 4557640f5f | |
King Kévin | 0d7b6b19ba | |
King Kévin | 6581d18e41 | |
King Kévin | 8783935df5 | |
King Kévin | 5966ed10d8 | |
King Kévin | f026117a8b | |
King Kévin | 26f31a612c | |
King Kévin | db951d8493 | |
King Kévin | e3ebf72bcb | |
King Kévin | 62f35353d4 | |
King Kévin | 09b899a9a6 | |
King Kévin | abee832aa0 | |
King Kévin | a0ba6ce381 | |
King Kévin | b776544878 | |
King Kévin | 5ee619c0b5 | |
King Kévin | 6c51f29372 | |
King Kévin | d21265f083 | |
King Kévin | 786947f2fb | |
King Kévin | 327b1ca07e | |
King Kévin | a976e4fde0 | |
King Kévin | 60ce73cdf9 | |
King Kévin | 5fcf15b9c6 | |
King Kévin | f2304bbd82 | |
King Kévin | adc85e6281 |
|
@ -1,3 +1,3 @@
|
|||
[submodule "library"]
|
||||
path = library
|
||||
url = http://git.cuvoodoo.info/qeda_library
|
||||
url = https://git.cuvoodoo.info/kingkevin/qeda_library
|
||||
|
|
29
.qeda.yaml
29
.qeda.yaml
|
@ -4,6 +4,35 @@ config:
|
|||
densityLevel: 'N'
|
||||
lineWidth:
|
||||
silkscreen: 0.2
|
||||
polarityMark: none
|
||||
preferManufacturer: false
|
||||
smoothPadCorners: false
|
||||
library:
|
||||
- connector/barrel_dc-005-2.0
|
||||
- ic/eeprom_ft24c16a-e@p
|
||||
- mechanical/switch_hroppart_ss12f44g5
|
||||
- vreg/buck_xl2596@to263-5l
|
||||
- connector/usb-a-2.0-receptacle_c42678
|
||||
- connector/usb-b-2.0-receptacle_c46392
|
||||
- vreg/fuse_1206sfh
|
||||
- resistor/r0603
|
||||
- capacitor/c0603
|
||||
- transistor/pmos_40p05
|
||||
- transistor/nmos_bss138
|
||||
- diode/schottky_rb521s
|
||||
- diode/schottky_ss34
|
||||
- inductor/slh@1207
|
||||
- vreg/ldo_torex_xc6206@mr
|
||||
- ic/usbhub_microchip_usb2517
|
||||
- diode/tvs_st_usblc6-2@sc6
|
||||
- diode/led0805
|
||||
- capacitor/cap_radial_10mm
|
||||
- capacitor/cap_radial_6.3mm
|
||||
- capacitor/cap_radial_5mm
|
||||
- connector/header-2.54@2x3
|
||||
- oscillator/x3225
|
||||
- vreg/current-limit_mt9700
|
||||
- connector/header-2.54@1x6
|
||||
- vreg/current-limit_sy6288
|
||||
- vreg/current-limit_tj2242
|
||||
- vreg/current-limit_dio755x
|
||||
|
|
|
@ -0,0 +1,45 @@
|
|||
v2
|
||||
==
|
||||
|
||||
this has major fixes for version 1:
|
||||
|
||||
- missing crystal resistor
|
||||
- 3.3V dip using larger capacitor
|
||||
- 6-40V feedback
|
||||
- DFP over-current
|
||||
|
||||
v1
|
||||
==
|
||||
|
||||
this is a complete re- board layout.
|
||||
it does not fit an off-the selves enclosure anymore.
|
||||
all SMD parts are on one side to allow easier SMT assembly.
|
||||
|
||||
fixes:
|
||||
|
||||
- 6-40V power input activated when UFP is connected
|
||||
- use current limit on DFP (prevents USB to reset when DFP is shorted)
|
||||
- 6-40V power input capacitor now lays down
|
||||
- remove copper plane under crystal to prevent impedance error
|
||||
|
||||
errors:
|
||||
|
||||
- crystal still does not start
|
||||
- none of the two possible OCS inputs (Dx04 XOR Dx05) work
|
||||
- power dip causes reset when enabling all 7 DFP power outputs at once
|
||||
|
||||
v0
|
||||
==
|
||||
|
||||
this version has been designed to fit in a 100x60x25mm enclosure.
|
||||
this makes it very compact, and not all surface mount parts fit on one side.
|
||||
this is not too much of an issue since it's a hand soldered prototype.
|
||||
|
||||
the prototype mostly works, with a couple of small errors:
|
||||
|
||||
- 6-40V power input is not activated unless the hub is already powered (through USB or 5V input)
|
||||
- crystal oscillator doesn't always start. I think the underlying copper plane skewed the impedance/capacitance too much
|
||||
- USB-A footprint has inverted pinout: just solder it on the other side and don't swap the data pins in the EEPROM configuration
|
||||
- fuse on downstream port is not fast enough to prevent shorts and causes the hub to reset
|
||||
- 6-40V power input capacitor is too tall and does not fit in the case
|
||||
- one of the LEDS on port 3 is misplaced
|
|
@ -0,0 +1,96 @@
|
|||
this will describe how to generate the output files form the sources.
|
||||
|
||||
requirements
|
||||
============
|
||||
|
||||
to be able to generate the outputs you need following software:
|
||||
|
||||
- rake: the central script taking care of generating the output files (Makefile is too cumbersome to parse files)
|
||||
- [QEDA](http://qeda.org/): to generate footprints for the parts
|
||||
- [Lepton EDA](https://github.com/lepton-eda/lepton-eda): for the schematic capture
|
||||
- [pcb-rnd](http://repo.hu/projects/pcb-rnd/): for the board layout
|
||||
the output generation is automatized.
|
||||
|
||||
compiling
|
||||
=========
|
||||
|
||||
library
|
||||
-------
|
||||
|
||||
almost all of the symbols and footprints used in the schematic and board layout are defined in the [QEDA](http://qeda.org/) format and generated for the CAD software.
|
||||
the `library` folder contains the QEDA parts definitions.
|
||||
|
||||
to install QEDA using NPM from the official repository:
|
||||
~~~
|
||||
sudo npm install -g qeda
|
||||
~~~
|
||||
|
||||
to install QEDA from the sources:
|
||||
~~~
|
||||
git clone https://github.com/qeda/qeda
|
||||
cd qeda
|
||||
npm install
|
||||
sudo npm install --global
|
||||
~~~
|
||||
|
||||
to generate the parts:
|
||||
~~~
|
||||
rake library
|
||||
~~~
|
||||
|
||||
this will use the parts definition (.yaml files) in the `library` to generate [gEDA gschem](http://wiki.geda-project.org/geda:gaf)/[Lepton EDA](https://github.com/lepton-eda/lepton-eda) symbols (.sym files) in the `geda/symbols` folder, and [coralEDA pcb-rnd](http://repo.hu/projects/pcb-rnd/) footprints (.lht files) in the `coraleda/subc` folder.
|
||||
|
||||
only the QEDA parts in subfolders within `library` come from the [QEDA library](https://doc.qeda.org/library/), but the files are included in this project for simplicity and archiving purposes.
|
||||
all other parts are custom and written for this project.
|
||||
|
||||
schematic
|
||||
---------
|
||||
|
||||
the `.sch` file is the schematic source file.
|
||||
it has been drawn using [Lepton EDA](https://github.com/lepton-eda/lepton-eda).
|
||||
|
||||
it uses standard symbols, and the ones in the `geda/symbols/` folder.
|
||||
most symbols are generated by QEDA as described above.
|
||||
|
||||
to export as pdf:
|
||||
~~~
|
||||
rake print
|
||||
~~~
|
||||
|
||||
BOM
|
||||
---
|
||||
|
||||
to export the bill of material (as CSV):
|
||||
~~~
|
||||
rake bom
|
||||
~~~
|
||||
|
||||
board
|
||||
-----
|
||||
|
||||
the `.lht` file is the board layout source file.
|
||||
it has been drawn using [coralEDA pcb-rnd](http://repo.hu/projects/pcb-rnd/).
|
||||
|
||||
it uses the symbols from the `coraleda/subc/` folder.
|
||||
most symbols are generated by QEDA as described above.
|
||||
`oshw_logo.lht` is just the Open Source Hardware Logo.
|
||||
it been generated from https://oshwlogo.cuvoodoo.info/.
|
||||
|
||||
to export gerber files for PCB manufacturer (and photo preview + overview document):
|
||||
~~~
|
||||
rake fabrication
|
||||
~~~
|
||||
|
||||
flashing
|
||||
========
|
||||
|
||||
the USB hub gets its configuration from an external EEPROM.
|
||||
running `eeprom.rb` will generate the EEPROM configuration in `eeprom.bin`.
|
||||
this must then be flashed on the board EEPROM.
|
||||
it is possible to flash it in circuit using the corresponding header, and by holding the RST signal low to prevent the USB hub from interfering with the communication.
|
||||
|
||||
to flash it using [minipro](https://gitlab.com/DavidGriffith/minipro/):
|
||||
|
||||
~~~
|
||||
minipro --device "AT24C16@SOIC8" --write eeprom.bin -s
|
||||
~~~
|
217
README.md
217
README.md
|
@ -1,88 +1,169 @@
|
|||
these are the hardware design files for **insert project name here**.
|
||||
the CuVoodoo USB hub is a 7-port USB 2.0 hub meant for device testing.
|
||||
|
||||
purpose
|
||||
=======
|
||||
|
||||
most USB hubs are super cheap and crappy, leading to poor connection and data transfer.
|
||||
there are industrial USB hubs, but they are bulky and very expensive.
|
||||
to solve this issue I decided to design my own USB hub, tailored to my needs.
|
||||
|
||||
when developing and testing hardware, you often end with a lot of USB devices connected (serial debugger, programmer, logic analyzer, ...).
|
||||
USB allows to have up to 128 devices, but only with a maximum depth of 7.
|
||||
thus you are only allowed to have a maximum of 5 USB hubs between computer and devices, and I often have to plan my setup to not reach this limit.
|
||||
most 7-port USB hubs use two 4-port USB hub, the seconds being connected to the first.
|
||||
there are some exceptions to that, but they are rare, old, and often not advertised as such.
|
||||
this heavily limits the actual number of end devices.
|
||||
the CuVoodoo USB hub is a 7-port flat USB hub, preventing reaching this limit too fast.
|
||||
|
||||
the upstream and downstream USB ports are individually ESD protected.
|
||||
this safety becomes important when developing, testing, and handling bare electronic devices.
|
||||
this also comes in handy when connecting circuit with different ground potentials.
|
||||
ESD protections already saved my day twice this way.
|
||||
the issue is that they can blow without you noticing, but at least they protected the device once.
|
||||
|
||||
each output port is current limited to 500 mA.
|
||||
no USB 2.0 device should draw more that this specified limit.
|
||||
it if does, there is very probably an issue with the device.
|
||||
this protection allows to isolate the faulty device and not have it affect all other connected devices, or the hub itself.
|
||||
see `current limitation` below for more details.
|
||||
|
||||
each downstream port is power controlled.
|
||||
this allows to remotely switch on and off individual devices.
|
||||
this is an important requirement when developing and testing devices, which require a power cycle.
|
||||
additionally, a switch next to the USB port can force the power off state.
|
||||
|
||||
the USB hub can be self-powered (through the USB input port), externally powered by 5V, or externally powered by anything between 6 and 40V.
|
||||
this allows to use higher voltage power supplies to provide enough current to all ports.
|
||||
the 5V are not feed back to the host.
|
||||
|
||||
each USB port comes with a high voltage output power port, connected to the high voltage input port.
|
||||
this allows to power devices which require more than 5V, with a maximum or 5A, such as 12V externally powered devices.
|
||||
these power outputs are controllable along the USB port.
|
||||
as with the 5V USB power output, this allows to remotely switch on an off individual devices.
|
||||
|
||||
each port has status LEDs, indicating the speed and power status of the connected device.
|
||||
|
||||
the board uses proper impedance and differential signal routing to provide clean USB signals.
|
||||
|
||||
design choice
|
||||
=============
|
||||
|
||||
USB 2.0
|
||||
-------
|
||||
|
||||
this hub is only for USB 2.0 devices.
|
||||
these are by far most of the devices I develop.
|
||||
it makes it simpler and keeps the cost reasonable.
|
||||
I often even disable USB 3.0 because of the 13-device limitation of the Intel xHCI.
|
||||
when I need USB 3.0 for the very few devices, I connected them to the computer directly.
|
||||
|
||||
USB2517
|
||||
-------
|
||||
|
||||
I wanted to use the FE2.1 7-port USB hub chip.
|
||||
it does not need an external voltage regulator or crystal.
|
||||
it is easier to solder thanks to its TQFP package, and provides all required functionalities.
|
||||
sadly I could not find a source for the 64-pin packages, and the 48-pin variant does not provide all required functionalities.
|
||||
thus I had to fall back to the Microchip USB2517, which uses a harder to solder QFN package.
|
||||
|
||||
power control
|
||||
-------------
|
||||
|
||||
some USB hub chips allow to remotely control the power output on individual ports.
|
||||
this capability is here also used to control the power on the higher voltage output.
|
||||
thus you can completely power off even larger target devices.
|
||||
|
||||
current limitation
|
||||
------------------
|
||||
|
||||
the USB hub has current limitation on the output.
|
||||
this does limit the current to 500 mA, but only in constant current mode.
|
||||
following current limiters have been tested:
|
||||
|
||||
- 0.5A PPTC fuse: it takes too long to trigger (> 1s), and switch off is not reliably detected
|
||||
- MT9700: it has no over-current signal
|
||||
- SY6288AAAC: the (fixed) current limit is not 0.6A, but around 1.5A
|
||||
- TJ2242GSF6: over-current is only detected after 3s (instead of specified 100us, probably caused by thermal shutdown), and it is not signaled
|
||||
- DIO7553ST6: works as expected and wished
|
||||
|
||||
the power distribution switch detects the over-current state and asserts the fault flag after 10 ms.
|
||||
after 0.1 ms (as set in OC_TIMER, in Configuration Data Byte 2, in EEPROM) the hub will switch off power.
|
||||
this also clears the over-current state.
|
||||
after 100 ms the HUB will re-enable power.
|
||||
this loop will repeat indefinitely.
|
||||
no over-current is reported to the host in this case (when the over-current is cleared while power is off).
|
||||
it is only reported when the OCS is asserted for longer (unknown time, with OCS kept low also when powered off).
|
||||
this is a flaw of the USB2517, where the over-current is only reported if it can't control the power state.
|
||||
I did not find a configuration option for this aspect in the datasheet.
|
||||
|
||||
LED color
|
||||
---------
|
||||
|
||||
the USB specification, LEDs are used as port indicator (section 11.5.3)
|
||||
|
||||
- off: powered off/disconnected
|
||||
- amber: current limitation reached
|
||||
- green: enabled or transmitting
|
||||
|
||||
instead the following color scheme is used:
|
||||
|
||||
- green off: power off or over-current
|
||||
- green on: power on
|
||||
- red: low speed device connected
|
||||
- blue: full speed device connected
|
||||
- purple (red+blue): high speed device connected
|
||||
- red and blue off: disconnected or in sleep
|
||||
|
||||
power output
|
||||
------------
|
||||
|
||||
switching the power of the USB port also switches the 6-40V forward output.
|
||||
when the 6-40V input is not connected, current/voltage feedback from the outputs is blocked.
|
||||
|
||||
usage
|
||||
=====
|
||||
|
||||
requirements
|
||||
============
|
||||
it mainly works like a regular USB hub, at least when it comes to the data transfer.
|
||||
just plug the device in a port.
|
||||
|
||||
to be able to generate the outputs you need following software:
|
||||
power on the Downstream Facing Ports (DFPs) is only available when the Upstream Facing Port (UFP) is connected.
|
||||
|
||||
- rake: the central script taking care of generating the output files (Makefile is too cumbersome to parse files)
|
||||
- [QEDA](http://qeda.org/): to generate footprints for the parts
|
||||
- [Lepton EDA](https://github.com/lepton-eda/lepton-eda): for the schematic capture
|
||||
- [pcb-rnd](http://repo.hu/projects/pcb-rnd/): for the board layout
|
||||
the output generation is automatized.
|
||||
the hub can operate as bus powered (power coming from the UFP), but it would not be able to provide more than 500 mA across all DFPs.
|
||||
it is preferable to connect an external 5V power supply to be able to provide 500 mA on all DFPs.
|
||||
this will also turn the hub into self powered, not using any power from the UFP.
|
||||
alternatively, you can connect a 6 to 40V power supply on the other power input.
|
||||
the power for the hub and the 5V for the DFP will be derivate from this higher voltage supply.
|
||||
the same higher voltage will be available on the power output next to the individual DFPs.
|
||||
the hub will not switch on until the UFP USB port is connected.
|
||||
|
||||
compiling
|
||||
=========
|
||||
a switch next to each DFP allows to turn off the power output on the USB and power ports.
|
||||
the green LED is on when power output is available.
|
||||
|
||||
library
|
||||
-------
|
||||
the power output on the USB and power ports can also be turned on/off remotely using standard USB commands.
|
||||
this power output control is implemented in [uhubctl](https://github.com/mvp/uhubctl):
|
||||
|
||||
almost all of the symbols and footprints used in the schematic and board layout are defined in the [QEDA](http://qeda.org/) format and generated for the CAD software.
|
||||
the `library` folder contains the QEDA parts definitions.
|
||||
|
||||
to install QEDA using NPM from the official repository:
|
||||
~~~
|
||||
sudo npm install -g qeda
|
||||
# list controllable USB hub ports
|
||||
sudo uhubctl
|
||||
# switch of port
|
||||
uhubctl --action off --location 1-1.4 --ports 5
|
||||
~~~
|
||||
|
||||
to install QEDA from the sources:
|
||||
EEPROM
|
||||
======
|
||||
|
||||
the USB2517 USB hub chip gets its configuration from an EEPROM.
|
||||
to generate the configuration:
|
||||
|
||||
~~~
|
||||
git clone https://github.com/qeda/qeda
|
||||
cd qeda
|
||||
npm install
|
||||
sudo npm install --global
|
||||
ruby eeprom.rb
|
||||
~~~
|
||||
|
||||
to generate the parts:
|
||||
this will create the `eeprom.bin` binary file.
|
||||
feel free to adjust the configuration in the generating script, such as the serial number.
|
||||
|
||||
after having soldered all the parts on the board, connect a programmer (here a MiniPRO TL866xx) on the J4 pin header to write the AT24C02 EEPROM:
|
||||
|
||||
~~~
|
||||
rake library
|
||||
~~~
|
||||
|
||||
this will use the parts definition (.yaml files) in the `library` to generate [gEDA gschem](http://wiki.geda-project.org/geda:gaf)/[Lepton EDA](https://github.com/lepton-eda/lepton-eda) symbols (.sym files) in the `geda/symbols` folder, and [coralEDA pcb-rnd](http://repo.hu/projects/pcb-rnd/) footprints (.lht files) in the `coraleda/subc` folder.
|
||||
|
||||
only the QEDA parts in subfolders within `library` come from the [QEDA library](https://doc.qeda.org/library/), but the files are included in this project for simplicity and archiving purposes.
|
||||
all other parts are custom and written for this project.
|
||||
|
||||
schematic
|
||||
---------
|
||||
|
||||
the `.sch` file is the schematic source file.
|
||||
it has been drawn using [Lepton EDA](https://github.com/lepton-eda/lepton-eda).
|
||||
|
||||
it uses standard symbols, and the ones in the `geda/symbols/` folder.
|
||||
most symbols are generated by QEDA as described above.
|
||||
|
||||
to export as pdf:
|
||||
~~~
|
||||
rake print
|
||||
~~~
|
||||
|
||||
BOM
|
||||
---
|
||||
|
||||
to export the bill of material (as CSV):
|
||||
~~~
|
||||
rake bom
|
||||
~~~
|
||||
|
||||
board
|
||||
-----
|
||||
|
||||
the `.lht` file is the board layout source file.
|
||||
it has been drawn using [coralEDA pcb-rnd](http://repo.hu/projects/pcb-rnd/).
|
||||
|
||||
it uses the symbols from the `coraleda/subc/` folder.
|
||||
most symbols are generated by QEDA as described above.
|
||||
`oshw_logo.lht` is just the Open Source Hardware Logo.
|
||||
it been generated from https://oshwlogo.cuvoodoo.info/.
|
||||
|
||||
to export gerber files for PCB manufacturer (and photo preview + overview document):
|
||||
~~~
|
||||
rake fabrication
|
||||
minipro --device "AT24C02@SOIC8" --write eeprom.bin -s
|
||||
~~~
|
||||
|
|
25
Rakefile
25
Rakefile
|
@ -14,7 +14,9 @@ require 'csv' # to export BOM and costs
|
|||
# =================
|
||||
|
||||
# common name used for file names
|
||||
name = "template"
|
||||
name = "usb_hub"
|
||||
# additional schematic sheets
|
||||
sheets = ["usb_hub-dfp1", "usb_hub-dfp2", "usb_hub-dfp3", "usb_hub-dfp4", "usb_hub-dfp5", "usb_hub-dfp6", "usb_hub-dfp7"]
|
||||
# project version, read from "version" file
|
||||
raise "define project version in 'version' file" unless File.exist? "version"
|
||||
version = IO.read("version").split("\n")[0]
|
||||
|
@ -37,8 +39,12 @@ task :default => [:print, :fabrication, :bom, :pnp]
|
|||
|
||||
desc "print schematic and layout (as pdf)"
|
||||
prints = [ "#{name}.sch.pdf", "#{name}.brd.pdf", "#{name}.brd-top.svg", "#{name}.brd-bottom.svg" ]
|
||||
unless sheets.empty? then
|
||||
prints += sheets.collect{|sheet| "#{sheet}.sch.pdf"}
|
||||
prints << "#{name}.sch-all.pdf"
|
||||
end
|
||||
task :print => prints
|
||||
CLEAN.include([ "#{name}.versioned.sch", "#{name}.versioned.lht" ])
|
||||
CLEAN.include([ "#{name}.versioned.sch", "#{name}.versioned.lht" ] + sheets.collect{|sheet| "#{sheet}.versioned.sch"})
|
||||
CLOBBER.include(prints)
|
||||
|
||||
desc "generate fabrication gerbers (as archive)"
|
||||
|
@ -89,7 +95,12 @@ end
|
|||
|
||||
desc "generate printable version (PDF) of schematic"
|
||||
rule ".sch.pdf" => ".versioned.sch" do |t|
|
||||
sh "lepton-cli export --color --paper iso_a4 --layout landscape --output #{t.name} #{t.source} 2> /dev/null"
|
||||
sh "lepton-cli export --color --paper=iso_a4 --layout=landscape --output=#{t.name} #{t.source} 2> /dev/null"
|
||||
end
|
||||
|
||||
desc "generate grouped printable version (PDF) of schematic"
|
||||
rule ".sch-all.pdf" => ["#{name}.sch.pdf"] + sheets.collect{|sheet| "#{sheet}.sch.pdf"} do |t|
|
||||
sh "mutool merge -o #{t.name} " + t.prerequisites * " "
|
||||
end
|
||||
|
||||
desc "generate printable version (PostScript) of board layout"
|
||||
|
@ -123,9 +134,9 @@ end
|
|||
desc "generate BOM file from schematic"
|
||||
rule ".bom.csv" => ".sch" do |t|
|
||||
attributes = ["device", "value", "description", "footprint", "manufacturer", "mpn", "datasheet", "lcsc", "digikey"]
|
||||
bom_data = bom2(t.prerequisites[0],attributes)
|
||||
bom_data = bom2(t.prerequisites[0], attributes)
|
||||
CSV.open(t.name, "wb") do |csv|
|
||||
all_attributes = ["refdes","qty"]+attributes
|
||||
all_attributes = ["refdes","qty"] + attributes
|
||||
csv << all_attributes
|
||||
bom_data.each do |line|
|
||||
csv << all_attributes.collect{|attribute| line[attribute]}
|
||||
|
@ -165,6 +176,10 @@ def bom2(schematic, attributes)
|
|||
list.gsub!(/(?!http):(?!\/\/)/, '\1":"\2') # protect the values between ':' (such as URLs)
|
||||
# parse bom2
|
||||
csv = CSV.parse(list, col_sep: ":", quote_char: '"')
|
||||
if csv.empty? then
|
||||
$stderr.puts "no parts found for BOM"
|
||||
return []
|
||||
end
|
||||
csv[1..-1].each do |row|
|
||||
line = {}
|
||||
row.each_index do |col|
|
||||
|
|
|
@ -0,0 +1,187 @@
|
|||
$fn=30;
|
||||
|
||||
BOARD_WIDTH=96.5;
|
||||
BOARD_HEIGHT=96.0;
|
||||
BOARD_THICKNESS=1.6;
|
||||
HOLE_NW_X=4.0;
|
||||
HOLE_NW_Y=4.0;
|
||||
HOLE_NE_X=92.5;
|
||||
HOLE_NE_Y=4.0;
|
||||
HOLE_SW_X=4.0;
|
||||
HOLE_SW_Y=92.0;
|
||||
HOLE_SE_X=92.5;
|
||||
HOLE_SE_Y=92.0;
|
||||
|
||||
WALL_SPACE=1.0;
|
||||
WALL_THICKNESS=2.0;
|
||||
HOLE_HEIGHT=15.0; // USB A is 14.5
|
||||
|
||||
module pillar() {
|
||||
translate([0,0,HOLE_HEIGHT/2]) {
|
||||
difference() {
|
||||
cylinder(h=HOLE_HEIGHT, d=6, center=true);
|
||||
cylinder(h=HOLE_HEIGHT, d=3.5, center=true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
mirror([1,0,0]) { // we used bottom view
|
||||
|
||||
// bottom plate
|
||||
cube([BOARD_WIDTH+2*WALL_SPACE+2*WALL_THICKNESS, BOARD_HEIGHT+2*WALL_SPACE+2*WALL_THICKNESS, WALL_THICKNESS]);
|
||||
|
||||
// screw mounts
|
||||
translate([WALL_THICKNESS+WALL_SPACE+HOLE_NW_X,WALL_THICKNESS+WALL_SPACE+HOLE_NW_Y,WALL_THICKNESS]) {
|
||||
pillar();
|
||||
}
|
||||
translate([WALL_THICKNESS+WALL_SPACE+HOLE_NE_X,WALL_THICKNESS+WALL_SPACE+HOLE_NE_Y,WALL_THICKNESS]) {
|
||||
pillar();
|
||||
}
|
||||
translate([WALL_THICKNESS+WALL_SPACE+HOLE_SW_X,WALL_THICKNESS+WALL_SPACE+HOLE_SW_Y,WALL_THICKNESS]) {
|
||||
pillar();
|
||||
}
|
||||
translate([WALL_THICKNESS+WALL_SPACE+HOLE_SE_X,WALL_THICKNESS+WALL_SPACE+HOLE_SE_Y,WALL_THICKNESS]) {
|
||||
pillar();
|
||||
}
|
||||
|
||||
// side
|
||||
MARGIN=1.0;
|
||||
USB_B_WIDTH=12.0+MARGIN;
|
||||
USB_B_HEIGHT=11.0+MARGIN;
|
||||
USB_A_WIDTH=7.0+MARGIN;
|
||||
USB_A_HEIGHT=14.5+MARGIN;
|
||||
BARREL_WIDTH=9.0+MARGIN;
|
||||
BARREL_HEIGHT=11.3+MARGIN;
|
||||
INDUCTOR_HEIGHT=7.5;
|
||||
|
||||
// side north
|
||||
difference() {
|
||||
cube([BOARD_WIDTH+2*WALL_SPACE+2*WALL_THICKNESS, WALL_THICKNESS, WALL_THICKNESS+HOLE_HEIGHT+BOARD_THICKNESS+INDUCTOR_HEIGHT]);
|
||||
// DFP 7 USB A
|
||||
translate([WALL_THICKNESS+WALL_SPACE+12.5-USB_A_WIDTH/2,0,WALL_THICKNESS+HOLE_HEIGHT-USB_A_HEIGHT]) {
|
||||
cube([USB_A_WIDTH,WALL_THICKNESS,USB_A_HEIGHT]);
|
||||
}
|
||||
// DFP 7 BARREL
|
||||
translate([WALL_THICKNESS+WALL_SPACE+28-BARREL_WIDTH/2,0,WALL_THICKNESS+HOLE_HEIGHT-BARREL_HEIGHT]) {
|
||||
cube([BARREL_WIDTH,WALL_THICKNESS,BARREL_HEIGHT]);
|
||||
}
|
||||
// DFP 6 USB A
|
||||
translate([WALL_THICKNESS+WALL_SPACE+40.5-USB_A_WIDTH/2,0,WALL_THICKNESS+HOLE_HEIGHT-USB_A_HEIGHT]) {
|
||||
cube([USB_A_WIDTH,WALL_THICKNESS,USB_A_HEIGHT]);
|
||||
}
|
||||
// DFP 6 BARREL
|
||||
translate([WALL_THICKNESS+WALL_SPACE+56-BARREL_WIDTH/2,0,WALL_THICKNESS+HOLE_HEIGHT-BARREL_HEIGHT]) {
|
||||
cube([BARREL_WIDTH,WALL_THICKNESS,BARREL_HEIGHT]);
|
||||
}
|
||||
// DFP 5 USB A
|
||||
translate([WALL_THICKNESS+WALL_SPACE+68.5-USB_A_WIDTH/2,0,WALL_THICKNESS+HOLE_HEIGHT-USB_A_HEIGHT]) {
|
||||
cube([USB_A_WIDTH,WALL_THICKNESS,USB_A_HEIGHT]);
|
||||
}
|
||||
// DFP 5 BARREL
|
||||
translate([WALL_THICKNESS+WALL_SPACE+84-BARREL_WIDTH/2,0,WALL_THICKNESS+HOLE_HEIGHT-BARREL_HEIGHT]) {
|
||||
cube([BARREL_WIDTH,WALL_THICKNESS,BARREL_HEIGHT]);
|
||||
}
|
||||
}
|
||||
|
||||
// side west
|
||||
difference() {
|
||||
cube([WALL_THICKNESS, BOARD_HEIGHT+2*WALL_SPACE+2*WALL_THICKNESS, WALL_THICKNESS+HOLE_HEIGHT+BOARD_THICKNESS+INDUCTOR_HEIGHT]);
|
||||
// USB B
|
||||
translate([0,WALL_THICKNESS+WALL_SPACE+48-USB_B_WIDTH/2,WALL_THICKNESS+HOLE_HEIGHT-USB_B_HEIGHT]) {
|
||||
cube([WALL_THICKNESS,USB_B_WIDTH,USB_B_HEIGHT]);
|
||||
}
|
||||
// 5V BARREL
|
||||
translate([0,WALL_THICKNESS+WALL_SPACE+33-BARREL_WIDTH/2,WALL_THICKNESS+HOLE_HEIGHT-BARREL_HEIGHT]) {
|
||||
cube([WALL_THICKNESS,BARREL_WIDTH,BARREL_HEIGHT]);
|
||||
}
|
||||
// 12V BARREL
|
||||
translate([0,WALL_THICKNESS+WALL_SPACE+63-BARREL_WIDTH/2,WALL_THICKNESS+HOLE_HEIGHT-BARREL_HEIGHT]) {
|
||||
cube([WALL_THICKNESS,BARREL_WIDTH,BARREL_HEIGHT]);
|
||||
}
|
||||
}
|
||||
|
||||
// side south
|
||||
translate([0,BOARD_HEIGHT+WALL_THICKNESS+2*WALL_SPACE,0]) {
|
||||
difference() {
|
||||
cube([BOARD_WIDTH+2*WALL_SPACE+2*WALL_THICKNESS, WALL_THICKNESS, WALL_THICKNESS+HOLE_HEIGHT+BOARD_THICKNESS+INDUCTOR_HEIGHT]);
|
||||
// DFP 1 USB A
|
||||
translate([WALL_THICKNESS+WALL_SPACE+27.5-USB_A_WIDTH/2,0,WALL_THICKNESS+HOLE_HEIGHT-USB_A_HEIGHT]) {
|
||||
cube([USB_A_WIDTH,WALL_THICKNESS,USB_A_HEIGHT]);
|
||||
}
|
||||
// DFP 1 BARREL
|
||||
translate([WALL_THICKNESS+WALL_SPACE+12-BARREL_WIDTH/2,0,WALL_THICKNESS+HOLE_HEIGHT-BARREL_HEIGHT]) {
|
||||
cube([BARREL_WIDTH,WALL_THICKNESS,BARREL_HEIGHT]);
|
||||
}
|
||||
// DFP 2 USB A
|
||||
translate([WALL_THICKNESS+WALL_SPACE+55.5-USB_A_WIDTH/2,0,WALL_THICKNESS+HOLE_HEIGHT-USB_A_HEIGHT]) {
|
||||
cube([USB_A_WIDTH,WALL_THICKNESS,USB_A_HEIGHT]);
|
||||
}
|
||||
// DFP 2 BARREL
|
||||
translate([WALL_THICKNESS+WALL_SPACE+40-BARREL_WIDTH/2,0,WALL_THICKNESS+HOLE_HEIGHT-BARREL_HEIGHT]) {
|
||||
cube([BARREL_WIDTH,WALL_THICKNESS,BARREL_HEIGHT]);
|
||||
}
|
||||
// DFP 3 USB A
|
||||
translate([WALL_THICKNESS+WALL_SPACE+83.5-USB_A_WIDTH/2,0,WALL_THICKNESS+HOLE_HEIGHT-USB_A_HEIGHT]) {
|
||||
cube([USB_A_WIDTH,WALL_THICKNESS,USB_A_HEIGHT]);
|
||||
}
|
||||
// DFP 3 BARREL
|
||||
translate([WALL_THICKNESS+WALL_SPACE+68-BARREL_WIDTH/2,0,WALL_THICKNESS+HOLE_HEIGHT-BARREL_HEIGHT]) {
|
||||
cube([BARREL_WIDTH,WALL_THICKNESS,BARREL_HEIGHT]);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// side east
|
||||
translate([BOARD_WIDTH+WALL_THICKNESS+2*WALL_SPACE,0,0]) {
|
||||
difference() {
|
||||
cube([WALL_THICKNESS, BOARD_HEIGHT+2*WALL_SPACE+2*WALL_THICKNESS, WALL_THICKNESS+HOLE_HEIGHT+BOARD_THICKNESS+INDUCTOR_HEIGHT]);
|
||||
// DFP 4 USB A
|
||||
translate([0,WALL_THICKNESS+WALL_SPACE+40.5-USB_A_WIDTH/2,WALL_THICKNESS+HOLE_HEIGHT-USB_A_HEIGHT]) {
|
||||
cube([WALL_THICKNESS,USB_A_WIDTH,USB_A_HEIGHT]);
|
||||
}
|
||||
// DFP 4 BARREL
|
||||
translate([0,WALL_THICKNESS+WALL_SPACE+56-BARREL_WIDTH/2,WALL_THICKNESS+HOLE_HEIGHT-BARREL_HEIGHT]) {
|
||||
cube([WALL_THICKNESS,BARREL_WIDTH,BARREL_HEIGHT]);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// top plate
|
||||
SWITCH_WIDTH=3.0+0.5;
|
||||
SWITCH_LENGTH=6.0+0.5;
|
||||
|
||||
translate([0,0,WALL_THICKNESS+HOLE_HEIGHT+BOARD_THICKNESS+INDUCTOR_HEIGHT]) {
|
||||
difference() {
|
||||
cube([BOARD_WIDTH+2*WALL_SPACE+2*WALL_THICKNESS, BOARD_HEIGHT+2*WALL_SPACE+2*WALL_THICKNESS, WALL_THICKNESS]);
|
||||
// DFP 7
|
||||
translate([WALL_THICKNESS+WALL_SPACE+20.0, WALL_THICKNESS+WALL_SPACE+6.7,WALL_THICKNESS/2]) {
|
||||
cube([SWITCH_WIDTH, SWITCH_LENGTH, WALL_THICKNESS], center=true);
|
||||
}
|
||||
// DFP 6
|
||||
translate([WALL_THICKNESS+WALL_SPACE+48.0, WALL_THICKNESS+WALL_SPACE+6.7,WALL_THICKNESS/2]) {
|
||||
cube([SWITCH_WIDTH, SWITCH_LENGTH, WALL_THICKNESS], center=true);
|
||||
}
|
||||
// DFP 5
|
||||
translate([WALL_THICKNESS+WALL_SPACE+76.0, WALL_THICKNESS+WALL_SPACE+6.7,WALL_THICKNESS/2]) {
|
||||
cube([SWITCH_WIDTH, SWITCH_LENGTH, WALL_THICKNESS], center=true);
|
||||
}
|
||||
// DFP 4
|
||||
translate([WALL_THICKNESS+WALL_SPACE+89.7, WALL_THICKNESS+WALL_SPACE+48.0,WALL_THICKNESS/2]) {
|
||||
cube([SWITCH_LENGTH, SWITCH_WIDTH, WALL_THICKNESS], center=true);
|
||||
}
|
||||
// DFP 3
|
||||
translate([WALL_THICKNESS+WALL_SPACE+76.0, WALL_THICKNESS+WALL_SPACE+89.3,WALL_THICKNESS/2]) {
|
||||
cube([SWITCH_WIDTH, SWITCH_LENGTH, WALL_THICKNESS], center=true);
|
||||
}
|
||||
// DFP 2
|
||||
translate([WALL_THICKNESS+WALL_SPACE+48.0, WALL_THICKNESS+WALL_SPACE+89.3,WALL_THICKNESS/2]) {
|
||||
cube([SWITCH_WIDTH, SWITCH_LENGTH, WALL_THICKNESS], center=true);
|
||||
}
|
||||
// DFP 1
|
||||
translate([WALL_THICKNESS+WALL_SPACE+20.0, WALL_THICKNESS+WALL_SPACE+89.3,WALL_THICKNESS/2]) {
|
||||
cube([SWITCH_WIDTH, SWITCH_LENGTH, WALL_THICKNESS], center=true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
Binary file not shown.
|
@ -0,0 +1,45 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<svg
|
||||
width="103mm"
|
||||
height="102mm"
|
||||
viewBox="-103 -102 103 102"
|
||||
version="1.1"
|
||||
id="svg4172"
|
||||
sodipodi:docname="top_plate.svg"
|
||||
inkscape:version="1.2.1 (9c6d41e410, 2022-07-14, custom)"
|
||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
||||
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
xmlns:svg="http://www.w3.org/2000/svg">
|
||||
<defs
|
||||
id="defs4176" />
|
||||
<sodipodi:namedview
|
||||
id="namedview4174"
|
||||
pagecolor="#ffffff"
|
||||
bordercolor="#666666"
|
||||
borderopacity="1.0"
|
||||
inkscape:showpageshadow="2"
|
||||
inkscape:pageopacity="0.0"
|
||||
inkscape:pagecheckerboard="0"
|
||||
inkscape:deskcolor="#d1d1d1"
|
||||
inkscape:document-units="mm"
|
||||
showgrid="false"
|
||||
inkscape:zoom="1.0246119"
|
||||
inkscape:cx="362.08831"
|
||||
inkscape:cy="323.04914"
|
||||
inkscape:window-width="1916"
|
||||
inkscape:window-height="1041"
|
||||
inkscape:window-x="0"
|
||||
inkscape:window-y="37"
|
||||
inkscape:window-maximized="1"
|
||||
inkscape:current-layer="svg4172" />
|
||||
<title
|
||||
id="title4168">OpenSCAD Model</title>
|
||||
<path
|
||||
d=" M 0,-102 L -102.5,-102 L -102.5,-0 L 0,-0 z M -24.75,-89.05 L -24.75,-95.55 L -21.25,-95.55 L -21.25,-89.05 z M -52.75,-89.05 L -52.75,-95.55 L -49.25,-95.55 L -49.25,-89.05 z M -80.75,-89.05 L -80.75,-95.55 L -77.25,-95.55 L -77.25,-89.05 z M -95.95,-49.25 L -95.95,-52.75 L -89.45,-52.75 L -89.45,-49.25 z M -24.75,-6.45 L -24.75,-12.95 L -21.25,-12.95 L -21.25,-6.45 z M -52.75,-6.45 L -52.75,-12.95 L -49.25,-12.95 L -49.25,-6.45 z M -80.75,-6.45 L -80.75,-12.95 L -77.25,-12.95 L -77.25,-6.45 z "
|
||||
stroke="black"
|
||||
fill="lightgray"
|
||||
stroke-width="0.5"
|
||||
id="path4170"
|
||||
style="stroke:#ff0000;fill:none" />
|
||||
</svg>
|
After Width: | Height: | Size: 1.8 KiB |
|
@ -0,0 +1,307 @@
|
|||
# subcircuit generated using QEDA
|
||||
li:pcb-rnd-subcircuit-v6 {
|
||||
ha:subc.1 {
|
||||
uid = CAPC1608X92N............
|
||||
ha:attributes {
|
||||
footprint = CAPC1608X92N
|
||||
}
|
||||
ha:data {
|
||||
li:padstack_prototypes {
|
||||
ha:ps_proto_v6.2 {
|
||||
htop = 0
|
||||
hbottom = 0
|
||||
hdia = 0
|
||||
hplated = 0
|
||||
li:shape {
|
||||
ha:ps_shape_v4 {
|
||||
clearance = 0.200mm
|
||||
li:ps_poly {
|
||||
-0.625mm
|
||||
-0.550mm
|
||||
0.625mm
|
||||
-0.550mm
|
||||
0.625mm
|
||||
0.550mm
|
||||
-0.625mm
|
||||
0.550mm
|
||||
}
|
||||
ha:layer_mask {
|
||||
top = 1
|
||||
copper = 1
|
||||
}
|
||||
ha:combining {
|
||||
}
|
||||
}
|
||||
ha:ps_shape_v4 {
|
||||
clearance = 0
|
||||
li:ps_poly {
|
||||
-0.675mm
|
||||
-0.600mm
|
||||
0.675mm
|
||||
-0.600mm
|
||||
0.675mm
|
||||
0.600mm
|
||||
-0.675mm
|
||||
0.600mm
|
||||
}
|
||||
ha:layer_mask {
|
||||
top = 1
|
||||
mask = 1
|
||||
}
|
||||
ha:combining {
|
||||
sub = 1
|
||||
auto = 1
|
||||
}
|
||||
}
|
||||
ha:ps_shape_v4 {
|
||||
clearance = 0
|
||||
li:ps_poly {
|
||||
-0.625mm
|
||||
-0.550mm
|
||||
0.625mm
|
||||
-0.550mm
|
||||
0.625mm
|
||||
0.550mm
|
||||
-0.625mm
|
||||
0.550mm
|
||||
}
|
||||
ha:layer_mask {
|
||||
top = 1
|
||||
paste = 1
|
||||
}
|
||||
ha:combining {
|
||||
auto = 1
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
li:objects {
|
||||
ha:padstack_ref.23 {
|
||||
proto = 2
|
||||
rot = 0
|
||||
x = 0.000mm
|
||||
y = -0.750mm
|
||||
ha:attributes {
|
||||
term = 1
|
||||
name = 1
|
||||
}
|
||||
clearance = 0.200mm
|
||||
ha:flags {
|
||||
clearline = 1
|
||||
}
|
||||
}
|
||||
ha:padstack_ref.24 {
|
||||
proto = 2
|
||||
rot = 0
|
||||
x = 0.000mm
|
||||
y = 0.750mm
|
||||
ha:attributes {
|
||||
term = 2
|
||||
name = 2
|
||||
}
|
||||
clearance = 0.200mm
|
||||
ha:flags {
|
||||
clearline = 1
|
||||
}
|
||||
}
|
||||
}
|
||||
li:layers {
|
||||
ha:subc-aux {
|
||||
lid = 0
|
||||
ha:type {
|
||||
top = 1
|
||||
misc = 1
|
||||
virtual = 1
|
||||
}
|
||||
li:objects {
|
||||
ha:line.25 {
|
||||
clearance = 0
|
||||
thickness = 0.1mm
|
||||
ha:attributes {
|
||||
subc-role = origin
|
||||
}
|
||||
x1 = 0.000mm
|
||||
x2 = 0.000mm
|
||||
y1 = 0.000mm
|
||||
y2 = 0.000mm
|
||||
}
|
||||
ha:line.26 {
|
||||
clearance = 0
|
||||
thickness = 0.1mm
|
||||
ha:attributes {
|
||||
subc-role = x
|
||||
}
|
||||
x1 = 0.000mm
|
||||
x2 = 1.000mm
|
||||
y1 = 0.000mm
|
||||
y2 = 0.000mm
|
||||
}
|
||||
ha:line.27 {
|
||||
clearance = 0
|
||||
thickness = 0.1mm
|
||||
ha:attributes {
|
||||
subc-role = y
|
||||
}
|
||||
x1 = 0.000mm
|
||||
x2 = 0.000mm
|
||||
y1 = 0.000mm
|
||||
y2 = 1.000mm
|
||||
}
|
||||
ha:line.28 {
|
||||
clearance = 0
|
||||
thickness = 0.1mm
|
||||
ha:attributes {
|
||||
subc-role = pnp-origin
|
||||
}
|
||||
x1 = 0.000mm
|
||||
x2 = 0.000mm
|
||||
y1 = 0.000mm
|
||||
y2 = 0.000mm
|
||||
}
|
||||
}
|
||||
}
|
||||
ha:top-silkscreen {
|
||||
lid = 1
|
||||
ha:type {
|
||||
top = 1
|
||||
silk = 1
|
||||
}
|
||||
li:objects {
|
||||
ha:text.29 {
|
||||
x = 0.000mm
|
||||
y = 0.000mm
|
||||
rot = 0
|
||||
scale = 100
|
||||
string = %a.parent.refdes%
|
||||
fid = 0
|
||||
ha:flags {
|
||||
floater = 1
|
||||
dyntext = 1
|
||||
}
|
||||
}
|
||||
ha:line.30 {
|
||||
x1 = -0.925mm
|
||||
y1 = -0.900mm
|
||||
x2 = -0.925mm
|
||||
y2 = 0.900mm
|
||||
thickness = 0.200mm
|
||||
clearance = 0
|
||||
}
|
||||
ha:line.31 {
|
||||
x1 = 0.925mm
|
||||
y1 = -0.900mm
|
||||
x2 = 0.925mm
|
||||
y2 = 0.900mm
|
||||
thickness = 0.200mm
|
||||
clearance = 0
|
||||
}
|
||||
}
|
||||
}
|
||||
ha:top-assembly {
|
||||
lid = 2
|
||||
ha:type {
|
||||
top = 1
|
||||
doc = 1
|
||||
}
|
||||
purpose = assy
|
||||
li:objects {
|
||||
ha:arc.32 {
|
||||
x = 0.000mm
|
||||
y = 0.000mm
|
||||
width = 0.500mm
|
||||
height = 0.500mm
|
||||
thickness = 0.100mm
|
||||
astart = 0
|
||||
adelta = 360
|
||||
clearance = 0
|
||||
}
|
||||
ha:line.33 {
|
||||
x1 = -0.700mm
|
||||
y1 = 0.000mm
|
||||
x2 = 0.700mm
|
||||
y2 = 0.000mm
|
||||
thickness = 0.100mm
|
||||
clearance = 0
|
||||
}
|
||||
ha:line.34 {
|
||||
x1 = 0.000mm
|
||||
y1 = -0.700mm
|
||||
x2 = 0.000mm
|
||||
y2 = 0.700mm
|
||||
thickness = 0.100mm
|
||||
clearance = 0
|
||||
}
|
||||
ha:text.35 {
|
||||
x = 0.000mm
|
||||
y = 0.000mm
|
||||
rot = 90
|
||||
scale = 53
|
||||
string = CAPC1608X92N
|
||||
fid = 0
|
||||
ha:flags {
|
||||
floater = 1
|
||||
}
|
||||
}
|
||||
ha:line.36 {
|
||||
x1 = -0.400mm
|
||||
y1 = -0.800mm
|
||||
x2 = 0.400mm
|
||||
y2 = -0.800mm
|
||||
thickness = 0.100mm
|
||||
clearance = 0
|
||||
}
|
||||
ha:line.37 {
|
||||
x1 = 0.400mm
|
||||
y1 = -0.800mm
|
||||
x2 = 0.400mm
|
||||
y2 = 0.800mm
|
||||
thickness = 0.100mm
|
||||
clearance = 0
|
||||
}
|
||||
ha:line.38 {
|
||||
x1 = 0.400mm
|
||||
y1 = 0.800mm
|
||||
x2 = -0.400mm
|
||||
y2 = 0.800mm
|
||||
thickness = 0.100mm
|
||||
clearance = 0
|
||||
}
|
||||
ha:line.39 {
|
||||
x1 = -0.400mm
|
||||
y1 = 0.800mm
|
||||
x2 = -0.400mm
|
||||
y2 = -0.800mm
|
||||
thickness = 0.100mm
|
||||
clearance = 0
|
||||
}
|
||||
}
|
||||
}
|
||||
ha:top-courtyard {
|
||||
lid = 3
|
||||
ha:type {
|
||||
top = 1
|
||||
doc = 1
|
||||
}
|
||||
purpose = ko.courtyard
|
||||
li:objects {
|
||||
ha:polygon.40 {
|
||||
li:geometry {
|
||||
ta:contour {
|
||||
{ -0.875mm; -1.550mm }
|
||||
{ -0.875mm; -1.050mm }
|
||||
{ -0.875mm; 1.050mm }
|
||||
{ -0.875mm; 1.550mm }
|
||||
{ 0.875mm; 1.550mm }
|
||||
{ 0.875mm; 1.050mm }
|
||||
{ 0.875mm; -1.050mm }
|
||||
{ 0.875mm; -1.550mm }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,428 @@
|
|||
# subcircuit generated using QEDA
|
||||
li:pcb-rnd-subcircuit-v6 {
|
||||
ha:subc.1 {
|
||||
uid = CAPPRD200W45D500H700N...
|
||||
ha:attributes {
|
||||
footprint = CAPPRD200W45D500H700N
|
||||
}
|
||||
ha:data {
|
||||
li:padstack_prototypes {
|
||||
ha:ps_proto_v6.2 {
|
||||
htop = 0
|
||||
hbottom = 0
|
||||
hdia = 0.650mm
|
||||
hplated = 1
|
||||
li:shape {
|
||||
ha:ps_shape_v4 {
|
||||
clearance = 0.200mm
|
||||
li:ps_poly {
|
||||
-0.525mm
|
||||
-0.525mm
|
||||
0.525mm
|
||||
-0.525mm
|
||||
0.525mm
|
||||
0.525mm
|
||||
-0.525mm
|
||||
0.525mm
|
||||
}
|
||||
ha:layer_mask {
|
||||
top = 1
|
||||
copper = 1
|
||||
}
|
||||
ha:combining {
|
||||
}
|
||||
}
|
||||
ha:ps_shape_v4 {
|
||||
clearance = 0
|
||||
li:ps_poly {
|
||||
-0.575mm
|
||||
-0.575mm
|
||||
0.575mm
|
||||
-0.575mm
|
||||
0.575mm
|
||||
0.575mm
|
||||
-0.575mm
|
||||
0.575mm
|
||||
}
|
||||
ha:layer_mask {
|
||||
top = 1
|
||||
mask = 1
|
||||
}
|
||||
ha:combining {
|
||||
sub = 1
|
||||
auto = 1
|
||||
}
|
||||
}
|
||||
ha:ps_shape_v4 {
|
||||
clearance = 0.200mm
|
||||
li:ps_poly {
|
||||
-0.525mm
|
||||
-0.525mm
|
||||
0.525mm
|
||||
-0.525mm
|
||||
0.525mm
|
||||
0.525mm
|
||||
-0.525mm
|
||||
0.525mm
|
||||
}
|
||||
ha:layer_mask {
|
||||
intern = 1
|
||||
copper = 1
|
||||
}
|
||||
ha:combining {
|
||||
}
|
||||
}
|
||||
ha:ps_shape_v4 {
|
||||
clearance = 0.200mm
|
||||
li:ps_poly {
|
||||
-0.525mm
|
||||
-0.525mm
|
||||
0.525mm
|
||||
-0.525mm
|
||||
0.525mm
|
||||
0.525mm
|
||||
-0.525mm
|
||||
0.525mm
|
||||
}
|
||||
ha:layer_mask {
|
||||
bottom = 1
|
||||
copper = 1
|
||||
}
|
||||
ha:combining {
|
||||
}
|
||||
}
|
||||
ha:ps_shape_v4 {
|
||||
clearance = 0
|
||||
li:ps_poly {
|
||||
-0.575mm
|
||||
-0.575mm
|
||||
0.575mm
|
||||
-0.575mm
|
||||
0.575mm
|
||||
0.575mm
|
||||
-0.575mm
|
||||
0.575mm
|
||||
}
|
||||
ha:layer_mask {
|
||||
bottom = 1
|
||||
mask = 1
|
||||
}
|
||||
ha:combining {
|
||||
sub = 1
|
||||
auto = 1
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
ha:ps_proto_v6.3 {
|
||||
htop = 0
|
||||
hbottom = 0
|
||||
hdia = 0.650mm
|
||||
hplated = 1
|
||||
li:shape {
|
||||
ha:ps_shape_v4 {
|
||||
clearance = 0.200mm
|
||||
ha:ps_circ {
|
||||
x = 0
|
||||
y = 0
|
||||
dia = 1.050mm
|
||||
}
|
||||
ha:layer_mask {
|
||||
top = 1
|
||||
copper = 1
|
||||
}
|
||||
ha:combining {
|
||||
}
|
||||
}
|
||||
ha:ps_shape_v4 {
|
||||
clearance = 0
|
||||
ha:ps_circ {
|
||||
x = 0
|
||||
y = 0
|
||||
dia = 1.100mm
|
||||
}
|
||||
ha:layer_mask {
|
||||
top = 1
|
||||
mask = 1
|
||||
}
|
||||
ha:combining {
|
||||
sub = 1
|
||||
auto = 1
|
||||
}
|
||||
}
|
||||
ha:ps_shape_v4 {
|
||||
clearance = 0.200mm
|
||||
ha:ps_circ {
|
||||
x = 0
|
||||
y = 0
|
||||
dia = 1.050mm
|
||||
}
|
||||
ha:layer_mask {
|
||||
intern = 1
|
||||
copper = 1
|
||||
}
|
||||
ha:combining {
|
||||
}
|
||||
}
|
||||
ha:ps_shape_v4 {
|
||||
clearance = 0.200mm
|
||||
ha:ps_circ {
|
||||
x = 0
|
||||
y = 0
|
||||
dia = 1.050mm
|
||||
}
|
||||
ha:layer_mask {
|
||||
bottom = 1
|
||||
copper = 1
|
||||
}
|
||||
ha:combining {
|
||||
}
|
||||
}
|
||||
ha:ps_shape_v4 {
|
||||
clearance = 0
|
||||
ha:ps_circ {
|
||||
x = 0
|
||||
y = 0
|
||||
dia = 1.100mm
|
||||
}
|
||||
ha:layer_mask {
|
||||
bottom = 1
|
||||
mask = 1
|
||||
}
|
||||
ha:combining {
|
||||
sub = 1
|
||||
auto = 1
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
li:objects {
|
||||
ha:padstack_ref.17 {
|
||||
proto = 2
|
||||
rot = 0
|
||||
x = 0.000mm
|
||||
y = -1.000mm
|
||||
ha:attributes {
|
||||
term = 1
|
||||
name = 1
|
||||
}
|
||||
clearance = 0.200mm
|
||||
ha:flags {
|
||||
clearline = 1
|
||||
}
|
||||
}
|
||||
ha:padstack_ref.18 {
|
||||
proto = 3
|
||||
rot = 0
|
||||
x = 0.000mm
|
||||
y = 1.000mm
|
||||
ha:attributes {
|
||||
term = 2
|
||||
name = 2
|
||||
}
|
||||
clearance = 0.200mm
|
||||
ha:flags {
|
||||
clearline = 1
|
||||
}
|
||||
}
|
||||
}
|
||||
li:layers {
|
||||
ha:subc-aux {
|
||||
lid = 0
|
||||
ha:type {
|
||||
top = 1
|
||||
misc = 1
|
||||
virtual = 1
|
||||
}
|
||||
li:objects {
|
||||
ha:line.19 {
|
||||
clearance = 0
|
||||
thickness = 0.1mm
|
||||
ha:attributes {
|
||||
subc-role = origin
|
||||
}
|
||||
x1 = 0.000mm
|
||||
x2 = 0.000mm
|
||||
y1 = 0.000mm
|
||||
y2 = 0.000mm
|
||||
}
|
||||
ha:line.20 {
|
||||
clearance = 0
|
||||
thickness = 0.1mm
|
||||