| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279 |
- <!DOCTYPE html>
- <!--[if IE 8]><html class="no-js lt-ie9" lang="en" > <![endif]-->
- <!--[if gt IE 8]><!--> <html class="no-js" lang="en" > <!--<![endif]-->
- <head>
- <meta charset="utf-8">
- <meta name="viewport" content="width=device-width, initial-scale=1.0">
-
- <title>Shell Command Line Interface — FlatCAM 7 documentation</title>
-
-
-
-
- <link href='https://fonts.googleapis.com/css?family=Lato:400,700|Roboto+Slab:400,700|Inconsolata:400,700' rel='stylesheet' type='text/css'>
-
-
- <script type="text/javascript">
- var DOCUMENTATION_OPTIONS = {
- URL_ROOT:'./',
- VERSION:'7',
- COLLAPSE_INDEX:false,
- FILE_SUFFIX:'.html',
- HAS_SOURCE: true
- };
- </script>
- <script type="text/javascript" src="_static/jquery.js"></script>
- <script type="text/javascript" src="_static/underscore.js"></script>
- <script type="text/javascript" src="_static/doctools.js"></script>
- <script type="text/javascript" src="http://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML"></script>
-
-
-
-
- <link rel="stylesheet" href="_static/css/theme.css" type="text/css" />
- <script type="text/javascript" src="_static/js/theme.js"></script>
-
-
-
- <script type="text/javascript">
- jQuery(function () {
- SphinxRtdTheme.StickyNav.enable();
- });
- </script>
-
-
- <link rel="top" title="FlatCAM 7 documentation" href="index.html"/>
- <link rel="next" title="Shell Command Reference" href="cmdreference.html"/>
- <link rel="prev" title="Geometry Editor" href="editor.html"/>
- <script src="https://cdnjs.cloudflare.com/ajax/libs/modernizr/2.6.2/modernizr.min.js"></script>
- <script>
- (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
- (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
- m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
- })(window,document,'script','//www.google-analytics.com/analytics.js','ga');
- ga('create', 'UA-55008703-1', 'auto');
- ga('send', 'pageview');
- </script>
- </head>
- <body class="wy-body-for-nav" role="document">
- <div class="wy-grid-for-nav">
-
- <nav data-toggle="wy-nav-shift" class="wy-nav-side">
- <div class="wy-side-nav-search" style="background-color: #3d3d3d;">
- <!--<a href="index.html" class="icon icon-home"> FlatCAM</a>-->
- <!--<a href="http://flatcam.org" class="icon icon-home"> FlatCAM</a>-->
- <a href="http://flatcam.org">
- <img src="http://flatcam.org/static/images/fcweblogo1.png"
- style="height: auto;
- width: auto;
- border-radius: 0px;
- background-color: #3d3d3d;
- margin: auto">
- </a>
- <div role="search">
- <form id ="rtd-search-form" class="wy-form" action="search.html" method="get">
- <input type="text" name="q" placeholder="Search docs" />
- <input type="hidden" name="check_keywords" value="yes" />
- <input type="hidden" name="area" value="default" />
- </form>
- </div>
- </div>
- <div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="main navigation">
-
-
- <ul class="current">
- <li class="toctree-l1"><a class="reference internal" href="introduction.html">Introduction</a></li>
- <li class="toctree-l1"><a class="reference internal" href="installation.html">Installation</a><ul>
- <li class="toctree-l2"><a class="reference internal" href="installation.html#windows-installer">Windows Installer</a></li>
- <li class="toctree-l2"><a class="reference internal" href="installation.html#ubuntu">Ubuntu</a></li>
- <li class="toctree-l2"><a class="reference internal" href="installation.html#manual-installation">Manual Installation</a></li>
- </ul>
- </li>
- <li class="toctree-l1"><a class="reference internal" href="basics.html">Basics</a><ul>
- <li class="toctree-l2"><a class="reference internal" href="basics.html#source-files">Source Files</a></li>
- <li class="toctree-l2"><a class="reference internal" href="basics.html#objects-and-tasks">Objects and Tasks</a></li>
- <li class="toctree-l2"><a class="reference internal" href="basics.html#creating-saving-and-loading-projects">Creating, Saving and Loading Projects</a></li>
- <li class="toctree-l2"><a class="reference internal" href="basics.html#navigating-plots">Navigating Plots</a></li>
- </ul>
- </li>
- <li class="toctree-l1"><a class="reference internal" href="procedures.html">Common Procedures</a><ul>
- <li class="toctree-l2"><a class="reference internal" href="procedures.html#isolation-routing">Isolation Routing</a></li>
- <li class="toctree-l2"><a class="reference internal" href="procedures.html#wide-isolation-routing">Wide Isolation Routing</a></li>
- <li class="toctree-l2"><a class="reference internal" href="procedures.html#cnc-jobs-for-drill-files">CNC Jobs for Drill Files</a></li>
- <li class="toctree-l2"><a class="reference internal" href="procedures.html#side-pcb">2-side PCB</a></li>
- <li class="toctree-l2"><a class="reference internal" href="procedures.html#copper-area-clear">Copper Area Clear</a></li>
- <li class="toctree-l2"><a class="reference internal" href="procedures.html#board-cutout">Board Cutout</a></li>
- <li class="toctree-l2"><a class="reference internal" href="procedures.html#bed-flattening">Bed Flattening</a></li>
- </ul>
- </li>
- <li class="toctree-l1"><a class="reference internal" href="editor.html">Geometry Editor</a><ul>
- <li class="toctree-l2"><a class="reference internal" href="editor.html#introduction">Introduction</a></li>
- <li class="toctree-l2"><a class="reference internal" href="editor.html#creating-new-geometry-objects">Creating New Geometry Objects</a></li>
- <li class="toctree-l2"><a class="reference internal" href="editor.html#editing-existing-geometry-objects">Editing Existing Geometry Objects</a></li>
- </ul>
- </li>
- <li class="toctree-l1 current"><a class="current reference internal" href="">Shell Command Line Interface</a><ul>
- <li class="toctree-l2"><a class="reference internal" href="#the-shell-window">The Shell Window</a></li>
- <li class="toctree-l2"><a class="reference internal" href="#shell-language">Shell Language</a></li>
- </ul>
- </li>
- <li class="toctree-l1"><a class="reference internal" href="cmdreference.html">Shell Command Reference</a><ul>
- <li class="toctree-l2"><a class="reference internal" href="cmdreference.html#add-circle">add_circle</a></li>
- <li class="toctree-l2"><a class="reference internal" href="cmdreference.html#add-poly">add_poly</a></li>
- <li class="toctree-l2"><a class="reference internal" href="cmdreference.html#add-rect">add_rect</a></li>
- <li class="toctree-l2"><a class="reference internal" href="cmdreference.html#cncjob">cncjob</a></li>
- <li class="toctree-l2"><a class="reference internal" href="cmdreference.html#delete">delete</a></li>
- <li class="toctree-l2"><a class="reference internal" href="cmdreference.html#follow">follow</a></li>
- <li class="toctree-l2"><a class="reference internal" href="cmdreference.html#geo-union">geo_union</a></li>
- <li class="toctree-l2"><a class="reference internal" href="cmdreference.html#get-names">get_names</a></li>
- <li class="toctree-l2"><a class="reference internal" href="cmdreference.html#help">help</a></li>
- <li class="toctree-l2"><a class="reference internal" href="cmdreference.html#isolate">isolate</a></li>
- <li class="toctree-l2"><a class="reference internal" href="cmdreference.html#make-docs">make_docs</a></li>
- <li class="toctree-l2"><a class="reference internal" href="cmdreference.html#new">new</a></li>
- <li class="toctree-l2"><a class="reference internal" href="cmdreference.html#new-geometry">new_geometry</a></li>
- <li class="toctree-l2"><a class="reference internal" href="cmdreference.html#offset">offset</a></li>
- <li class="toctree-l2"><a class="reference internal" href="cmdreference.html#open-excellon">open_excellon</a></li>
- <li class="toctree-l2"><a class="reference internal" href="cmdreference.html#open-gcode">open_gcode</a></li>
- <li class="toctree-l2"><a class="reference internal" href="cmdreference.html#open-gerber">open_gerber</a></li>
- <li class="toctree-l2"><a class="reference internal" href="cmdreference.html#open-project">open_project</a></li>
- <li class="toctree-l2"><a class="reference internal" href="cmdreference.html#options">options</a></li>
- <li class="toctree-l2"><a class="reference internal" href="cmdreference.html#paint-poly">paint_poly</a></li>
- <li class="toctree-l2"><a class="reference internal" href="cmdreference.html#plot">plot</a></li>
- <li class="toctree-l2"><a class="reference internal" href="cmdreference.html#save-project">save_project</a></li>
- <li class="toctree-l2"><a class="reference internal" href="cmdreference.html#scale">scale</a></li>
- <li class="toctree-l2"><a class="reference internal" href="cmdreference.html#set-active">set_active</a></li>
- <li class="toctree-l2"><a class="reference internal" href="cmdreference.html#write-gcode">write_gcode</a></li>
- </ul>
- </li>
- </ul>
-
- </div>
-
- </nav>
- <section data-toggle="wy-nav-shift" class="wy-nav-content-wrap">
-
- <nav class="wy-nav-top" role="navigation" aria-label="top navigation">
- <i data-toggle="wy-nav-top" class="icon icon-reorder"></i>
- <a href="index.html">FlatCAM</a>
- </nav>
-
- <div class="wy-nav-content">
- <div class="rst-content">
- <div role="navigation" aria-label="breadcrumbs navigation">
- <ul class="wy-breadcrumbs">
- <li><a href="index.html">Docs</a> »</li>
-
- <li>Shell Command Line Interface</li>
- <li class="wy-breadcrumbs-aside">
-
- <a href="_sources/flatcamshell.txt" rel="nofollow"> View page source</a>
-
- </li>
- </ul>
- <hr/>
- </div>
- <div role="main">
-
- <div class="section" id="shell-command-line-interface">
- <h1>Shell Command Line Interface<a class="headerlink" href="#shell-command-line-interface" title="Permalink to this headline">¶</a></h1>
- <div class="admonition warning">
- <p class="first admonition-title">Warning</p>
- <p class="last">The FlatCAM Shell is under development and its behavior might change in the future. This includes available commands and their syntax.</p>
- </div>
- <p>The FlatCAM Shell provides a command line interface to FlatCAM’s functionalies and to the TCL language. It serves the following purposes:</p>
- <ul class="simple">
- <li>An alternative the GUI for issuing commands and visualizing data output.</li>
- <li>Scripting interface for automating large sequences of commands.</li>
- <li>A mechanism for the user to implement new functionality.</li>
- <li>A mechanism to provide detailed information to the user.</li>
- <li>Keep a record of commands and responses.</li>
- </ul>
- <div class="section" id="the-shell-window">
- <h2>The Shell Window<a class="headerlink" href="#the-shell-window" title="Permalink to this headline">¶</a></h2>
- <img alt="_images/shell.png" class="align-center" src="_images/shell.png" />
- <p>The FlatCAM Shell window is shown at startup when FlatCAM loads. It can be closed and re-opened at any time without loss of data by clicking on the close button on the top right edge of the window and selecting <strong>Tool→Command Line</strong> from the main menu respectively.</p>
- <p>It is divided into 2 sections, an output section on the top and an input section on the bottom. A record of previously issued commands is shown in the output section along with their results and other information that FlatCAM might provide. Distinction between types of data in the output section is done by color coding.</p>
- <p>To issue a command, type it in the input section and hit <tt class="docutils literal"><span class="pre">Enter</span></tt>. If the command consists of multiple lines, use <tt class="docutils literal"><span class="pre">Shift-Enter</span></tt> to insert a new line without issuing the command.</p>
- </div>
- <div class="section" id="shell-language">
- <h2>Shell Language<a class="headerlink" href="#shell-language" title="Permalink to this headline">¶</a></h2>
- <p>The Shell uses the <a class="reference external" href="https://www.tcl.tk/man/tcl8.5/tutorial/tcltutorial.html">TCL</a> language. TCL provides the simples posible syntax and requires no learning at all for isuing the basic FlatCAM commands. Nonetheless, TCL is a powerfull language that enables the users to create their own complex functionality if desired.</p>
- <p>Issuing a command is as simple as typing its name and hitting the <tt class="docutils literal"><span class="pre">Enter</span></tt> key. For example:</p>
- <div class="highlight-python"><div class="highlight"><pre><span class="n">new</span>
- </pre></div>
- </div>
- <p>This the same as clicking on <strong>File→New</strong> in the main window menu.</p>
- <p>If a command requires additional information, it is given immediately after the command name and a space. For example, to open the gerber file <tt class="docutils literal"><span class="pre">mygerber.gbr</span></tt>:</p>
- <div class="highlight-python"><pre>open_gerber mygerber.gbr</pre>
- </div>
- <p>Sometimes a command will have optional parameters, this is, if you provide it it will use it, otherwise it will use some default value. For example:</p>
- <div class="highlight-python"><pre>isolate mygerber.gbr -tooldia 0.04</pre>
- </div>
- <p>This would create isolation routing geometry for the <tt class="docutils literal"><span class="pre">mygerber.gbr</span></tt> gerber object with a tool diameter of 0.04 inches (or mm, depending on the project settings). Otherwise, if you run:</p>
- <div class="highlight-python"><pre>isolate mygerber.gbr</pre>
- </div>
- <p>The same action will be performed but the tool diameter will be taken from the default value set for that object (If it is a new object, its default values will be set from the project options.)</p>
- <p>For complete reference of FlatCAM Shell commands, see <a class="reference internal" href="cmdreference.html#cmdreference"><em>Shell Command Reference</em></a>.</p>
- </div>
- </div>
- </div>
- <footer>
-
- <div class="rst-footer-buttons" role="navigation" aria-label="footer navigation">
-
- <a href="cmdreference.html" class="btn btn-neutral float-right" title="Shell Command Reference"/>Next <span class="icon icon-circle-arrow-right"></span></a>
-
-
- <a href="editor.html" class="btn btn-neutral" title="Geometry Editor"><span class="icon icon-circle-arrow-left"></span> Previous</a>
-
- </div>
-
- <hr/>
- <div role="contentinfo">
- <p>
- © Copyright 2014, Juan Pablo Caram.
- </p>
- </div>
- <a href="https://github.com/snide/sphinx_rtd_theme">Sphinx theme</a> provided by <a href="https://readthedocs.org">Read the Docs</a>
- </footer>
- </div>
- </div>
- </section>
- </div>
-
- </body>
- </html>
|