cnccoder 0.2.0

A library for generating gcode operations targeted for GRBL controled cnc machines, and also generates camotics projects for simulation
Documentation
//! Easy to use ready made programs that each takes a measurement struct and
//! can output the full G-code.
//!
//! When working with CNC routing there are some steps that is often needed
//! again and again, like planing surfaces for example, the intention is to
//! gather automated instructions for several of these kinds of tasks in this
//! module.
//!
//! Hopefully this module will grow with time to provide a larger set of
//! useful programs.
//!
//! The gcode can be generated by running `program.to_gcode()?` or by passing
//! it to [filesystem::write_project](../filesystem/fn.write_project.html).
//!
//! You can also combine/merge two or more programs using the
//! [.merge(program)](../program/struct.Program.html#method.merge) method.
//!
//! Example for the planing program:
//! ```
//! use anyhow::Result;
//! use cnccoder::prelude::*;
//!
//! fn main() -> Result<()> {
//!     let measurements = PlaningMeasurements {
//!         x_length: 100.0,
//!         y_length: 100.0,
//!         z_start: 3.0,
//!         z_end: 0.0,
//!         z_max_step: 1.0,
//!         units: Units::Metric
//!     };
//!
//!     let tool = Tool::cylindrical(
//!         Units::Metric,
//!         20.0,
//!         10.0,
//!         Direction::Clockwise,
//!         20000.0,
//!         5000.0,
//!     );
//!
//!     let mut program = planing(tool, measurements);
//!     program.set_name("Peng");
//!
//!     write_project(&program, 0.5)?;
//!
//!     Ok(())
//! }
//! ```

mod planing;
pub use planing::*;