示例#1
0
 def define_ports(self, prts):
     prts += [OpticalPort(position = (-self.ring_radius, -self.ring_radius - self.coupler_spacing),
                          angle = 180.0, # outward pointing
                          wg_definition = self.bus_wg_def),
              OpticalPort(position = (self.ring_radius, -self.ring_radius - self.coupler_spacing),
                          angle = 0.0, # outward pointing
                          wg_definition = self.bus_wg_def)
              ]
     return prts
示例#2
0
文件: tapers.py 项目: joamatab/ipkiss
    def define_taper(self):
        start_wg_def = self.start_port.wg_definition.get_wg_definition_cross_section(
        )
        end_wg_def = self.end_wg_def.get_wg_definition_cross_section()
        if start_wg_def.trench_width == 0.0:
            new_start_wg_def = WgElDefinition(
                wg_width=start_wg_def.shallow_wg_width,
                trench_width=start_wg_def.shallow_trench_width,
                process=start_wg_def.shallow_process)
            new_start_port = OpticalPort(
                position=self.start_port.position,
                wg_definition=new_start_wg_def,
                angle=self.start_port.angle)
            taper = WgElPortTaperFromShallow(
                start_port=new_start_port,
                end_wg_def=end_wg_def,
                length=self.length,
                straight_extension=self.straight_extension,
                shallow_process=start_wg_def.shallow_process)
        else:
            new_end_wg_def = WGFCWgElDefinition(
                trench_width=end_wg_def.trench_width,
                shallow_wg_width=end_wg_def.wg_width,
                shallow_trench_width=start_wg_def.shallow_trench_width,
                wg_width=end_wg_def.wg_width,
                shallow_process=start_wg_def.shallow_process)

            taper = WgElPortTaperLinear(
                start_port=self.start_port,
                end_wg_def=new_end_wg_def,
                length=self.length,
                straight_extension=self.straight_extension)

        return taper
示例#3
0
 def define_taper(self):
     start_wg_def = self.start_port.wg_definition.get_wg_definition_cross_section(
     )
     end_wg_def = self.end_wg_def.get_wg_definition_cross_section()
     new_end_wg_def = WGFCWgElDefinition(
         trench_width=end_wg_def.trench_width,
         shallow_wg_width=end_wg_def.wg_width,
         shallow_trench_width=0.5 *
         (start_wg_def.thin_width - end_wg_def.wg_width),
         wg_width=end_wg_def.wg_width,
         shallow_process=start_wg_def.thin_process)
     new_start_wg_def = WGFCWgElDefinition(
         trench_width=start_wg_def.trench_width,
         shallow_wg_width=TECH.TECH.MINIMUM_LINE,
         shallow_trench_width=0.5 *
         (start_wg_def.thin_width - TECH.TECH.MINIMUM_LINE),
         wg_width=start_wg_def.wg_width,
         shallow_process=start_wg_def.thin_process)
     new_start_port = OpticalPort(position=self.start_port.position,
                                  wg_definition=new_start_wg_def,
                                  angle=self.start_port.angle)
     taper = WgElPortTaperLinear(start_port=new_start_port,
                                 end_wg_def=new_end_wg_def,
                                 length=self.length,
                                 straight_extension=self.straight_extension)
     return taper
示例#4
0
文件: layout.py 项目: joamatab/ipkiss
    def __get_arm_content__(self, A):
        # if no content in arm, create dummy
        if A is None:
            A = Structure(name="%s_BLANK" % (self.name),
                          elements=[],
                          ports=[
                              OpticalPort(position=(0.0, 0.0),
                                          wg_definition=self.wg_definition,
                                          angle_deg=180.0),
                              OpticalPort(position=(0.0, 0.0),
                                          wg_definition=self.wg_definition,
                                          angle_deg=0.0)
                          ])

        # if widths not identical,add tapers
        if A.west_ports[0].wg_definition.wg_width == self.CPin[
                1].wg_definition.wg_width and A.east_ports[
                    0].wg_definition.wg_width == self.CPout[
                        1].wg_definition.wg_width:
            AC = A
        else:
            from picazzo.wg.taper_extended import WgElPortTaperExtended
            if self.automatic_taper_west_length is None:
                T1 = WgElPortTaperExtended(
                    start_port=A.west_ports[0],
                    end_wg_def=self.CPin[1].wg_definition)
            else:
                T1 = WgElPortTaperExtended(
                    start_port=A.west_ports[0],
                    end_wg_def=self.CPin[1].wg_definition,
                    length=self.automatic_taper_west_length)

            if self.automatic_taper_east_length is None:
                T2 = WgElPortTaperExtended(
                    start_port=A.east_ports[0],
                    end_wg_def=self.CPout[1].wg_definition)
            else:
                T2 = WgElPortTaperExtended(
                    start_port=A.east_ports[0],
                    end_wg_def=self.CPout[1].wg_definition,
                    length=self.automatic_taper_east_length)

            AC = Structure(elements=[SRef(A, (0.0, 0.0)), T1, T2],
                           ports=[T1.west_ports[0], T2.east_ports[0]])
        return AC