diff --git a/electronics_lib/PassiveConnector_Fpc.py b/electronics_lib/PassiveConnector_Fpc.py index 902a36bd5..090ae7056 100644 --- a/electronics_lib/PassiveConnector_Fpc.py +++ b/electronics_lib/PassiveConnector_Fpc.py @@ -120,13 +120,19 @@ class Fpc030TopBottom(Fpc030Bottom): IMPORTANT: the pin numbering scheme differs for top- and bottom-contact connectors.""" -class HiroseFh35cshw(Fpc030TopBottom, FootprintPassiveConnector): +class HiroseFh35cshw(Fpc030TopBottom, FootprintPassiveConnector, JlcPart): """Hirose FH35C SHW FFC/FPC connector, 0.30mm pitch horizontal top/bottom contacts.""" # positions the FH35C exists in, per datasheet _fh35c_pins = {9, 11, 13, 15, 17, 19, 21, 23, 25, 27, 31, 33, 35, 37, 39, 41, 45, 49, 51, 55, 61} # positions for which there are KiCad footprints _kicad_pins = {31} allowed_pins = _fh35c_pins.intersection(_kicad_pins) + PART_NUMBERS = { # partial list of the ones currently used + 31: 'C424662', + } def part_footprint_mfr_name(self, length: int) -> Tuple[str, str, str]: + # TODO this isn't the intended hook and uses side effects, but it works for now + self.assign(self.lcsc_part, self.PART_NUMBERS[length]) + self.assign(self.actual_basic_part, False) return (f'edg:Hirose_FH35C-{length}S-0.3SHW_1x{length:02d}-1MP_P0.30mm_Horizontal', "Hirose", f"FH35C-{length}S-0.3SHW") diff --git a/examples/jlcpcb_pcba_postprocess.py b/examples/jlcpcb_pcba_postprocess.py index b2cfbab14..ba81fe62d 100644 --- a/examples/jlcpcb_pcba_postprocess.py +++ b/examples/jlcpcb_pcba_postprocess.py @@ -27,6 +27,7 @@ 'C508453': 180, # FET 'C527684': -90, # TPS54202H SOT-23-6 'C155534': -90, # AL8861 MSOP-8 + 'C7722': -90, # TPS61040 SOT-23-5 'C2962219': -90, # 2x5 1.27mm header shrouded 'C126830': 90, # "SOT-23" USB ESD protector @@ -45,6 +46,8 @@ 'C262645': 180, # AFC07 FPC 30 'C262669': 180, # AFC01 FPC 24 + 'C424662': -90, # FH35C 0.3mm FPC 31 + 'C209762': -90, # EC11J15 } @@ -54,6 +57,7 @@ 'Package_TO_SOT_SMD:SOT-23': 180, 'Package_TO_SOT_SMD:SOT-23-5': 180, 'Package_TO_SOT_SMD:SOT-23-6': 180, + 'Package_TO_SOT_SMD:SOT-89-3': 180, 'Package_TO_SOT_SMD:SOT-323_SC-70': 180, 'Package_TO_SOT_SMD:SOT-223-3_TabPin2': 180, 'Package_SO:SOIC-8_3.9x4.9mm_P1.27mm': -90, @@ -80,6 +84,8 @@ 'C116648': (0, 2.1), # EC05E1220401 } _FOOTPRINT_OFFSETS = { + 'Package_TO_SOT_SMD:SOT-89-3': (-0.6, 0), + 'Connector_USB:USB_C_Receptacle_XKB_U262-16XN-4BVC11': (0, -1.25), 'RF_Module:ESP32-WROOM-32': (0, 0.8),