omdl  v0.9.5
OpenSCAD Mechanical Design Library
docs_start.scad
Go to the documentation of this file.
1 //! Library documentation start page.
2 /***************************************************************************//**
3  \file
4  \author Roy Allen Sutton
5  \date 2015-2024
6 
7  \copyright
8 
9  This file is part of [omdl] (https://github.com/royasutton/omdl),
10  an OpenSCAD mechanical design library.
11 
12  The \em omdl is free software; you can redistribute it and/or modify
13  it under the terms of the [GNU Lesser General Public License]
14  (http://www.gnu.org/licenses/lgpl.html) as published by the Free
15  Software Foundation; either version 2.1 of the License, or (at
16  your option) any later version.
17 
18  The \em omdl is distributed in the hope that it will be useful,
19  but WITHOUT ANY WARRANTY; without even the implied warranty of
20  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
21  Lesser General Public License for more details.
22 
23  You should have received a copy of the GNU Lesser General Public
24  License along with the \em omdl; if not, write to the Free Software
25  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
26  02110-1301, USA; or see <http://www.gnu.org/licenses/>.
27 
28 *******************************************************************************/
29 
30 //----------------------------------------------------------------------------//
31 // introduction.
32 //----------------------------------------------------------------------------//
33 
34 /***************************************************************************//**
35  \mainpage Introduction
36  \tableofcontents
37 
38  \anchor introduction
39 
40  [omdl] is an [OpenSCAD] mechanical design library that provides
41  open-source high-level design primitives with coherent
42  documentation generated by [Doxygen] using [openscad-amu].
43 
44  With Doxygen, the code documentation is written within the code
45  itself, and is thus easy to keep current. Moreover, it provides a
46  standard way to both write and present OpenSCAD design
47  documentation, compilable to common output formats (html, pdf,
48  etc). With [omdl], all library primitives are \em parametric with
49  minimal, mostly zero, global variable dependencies and all library
50  API's include [markups] that describe its parameters, behavior, and
51  use.
52 
53  [Validation] scripts are used to verify that the core operations
54  work as expected across evolving [OpenSCAD] versions. This
55  validation is performed when building and [installing] the library
56  documentation). The library uses a common set of conventions for
57  specifying [data types] and is divided into individual component
58  modules of functionality, organized into groups, that may be
59  included as desired.
60 
61  \section starting Getting Started
62 
63  \amu_define title (Hello world)
64  \amu_define image_views (right top front diag)
65  \amu_define image_size (sxga)
66  \amu_define image_columns (4)
67  \amu_define scope_id (quickstart)
68  \amu_define notes_scad
69  ( The \ref make_bearing_linear_rod operations can be used to
70  transform 2D and 3D objects into 3D-printable linear rod
71  bearings with arbitrary bearing-ball and rod sizes. )
72  \amu_define notes_diagrams
73  ( Click image above to expand. See the end of ${FILE_NAME} in the
74  scope [ \em ${scope_id} ] for the the dimension operations used
75  in the above example. )
76 
77  \amu_include (include/amu/scope_diagrams_3d.amu)
78 
79  \section contributing Contributing
80 
81  [omdl] uses [git] for development tracking, and is hosted on
82  [GitHub] following the usual practice of [forking] and submitting
83  [pull requests] to the source repository.
84 
85  As it is released under the [GNU Lesser General Public License],
86  any file you change should bear your copyright notice alongside the
87  original authors' copyright notices typically located at the top of
88  each file.
89 
90  Ideas, requests, comments, contributions, and constructive
91  criticism are welcome.
92 
93  \section support Support
94 
95  In case you have any questions or would like to make feature
96  requests, you can contact the maintainer of the project or file an
97  [issue].
98 
99 
100  [GNU Lesser General Public License]: https://www.gnu.org/licenses/lgpl.html
101 
102  [omdl]: https://royasutton.github.io/omdl
103  [omdl repository]: https://github.com/royasutton/omdl
104  [issue]: https://github.com/royasutton/omdl/issues
105 
106  [Validation]: \ref tv
107  [data types]: \ref dt
108  [installing]: \ref lb
109 
110  [openscad-amu]: https://royasutton.github.io/openscad-amu
111 
112  [Doxygen]: http://www.doxygen.nl
113  [markups]: http://www.doxygen.nl/manual/commands.html
114 
115  [OpenSCAD]: http://www.openscad.org
116 
117  [git]: http://git-scm.com
118  [GitHub]: http://github.com
119  [forking]: http://help.github.com/forking
120  [pull requests]: https://help.github.com/articles/about-pull-requests
121 *******************************************************************************/
122 
123 //----------------------------------------------------------------------------//
124 // openscad-amu auxiliary scripts
125 //----------------------------------------------------------------------------//
126 
127 /*
128 BEGIN_SCOPE logo;
129  BEGIN_OPENSCAD;
130  include <omdl-base.scad>;
131 
132  s = 10;
133 
134  fs = [3, 5, 4] * s;
135  cs = fs * 2 / 3;
136  vr = [4, 2, 1]/10 * s;
137 
138  ft = triangle2d_sss2ppp(fs);
139  ct = triangle2d_sss2ppp(cs);
140 
141  cone( h=s*2, r=s, vr=2/10*s );
142  rotate([0, 0, 360/20])
143  repeat_radial( n=5, angle=true )
144  extrude_linear_mss( h=s )
145  translate(triangle_centroid(ft) + [-15,2]/s)
146  difference()
147  {
148  translate(-triangle_centroid(ft))
149  polygon( polygon_round_eve_all_p(ft, vr=vr) );
150  translate(-triangle_centroid(ct))
151  polygon( polygon_round_eve_all_p(ct, vr=vr) );
152  }
153  END_OPENSCAD;
154 
155  BEGIN_MFSCRIPT;
156  include --path "${INCLUDE_PATH}" {var_init,var_gen_png2eps}.mfs;
157 
158  views name "views" distance "250" views "top";
159  images name "slogo" aspect "1:1" xsizes "55";
160  variables set_opts_combine "views slogo";
161 
162  include --path "${INCLUDE_PATH}" scr_make_mf.mfs;
163  END_MFSCRIPT;
164 END_SCOPE;
165 
166 BEGIN_SCOPE quickstart;
167  BEGIN_OPENSCAD;
168  include <omdl-base.scad>;
169  include <tools/operation_cs.scad>;
170  include <tools/drafting/draft-base.scad>;
171  include <parts/3d/bearing/bearing_linear_rod.scad>;
172 
173  $fn = 36;
174 
175  p = [length(0.706, "in"), length(0.622, "in")];
176  b = length(6, "mm");
177 
178  r = 21.5; c = 6; a = 85;
179  h = [b*8, undef, false];
180 
181  v = is_undef ( __mfs__diag ) ? 2: undef;
182 
183  make_bearing_linear_rod(pipe=p, ball=b, count=c, angle=a, h=h, align=4, view=v)
184  minkowski() {cylinder(r=r-b*2/3, h=first(h)-b*3/2, center=true); sphere(r=r/5);};
185 
186  // end_include
187 
188  if ( !is_undef(__mfs__top) ) color("brown"){
189  draft_dim_center(r=r);
190  draft_dim_radius(r=r, v=[+1,-1], u="mm");
191  draft_dim_line(p1=[-r,0], p2=[+r,0], d=r*1.25, u ="mm");
192  draft_dim_line(p1=[-first(p)/2,0], p2=[+first(p)/2,0], d=r*3/4, u ="mm");
193  }
194 
195  if ( !is_undef(__mfs__front) ) color("brown") rotate([90,0,0]) {
196  draft_dim_line(p1=[-r,0], p2=[+r,0], d=r*3/4, u ="mm");
197  draft_dim_line(p1=[-first(p)/2,0], p2=[+first(p)/2,0], u ="mm");
198  draft_dim_line(p1=[0,0], p2=[0,-first(h)], d=+r*1.25, u ="mm");
199  draft_dim_leader(p=[-r+r/20,-r/15], v1=135, v2=180, l1=7, l2=7, t="r/5", tr=0, s=2);
200  }
201 
202  END_OPENSCAD;
203 
204  BEGIN_MFSCRIPT;
205  include --path "${INCLUDE_PATH}" {var_init,var_gen_png2eps}.mfs;
206  table_unset_all sizes;
207 
208  images name "sizes" types "sxga";
209  views name "views" views "diag front right top";
210 
211  variables set_opts_combine "sizes views";
212  variables add_opts "--viewall --autocenter --view=axes";
213 
214  include --path "${INCLUDE_PATH}" scr_make_mf.mfs;
215  END_MFSCRIPT;
216 END_SCOPE;
217 */
218 
219 //----------------------------------------------------------------------------//
220 // end of file
221 //----------------------------------------------------------------------------//