abey79 / vpype

The Swiss-Army-knife command-line tool for plotter vector graphics.
https://vpype.readthedocs.io/
MIT License
702 stars 61 forks source link

New Feature: Add DM/PL as output format #522

Closed OzHawk closed 1 year ago

OzHawk commented 2 years ago

The current implementation of vpype only allows SVG or HPGL output. To support Houston Instrument plotters that do not have HPGL compatibility mode, DM/PL format output should be added as an option for 'write' functionality. The document "DM/PL Command Language", Houston Instruments, Copyright 1984, describes the complete language command structure/protocol.

abey79 commented 2 years ago

Please try to implement this as a vpype-gcode profile. In the future, I don't plan on "hard-coding" new output format in vpype. Instead, the plan is to integrate vpype-gcode and its profiles.

OzHawk commented 2 years ago

I'll have a look at implementing it as you suggested. I had it implemented in parallel to the HPGL code this morning, but lost the change when I tried to commit it. Not sure where it ended up. I was trying to use gitpod to develop. Can the vpype-gcode access the device configuration the same as the HPGL code does? How is it best to develop, but forking my own branch, or working from your repository?

abey79 commented 2 years ago

What do you mean by "device configuration"? With vpype-gcode, you can simply create a profile in a ~/.vpype.toml config file.

abey79 commented 2 years ago

As for your question on developing on vpype, the best is to fork on GitHub, checkout on your computer, make a branch and commit to your fork, and the create a pull request.

OzHawk commented 2 years ago

The "device" configuration I was referring to is in vpype_config.toml. The differences between the HPGL devices can be configured here.

OzHawk commented 2 years ago

One of the significant differences between GCode and HPGL and DM/PL is the units. GCode uses real world units, where as HPGL and DM/PL use plotter units which map to real world units via a step size. How do you envisage this difference being implemented within vpype-gcode? Thanks

abey79 commented 2 years ago

You can make any number of vpype-profiles too, so you can cover multiple devices if needed.

vpype-gcode lets you specify which units you want to work with, as well as offsets and axes orientation (see this section of the readme).

ithinkido commented 2 years ago

One of the significant differences between GCode and HPGL and DM/PL is the units. GCode uses real world units, where as HPGL and DM/PL use plotter units which map to real world units via a step size. How do you envisage this difference being implemented within vpype-gcode? Thanks

These profiles were made for HPGL as well as non HPGL plotters. using vpype-gcode

You can use these as a base to understand what you need. They cover both non standard commands and non standard units.

abey79 commented 1 year ago

Closing this as it is addressed by vpype-gcode.