[OpenSCAD] Frustrating unexpected behavior

Peter Falke stempeldergeschichte at googlemail.com
Mon Apr 6 19:11:05 EDT 2015


I`m sorry. I cant quiet understand what you problem is.
What numbers? What are you trying to do?

2015-04-06 23:37 GMT+02:00 linkreincarnate <linkreincarnate at gmail.com>:

> So I am trying to make a lid for a hinged box.  I am getting some
> unpredictable results with it though.   I need to be able to make a cutout
> of the lip of the box at the level where the lid ends and the lip begins
> and
> to place a hinge part there.  But when I change the numbers around to
> anything other than a 1:1 ratio on the two numbers that control the
> thickness I am unable to predict where the transition from lid to lip
> begins.  I have been working on this particular problem since yesterday and
> I am being stumped.  What am I missing here?
>
> boxLength = 90.4;
> boxWidth = 81.25;
> boxHeight = 19.2;
> boxBottomThickness = .67;
> boxWallThickness = .67;
> boxArcHeight = 3.5;
> boxArcRadius=1;
> boxControlArmHoleZOffset = 3.5;
> boxControlArmHoleYOffset = 3;
> boxHingePinDiameter = 3;
> boxHingeDiameter= 5;
> boxHingeZOffset = 0;
> boxHingeYOffset = 0;
> boxHingeTolerance = .1;
> boxHingeSupportZOffset= -5;
> boxHingeSupportYOffset = -4.5;
> boxHingeNumberOfSplits = 7;
> boxHingeClearance=1;
> //the following variables determine the details of the cylinder (or sphere)
> used for minkowski sums
> boxCornerRoundness = 7;
> boxCornerSmoothness = 16;
> boxRoundCorners = true;
>
> controlArmLength = 0;
> controlArmHeight = 0;
> conrolArmThickness = 0;
> controlArmPinDiameter = 2;
> controlArmHoleZOffset = 0;
> controlArmHoleYOffset = 0;
> controlArmPinTolerance = .1;
>
> lidLipHeight = 2;
> lidThickness = 2;
> lidTolerance = 1;
> lidHingeZOffset = 0;
> lidHingeYOffset = 0;
> lidHingeTolerance = 1;
> lidOverlap = 2;
>
> dispenserHoleLength = 72; //also used for dist between tracks
> dispenserHoleWidth = 11.5;
> dispenserHoleXOffset = 0;
> dispenserHoleYOffset = 0;
>
> trackPanelLength = 76;
> trackPanelHeight = 19;
> trackPanelThickness = 3;
> trackWidth = 2.5;
> trackLength = 61;
> trackHeight = 14;
>
> rollerDiameter = 7;
> rollerLength = 71;
>
> rollerPinDiameter = 2;
> hingePinDiameter = 1.6;
> pinLength= 71;
>
> pinTolerance = 1;
> cigaretteDiameter = 7.75;
> cigaretteLength = 70;
>
> booleanOverlap = .01; //to ensure that the faces used to difference() dont
> line up
>
> lowRollingClearance = 5; //the distance from the center of the rolling pin
> to the lid at the lowest point.
> hightRollingClearance = 12.6;
>
> arched = false;
> //uses math to determine the arc radius of the curve of the box and creates
> the appropriate cylinder
>
>
> difference(){
>                     $fn=boxCornerSmoothness;
>                     minkowski(){
>                      cube([lidOverlap + boxLength + lidTolerance - (2 *
> boxCornerRoundness),
>                            lidOverlap + boxWidth + lidTolerance - (2 *
> boxCornerRoundness),
>                            ((lidThickness + lidLipHeight)/2)],
> center=true);
>                      cylinder(r=boxCornerRoundness,
>                                  h=((lidThickness + lidLipHeight)/2),
> center=true);
>                     }
>
>                     translate([0,0,-lidThickness/2 ])
>                     {
>                         $fn=boxCornerSmoothness;
>                         minkowski()
>                         {
>                          cube([boxLength + lidTolerance - (2 *
> boxCornerRoundness) ,
>                                boxWidth + lidTolerance - (2 *
> boxCornerRoundness),
>                                lidLipHeight+booleanOverlap],center = true);
>                          cylinder(r=boxCornerRoundness,h=lidLipHeight/2,
> center = true);
>                         }
>                     }
>                     translate([0,(boxCornerRoundness + lidTolerance +
> lidOverlap+booleanOverlap),-lidThickness/2])
>                     cube([boxLength + lidTolerance - (2 *
> boxCornerRoundness) ,
>                                boxWidth + lidTolerance - (2 *
> boxCornerRoundness),
>                                lidLipHeight +booleanOverlap],center =
> true);
> }
>
>
>
> --
> View this message in context:
> http://forum.openscad.org/Frustrating-unexpected-behavior-tp12321.html
> Sent from the OpenSCAD mailing list archive at Nabble.com.
>
> _______________________________________________
> OpenSCAD mailing list
> Discuss at lists.openscad.org
> http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
>



-- 
stempeldergeschichte at googlemail.com <karsten at rohrbach.de>

P.S. Falls meine E-Mail kürzer ausfällt als Dir angenehm ist:
Ich probiere gerade aus kurze Antworten statt gar keine Antworten zu
schreiben.
Wenn Du gerne mehr lesen möchtest, dann lass es mich bitte wissen.

P.S. In case my e-mail is shorter than you enjoy:
I am currently trying short replies instead of no replies at all.
Please let me know, if you like to read more.

Enjoy!
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openscad.org/pipermail/discuss_lists.openscad.org/attachments/20150407/e6852e7c/attachment-0002.html>


More information about the Discuss mailing list