AnsweredAssumed Answered

Script help - disconnected parameters and variables.

Question asked by johnboyer on Jan 5, 2016
Latest reply on Jan 28, 2016 by BarrettP

Hi,

I've got a script, which creates a slot antenna and I'd like to tweak it using parameters I've set up, but they seem to be disconnected from the design. If I change them, the geometry doesn't change.

Thanks for any help received.

J.

Precis of  my script
gnd_w = 60*mm
gnd_h = 130*mm
t = 0.017*mm    # copper thickness

die_t=1.6 * mm  # overall thickness of pcb
layer1_t = 0.1016 *mm

die_t = 1.6*mm

slot_h = 9.4*mm
slot_w = 0.8*mm
feed_off = 4.5* mm

#center position of slot
slot_y = 10*mm 
slot_z = 10*mm

params.append("slot_y","10 mm")
params.append("slot_z","10 mm")

# Add ground plane
tmp = toolkit.geometry.Block(V(0,-gnd_w/2,-gnd_h/2),V(t,gnd_w/2,gnd_h/2))

# Draw slot
slot = toolkit.geometry.Block(V(0,-slot_w/2+slot_y,-slot_h/2+slot_z),V(t,slot_w/2+slot_y,slot_h/2+slot_z))

#remove slot from ground
gnd=empro.geometry.Boolean.subtract(tmp,slot)
gnd.name = "gnd"
gnd.material = empro.toolkit.defaultMaterial("Cu")
parts.append(gnd)

Outcomes