aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFranklin Wei <franklin@rockbox.org>2019-12-25 21:13:19 -0500
committerFranklin Wei <franklin@rockbox.org>2019-12-25 21:13:19 -0500
commit9c4e5bb77054b4115c03c8a60f9b5304ab985125 (patch)
treeaa809c4e52947639b06b4dee15bb55b46c7d9456
parentd3e2a6b089740b774d47beadfa684f5d0c59c254 (diff)
downloadrastercarve-9c4e5bb77054b4115c03c8a60f9b5304ab985125.zip
rastercarve-9c4e5bb77054b4115c03c8a60f9b5304ab985125.tar.gz
rastercarve-9c4e5bb77054b4115c03c8a60f9b5304ab985125.tar.bz2
rastercarve-9c4e5bb77054b4115c03c8a60f9b5304ab985125.tar.xz
Update README
-rw-r--r--README.md64
1 files changed, 57 insertions, 7 deletions
diff --git a/README.md b/README.md
index 7d6647c..96faaa5 100644
--- a/README.md
+++ b/README.md
@@ -3,14 +3,64 @@
This is a little Python script I wrote to generate 3-axis toolpaths to
engrave raster images.
-## Getting Started
+## Dependencies
-You just need Python 3, OpenCV, and NumPy (i.e. `pip install ...`).
+You just need Python 3, OpenCV, tqdm, and NumPy (i.e. `pip install
+...`).
-Then, just run `python src/rastercarve.py IMAGE`, where `IMAGE` is a
-bitmap image in any format supported by OpenCV. G-code is output to
-standard output.
+## Usage
-## Configuration
+The program should be self-documenting. Run `src/rastercarve.py
+--help` or see the output below.
-Edit `rastercarve.py` to change the material and engraving settings.
+```
+usage: rastercarve.py [-h] (--width WIDTH | --height HEIGHT) [-f FEED_RATE] [-p PLUNGE_RATE] [--rapid RAPID_RATE] [-z SAFE_Z]
+ [--end-z TRAVERSE_Z] [-d MAX_DEPTH] [-t TOOL_ANGLE] [-a LINE_ANGLE] [-s STEPOVER] [-r LINEAR_RESOLUTION]
+ [--no-line-numbers] [--debug] [-q] [--version]
+ filename
+
+Generate G-code to engrave raster images.
+
+positional arguments:
+ filename input image (any OpenCV-supported format)
+
+optional arguments:
+ -h, --help show this help message and exit
+ --debug print debug messages
+ -q disable progress and statistics
+ --version show program's version number and exit
+
+output dimensions:
+ Exactly one required.
+
+ --width WIDTH output width (in)
+ --height HEIGHT output height (in)
+
+machine configuration:
+ -f FEED_RATE engraving feed rate (in/min) (default: 100)
+ -p PLUNGE_RATE engraving plunge rate (in/min) (default: 30)
+ --rapid RAPID_RATE rapid traverse rate (for time estimation only) (default: 240)
+ -z SAFE_Z rapid Z traverse height (in) (default: 0.1)
+ --end-z TRAVERSE_Z Z height of final traverse (in) (default: 2)
+ -d MAX_DEPTH maximum engraving depth (in) (default: 0.08)
+ -t TOOL_ANGLE included angle of tool (deg) (default: 30)
+
+engraving parameters:
+ -a LINE_ANGLE angle of grooves from horizontal (deg) (default: 22.5)
+ -s STEPOVER stepover percentage (affects spacing between lines) (default: 110)
+ -r LINEAR_RESOLUTION distance between successive G-code points (in) (default: 0.01)
+
+G-code parameters:
+ --no-line-numbers suppress G-code line numbers (dangerous on ShopBot!)
+
+Defaults are usually safe to leave unchanged.
+```
+
+### Examples
+
+```
+python src/rastercarve.py --width 10 examples/test.png > out.nc
+```
+
+Generate G-code to engrave `examples/test.png` into an image 10 inches
+wide. Output will be piped from stdout to `out.nc`.