;================================================================================ ; Robert Johnstone ; Simon Fraser University ; ; Copyright 2000,2002 Robert W. Johnstone ;-------------------------------------------------------------------------------- ; 2002/06/03 ; - modified code because interface to dbCreateMumpsPin changed ; - modified code because interface to dbCreateRoundRect changed ; 2002/02/21 ; - added parameter check to ensure cross parameter is greater then the minSpacing ; 2001/10/19 ; - tech file has been updated to include DIMPLE maxSpacing rule ; - removed the dimples parameter, dimple count now determined automatically ; - changed default for include_poly0 to true unless( boundp( 'admLibraryName ) warn( "Setting the destination library to default value of ADM" ) admLibraryName = "ADM" ) pcDefinePCell( list( ddGetObj(admLibraryName) "heatuator" "layout" ) ; end of list for first argument ( ( length 200.0 ) ( flexure 40.0 ) ( gap 2.0 ) ( chamfer 0.0 ) ( width_c 15.0 ) ( width_h 2.0 ) ( width_f 2.0 ) ( cross 9.0 ) ( actuation 10.0 ) ( pin_size 20.0 ) ( include_stopper "boolean" nil ) ( include_poly0 "boolean" t ) ( include_hook "boolean" nil ) ) ; end of parameter list prog( ; declare variables ( pcTechFile pcNet pcPin rodObj p0p1_enclosure p0p1_minSpacing p1_minSpacing p1_minWidth p1_nomSpacing p1a1_enclosure p1p2_enclosure a1_nomWidth p2p0_enclosure p2v_enclosure p2m_enclosure v_minWidth m_minWidth d_maxSpacing d_nomWidth tmp1 tmp2 tmp3 dimple_count ) ; load tech file rules pcTechFile = techGetTechFile( pcCellView ) p0p1_enclosure = techGetOrderedSpacingRule( pcTechFile "minEnclosure" "POLY0" "POLY1" ) unless( p0p1_enclosure warn("minEnclosure rule for POLY0->POLY1 not set") ) p0p1_minSpacing = techGetSpacingRule( pcTechFile "minSpacing" "POLY0" "POLY1" ) unless( p0p1_minSpacing warn("minSpacing rule for POLY0 and POLY1 not set") ) p1_minSpacing = techGetSpacingRule( pcTechFile "minSpacing" "POLY1" ) unless( p1_minSpacing warn("minSpacing rule for POLY1 not set") ) p1_minWidth = techGetSpacingRule( pcTechFile "minWidth" "POLY1" ) unless( p1_minWidth warn("minWidth rule for POLY1 not set") ) p1_nomSpacing = techGetSpacingRule( pcTechFile "nomSpacing" "POLY1" ) unless( p1_nomSpacing warn("nomSpacing rule for POLY1 not set") ) p1a1_enclosure = techGetOrderedSpacingRule( pcTechFile "minEnclosure" "POLY1" "ANCHOR1" ) unless( p1a1_enclosure warn("minEnclosure rule for POLY1->ANCHOR1 not set") ) p1p2_enclosure = techGetOrderedSpacingRule( pcTechFile "minEnclosure" "POLY1" "POLY2" ) unless( p1p2_enclosure warn("minEnclosure rule for POLY1->POLY2 not set") ) a1_nomWidth = techGetSpacingRule( pcTechFile "nomWidth" "ANCHOR1" ) unless( a1_nomWidth warn("nomWidth rule for ANCHOR1 not set") ) p2p0_enclosure = techGetOrderedSpacingRule( pcTechFile "minEnclosure" "POLY2" "POLY0" ) unless( p2p0_enclosure warn("minEnclosure rule for POLY2->POLY0 not set") ) p2v_enclosure = techGetOrderedSpacingRule( pcTechFile "minEnclosure" "POLY2" "P1P2VIA" ) unless( p2v_enclosure warn("minEnclosure rule for POLY2->P1P2VIA not set") ) p2m_enclosure = techGetOrderedSpacingRule( pcTechFile "minEnclosure" "POLY2" "METAL" ) unless( p2m_enclosure warn("minEnclosure rule for POLY2->METAL not set") ) v_minWidth = techGetSpacingRule( pcTechFile "minWidth" "P1P2VIA" ) unless( v_minWidth warn("minWidth rule for P1P2VIA not set") ) m_minWidth = techGetSpacingRule( pcTechFile "minWidth" "METAL" ) unless( m_minWidth warn("minWidth rule for METAL not set") ) d_maxSpacing = techGetSpacingRule( pcTechFile "maxSpacing" "DIMPLE" ) unless( d_maxSpacing warn("maxSpacing rule for DIMPLE not set") ) d_nomWidth = techGetSpacingRule( pcTechFile "nomWidth" "DIMPLE" ) unless( d_nomWidth warn("nomWidth rule for DIMPLE not set") ) ; check parameters gap = if( (gapparamVal + SPCInfo->increment ) ) ; poly0 enclosure if( (include_poly0==t) then dbCreatePolygon( pcCellView "POLY0" list( p0p1_minSpacing:(gap*0.5+width_h+p0p1_enclosure) (length+p0p1_enclosure):(gap*0.5+width_h+p0p1_enclosure) (length+p0p1_enclosure):(-gap*0.5-width_c-p0p1_enclosure-actuation) (length-p0p1_enclosure):(-gap*0.5-width_c-p0p1_enclosure-actuation) p0p1_minSpacing:(-gap*0.5-width_c-p0p1_enclosure) ) ) dbCreateRect( pcCellView "POLY0" list( -pin_size+p1p2_enclosure+p2p0_enclosure:-pin_size-gap*0.5+p1p2_enclosure+p2p0_enclosure p0p1_minSpacing:-gap*0.5-p1p2_enclosure-p2p0_enclosure ) ) ) ; inlclude hook ? if( (include_hook==t) then dbCreatePolygon( pcCellView "POLY1" list( length:-p1_minWidth length+2*p1_minWidth:-p1_minWidth length+4*p1_minWidth:p1_minWidth length+4*p1_minWidth:3*p1_minWidth length+3*p1_minWidth:3*p1_minWidth length+p1_minWidth:p1_minWidth length:p1_minWidth ) ) dbCreateRect( pcCellView "TMP" list( length+3*p1_minWidth:3*p1_minWidth length+4*p1_minWidth:4*p1_minWidth ) ) ) ; create the stop label if( (actuation>0) then dbCreateRect( pcCellView "LABEL" list( length:(-gap*0.5-width_c-actuation) (length-width_c-gap-width_h):(-gap*0.5-width_c-actuation-1) ) ) dbCreateLabel( pcCellView '("TMP" "drawing") (length-0.5*(width_c+gap+width_h)):(-gap*0.5-width_c-actuation+1) "STOP LINE" "lowerCenter" "R0" "roman" 2.0 ) ) ; create PWR pin pcNet = dbMakeNet( pcCellView "PWR" ) pcPin = dbCreateMumpsPin( pcCellView pcNet -pin_size*0.5:(pin_size*0.5 + gap*0.5) pin_size chamfer ) pcPin~>accessDir = list( "top" "left" ) ; create GND pin pcNet = dbMakeNet( pcCellView "GND" ) pcPin = dbCreateMumpsPin( pcCellView pcNet -pin_size*0.5:(-pin_size*0.5 - gap*0.5) pin_size chamfer ) pcPin~>accessDir = list( "bottom" "left" ) ; add stopper if requested if( (include_stopper==t) then tmp1 = p1a1_enclosure*2 + a1_nomWidth tmp2 = gap*0.5+width_h+p1_nomSpacing dbCreateRoundRect( pcCellView "POLY1" list( (length-2*tmp1):tmp2 length:(tmp2+tmp1) ) 1 ) if( (include_poly0==t) dbCreateRoundRect( pcCellView "POLY0" list( (length-2*tmp1-p0p1_enclosure):(tmp2-p0p1_enclosure) (length+p0p1_enclosure):(tmp1+tmp2+p0p1_enclosure) ) 1 ) ) dbCreateRect( pcCellView "ANCHOR1" list( (length-p1a1_enclosure):(tmp2+p1a1_enclosure) (length-2*tmp1+p1a1_enclosure):(tmp2+tmp1-p1a1_enclosure) ) ); ) ; add the dimples if( (dimple_count<1) then warn( "dimple count less than 1 in hatuator pcell." ) ) if( (dimple_count>1) then tmp1 = (width_c - d_nomWidth)*0.5 tmp2 = -gap*0.5-tmp1 for( lp 1 dimple_count tmp3 = length - tmp1 - d_nomWidth - (lp-1)*(length-flexure-tmp1*2-d_nomWidth)/(dimple_count-1) dbCreateRect( pcCellView "DIMPLE" list( tmp3:tmp2 (tmp3+d_nomWidth):(tmp2-d_nomWidth) ) ) ) else tmp1 = (-width_c + d_nomWidth - gap)*0.5 tmp3 = length - width_c* 0.5 + d_nomWidth * 0.5 dbCreateRect( pcCellView "DIMPLE" list( tmp3:tmp1 tmp3-d_nomWidth:tmp1-d_nomWidth) ) ) ; calculate resistance properties, if possible ;tmp1 = techGetSpacingRule( pcTechFile "minResistance" "POLY1" ) ;if( (tmp1!=nil) then ; tmp2 = (length-cross)/width_h + gap/cross + (length-flexure-cross)/width_c + flexure/width_f ; tmp2 = tmp2 * tmp1 ; pcProp = dbReplaceProp( pcCellView "minResistance" "float" tmp2 ) ;dbCreateTextDisplay( pcProp pcCellView "TMP" t ; 1:gap*0.5+pin_size-1 ; "upperLeft" "R0" "stick" 2 t nil t t t "name" nil) ;else ; warn( "minResistance property for POLY1 not set." ) ;) ;tmp1 = techGetSpacingRule( pcTechFile "nomResistance" "POLY1" ) ;if( (tmp1!=nil) then ; tmp2 = (length-cross)/width_h + gap/cross + (length-flexure-cross)/width_c + flexure/width_f ; tmp2 = tmp2 * tmp1 ; pcProp = dbReplaceProp( pcCellView "nomResistance" "float" tmp2 ) ;dbCreateTextDisplay( pcProp pcCellView "TMP" t ; 1:gap*0.5+pin_size-4 ; "upperLeft" "R0" "stick" 2 t nil t t t "name" nil) ;else ; warn( "nomResistance property for POLY1 not set." ) ;) ;tmp1 = techGetSpacingRule( pcTechFile "maxResistance" "POLY1" ) ;if( (tmp1!=nil) then ; tmp2 = (length-cross)/width_h + gap/cross + (length-flexure-cross)/width_c + flexure/width_f ; tmp2 = tmp2 * tmp1 ; pcProp = dbReplaceProp( pcCellView "maxResistance" "float" tmp2 ) ;dbCreateTextDisplay( pcProp pcCellView "TMP" t ; 1:gap*0.5+pin_size-8 ; "upperLeft" "R0" "stick" 2 t nil t t t "name" nil) ;else ; warn( "maxResistance property for POLY1 not set." ) ;) ; set default instance name prefix dbReplaceProp( pcCellView "instNamePrefix" "string" "actuator" ) ; set version string dbReplaceProp( pcCellView "version" "string" "1.7.1" ) ; body SKILL code returns value t return(t) ) ; end of body-of-SKILL-code prog ) ; ; end of pcDefinePCell