scaling with OpenScad, Cura, and Repetier

classic Classic list List threaded Threaded
9 messages Options
Reply | Threaded
Open this post in threaded view
|

scaling with OpenScad, Cura, and Repetier

jordanthompson
Hi all,
I am trying to wrap my head around this:
Since OpenScad doesn't support units, how do you print a correctly-sized
model?  I am trying to make some feet for a food processor and they need to
fit into the 1/4 inch (sorry, its easier for me to think in inches) hole.

I am using Cura slicer and Repetier.

thanks in advance for your help



--
Sent from: http://forum.openscad.org/

_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
Reply | Threaded
Open this post in threaded view
|

Re: scaling with OpenScad, Cura, and Repetier

OpenSCAD mailing list-2
jordanthompson wrote:

>Since OpenScad doesn't support units, how do you print a correctly-sized
>model?  I am trying to make some feet for a food processor and they need to
>fit into the 1/4 inch (sorry, its easier for me to think in inches) hole.

I've just always assumed the measure in OpenSCAD was millimeters and exports have always matched up dimensionally on that basis --- should that not work?

So, 3.175 radius and 6.35 diameter (but see the discussions about making holes match based on orientation and so forth)

William




_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
Reply | Threaded
Open this post in threaded view
|

Re: scaling with OpenScad, Cura, and Repetier

nophead
Openscad is unitless, so whatever numbers you put in the scad file go into the STL file. STL is also unitless but slicers default to interpreting the numbers as mm.

On Sun, 23 Aug 2020 at 16:18, William F. Adams via Discuss <[hidden email]> wrote:
jordanthompson wrote:

>Since OpenScad doesn't support units, how do you print a correctly-sized
>model?  I am trying to make some feet for a food processor and they need to
>fit into the 1/4 inch (sorry, its easier for me to think in inches) hole.

I've just always assumed the measure in OpenSCAD was millimeters and exports have always matched up dimensionally on that basis --- should that not work?

So, 3.175 radius and 6.35 diameter (but see the discussions about making holes match based on orientation and so forth)

William



_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org

_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
Reply | Threaded
Open this post in threaded view
|

Re: scaling with OpenScad, Cura, and Repetier

MichaelAtOz
Administrator
In reply to this post by jordanthompson
You then have:

inch=25.4;
...
holeDiameter=0.25*inch;  // or =1/4*inch if you prefer

IMHO better than trying to get your toolchain into imperial.

> -----Original Message-----
> From: Discuss [mailto:[hidden email]] On Behalf Of jordanthompson
> Sent: Mon, 24 Aug 2020 01:12
> To: [hidden email]
> Subject: [OpenSCAD] scaling with OpenScad, Cura, and Repetier
>
> Hi all,
> I am trying to wrap my head around this:
> Since OpenScad doesn't support units, how do you print a correctly-sized
> model?  I am trying to make some feet for a food processor and they need to
> fit into the 1/4 inch (sorry, its easier for me to think in inches) hole.
>
> I am using Cura slicer and Repetier.
>
> thanks in advance for your help
>
>
>
> --
> Sent from: http://forum.openscad.org/
>
> _______________________________________________
> OpenSCAD mailing list
> [hidden email]
> http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org


--
This email has been checked for viruses by AVG.
https://www.avg.com


_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
OpenSCAD Admin - email* me if you need anything, or if I've done something stupid...
* on the Forum, click on my MichaelAtOz label, there is a link to email me.

Unless specifically shown otherwise above, my contribution is in the Public Domain;
to the extent possible under law, I have waived all copyright and related or neighbouring rights to this work.
Obviously inclusion of works of previous authors is not included in the above.
Reply | Threaded
Open this post in threaded view
|

Re: scaling with OpenScad, Cura, and Repetier

jordanthompson
In reply to this post by OpenSCAD mailing list-2
That is what I wound up doing but it surprised me that literally EVERYWHERE I
read, OpenScad was unit-less.  
In fact (at least with Cura and Repetier on my modified Davinci 1.0a) 1 unit
= 1 mm.  So to convert to inches:

2.54 in/cm *10 mm/cm = 25.4 mm/in

I now have:
2.54 * 10 = inches;

// 1/4 in sphere:
sphere(r=1/4*inches);

thanks for helping me clear this up!



--
Sent from: http://forum.openscad.org/

_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
Reply | Threaded
Open this post in threaded view
|

Re: scaling with OpenScad, Cura, and Repetier

acwest
Openscad only has one output format, stl, which is unitless. It is worth noting that it works in geometric shapes, which are also unitless... 

On Mon, 24 Aug 2020, 10:44 jordanthompson, <[hidden email]> wrote:
That is what I wound up doing but it surprised me that literally EVERYWHERE I
read, OpenScad was unit-less. 
In fact (at least with Cura and Repetier on my modified Davinci 1.0a) 1 unit
= 1 mm.  So to convert to inches:

2.54 in/cm *10 mm/cm = 25.4 mm/in

I now have:
2.54 * 10 = inches;

// 1/4 in sphere:
sphere(r=1/4*inches);

thanks for helping me clear this up!



--
Sent from: http://forum.openscad.org/

_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org

_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
Reply | Threaded
Open this post in threaded view
|

Re: scaling with OpenScad, Cura, and Repetier

jordanthompson
In reply to this post by MichaelAtOz
I just read this and it is exactly what I wound up doing earlier.  Thanks
very much for your help



--
Sent from: http://forum.openscad.org/

_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
Reply | Threaded
Open this post in threaded view
|

Re: scaling with OpenScad, Cura, and Repetier

doug.moen
In reply to this post by acwest

Openscad only has one output format, stl, which is unitless. It is worth noting that it works in geometric shapes, which are also unitless... 

OpenSCAD has many output formats.

For STL export, there is no way to specify units of measurement. Some people say that STL is unitless, but the defacto standard is to interpret the units as millimeters.

For 3MF export, if you don't specify a unit of measurement, it defaults to millimeters. Therefore, OpenSCAD uses millimeters when exporting to 3MF.

For SVG export, OpenSCAD explicitly sets the unit of measurement to be millimeters, even though specifying the unit of measurement is optional.

_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
Reply | Threaded
Open this post in threaded view
|

Re: scaling with OpenScad, Cura, and Repetier

RayBellis
In reply to this post by jordanthompson


On 24/08/2020 15:44, jordanthompson wrote:

> That is what I wound up doing but it surprised me that literally EVERYWHERE I
> read, OpenScad was unit-less.  
> In fact (at least with Cura and Repetier on my modified Davinci 1.0a) 1 unit
> = 1 mm.  So to convert to inches:
>
> 2.54 in/cm *10 mm/cm = 25.4 mm/in
>
> I now have:
> 2.54 * 10 = inches;
>
> // 1/4 in sphere:
> sphere(r=1/4*inches);
>
> thanks for helping me clear this up!

You could always just build your model as if the units are inches, and
then perform one single "scale" operation at the end when you
instantiate the model:

  module my_model() {
    // definite geometry here with 1" units
    ...
  }

  // scale up for slicer compatibility
  scale(inches) my_model();

This removes the need to repeatedly use "* inches" throughout the model.

Ray

_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org