A G-code virtual machine and post-processing DSL.
- Ruby v3.0 to v3.3
To use this gem, include it in your Gemfile.
gem 'gcode-vm', git: '[email protected]:jtran/gcode-vm.git'
Then install it.
bundle install
First, make a transform file, my_transform.yml
, that specifies how to
transform a toolpath.
version: '1'
transform:
# Strip line-ending characters.
- chomp
# Change all B axis movements to D axis movements.
- name: rename_axis
from: B
to: D
See examples/demo.yml
for more transforms.
Then transform your G-code toolpath using your specification.
transform -t my_transform.yml thing.gcode > thing_transformed.gcode
rake test