Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add dbr component #7

Merged
merged 4 commits into from
Oct 18, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 21 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,25 @@

Skywater photonics PDK for the SKY130 process node.

## Usage

## Installation

As of now, this PDK is not on PyPI.

So, to install it, you would need to:

1. Clone the repo
2. cd into the repo
3. Run `pip install -e .`

## TODO

- Add component library
- Add tests
- Test components

## Authors

- Skandan Chandrasekar
- Sequoia Ploeg
- Elise Bangerter
- Joel Kartchner
1 change: 0 additions & 1 deletion sky130ph/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,4 @@
__author__ = "SkandanC <[email protected]>"
from typing import List


__all__: List[str] = []
84 changes: 84 additions & 0 deletions sky130ph/components.py
Original file line number Diff line number Diff line change
@@ -1 +1,85 @@
"""Photonic component library."""


import gdsfactory as gf
from gdsfactory import cell, get_component


@cell
def _dbr_cell(
w1: float = 0.5,
w2: float = 0.65,
l1: float = 0.288,
l2: float = 0.288,
straight: gf.types.ComponentSpec = gf.components.straight,
) -> gf.Component:
"""Distributed Bragg Reflector unit cell.

Args:
w1: thin width in um.
l1: thin length in um.
w2: thick width in um.
l2: thick length in um.
n: number of periods.
straight: spec in um.

.. code::

l1 l2
<-----><-------->
_________
_______|

w1 w2
_______
|_________
"""
l1 = gf.snap.snap_to_grid(l1)
l2 = gf.snap.snap_to_grid(l2)
w1 = gf.snap.snap_to_grid(w1, 2)
w2 = gf.snap.snap_to_grid(w2, 2)
c = gf.Component()
c1 = c << get_component(straight, length=l1, width=w1, cross_section="nitride")
c2 = c << get_component(straight, length=l2, width=w2, cross_section="strip")
c2.connect(port="o1", destination=c1.ports["o2"])
c.add_port("o1", port=c1.ports["o1"])
c.add_port("o2", port=c2.ports["o2"])
return c


@gf.cell
def dbr() -> gf.Component:
"""Distributed Bragg Reflector.

.. code::

0.288um 0.288um
<-------><------>
________ _______
| |_______|
| | |
| 0.5um | 0.65um| ... 10 times
| |_______|
|_______| |_______
"""
c = gf.Component()
l1 = gf.snap.snap_to_grid(0.288)
l2 = gf.snap.snap_to_grid(0.288)
cell = _dbr_cell()
c.add_array(cell, columns=10, rows=1, spacing=(l1 + l2, 100))
starting_rect = c << gf.get_component(
"straight", length=l2, width=0.65, cross_section="strip"
)
starting_rect.move(starting_rect.center, (-0.144, 0))
c.add_port("o1", port=starting_rect.ports["o1"])
p1 = c.add_port("o2", port=cell.ports["o2"])
p1.center = [(l1 + l2) * 10, 0]
return c


if __name__ == "__main__":
import gdsfactory as gf

c = dbr()
c.show()
print(c.to_yaml())
194 changes: 0 additions & 194 deletions sky130ph/layers.py

This file was deleted.

13 changes: 0 additions & 13 deletions sky130ph/tech.py

This file was deleted.