PHPackages                             nielsiano/dmpl-builder - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. nielsiano/dmpl-builder

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

nielsiano/dmpl-builder
======================

Compile machine instructions in DM/PL format for plotters and printers.

1.0.1(10y ago)11279MITPHP ~7.0

Since May 28Compare

[ Source](https://github.com/nielsiano/dmpl-builder)[ Packagist](https://packagist.org/packages/nielsiano/dmpl-builder)[ Docs](https://github.com/nielsiano/dmpl-builder)[ RSS](/packages/nielsiano-dmpl-builder/feed)WikiDiscussions Synced 2w ago

READMEChangelog (2)Dependencies (2)Versions (3)Used By (0)

DmplBuilder
===========

[](#dmplbuilder)

[![Latest Version on Packagist](https://camo.githubusercontent.com/fc69e31379d237ce0450b6a4a65c7569fd2f03fb90fd4d1e7ab60502e42f13cd/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6e69656c7369616e6f2f646d706c2d6275696c6465722e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/nielsiano/dmpl-builder)[![Software License](https://camo.githubusercontent.com/55c0218c8f8009f06ad4ddae837ddd05301481fcf0dff8e0ed9dadda8780713e/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d627269676874677265656e2e7376673f7374796c653d666c61742d737175617265)](LICENSE.md)[![Build Status](https://camo.githubusercontent.com/9c6a30d655f135d18aefea5eb19d6543fcdd1b1ce9a2d42a31cd4c33d54344be/68747470733a2f2f696d672e736869656c64732e696f2f7472617669732f6e69656c7369616e6f2f646d706c2d6275696c6465722f6d61737465722e7376673f7374796c653d666c61742d737175617265)](https://travis-ci.org/nielsiano/dmpl-builder)[![Coverage Status](https://camo.githubusercontent.com/e2ce3dd957478aa77d8ff6e87d5abe1e79a7b46097491e5113abcc95b60732d8/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f636f7665726167652f672f6e69656c7369616e6f2f646d706c2d6275696c6465722e7376673f7374796c653d666c61742d737175617265)](https://scrutinizer-ci.com/g/nielsiano/dmpl-builder/code-structure)[![Quality Score](https://camo.githubusercontent.com/468891b26d755349bf02b0fb92daa66cabd7b1d0c7dd6bf7fe1afaea8da14565/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f672f6e69656c7369616e6f2f646d706c2d6275696c6465722e7376673f7374796c653d666c61742d737175617265)](https://scrutinizer-ci.com/g/nielsiano/dmpl-builder)[![SensioLabsInsight](https://camo.githubusercontent.com/f491629aa152de8fce22a0b4946189fb74db99c87f1117e63d2ba9e94530de6f/68747470733a2f2f696d672e736869656c64732e696f2f73656e73696f6c6162732f692f35623433653063662d353064302d346139332d616337612d3339356232653231346335322e7376673f7374796c653d666c61742d737175617265)](https://insight.sensiolabs.com/projects/5b43e0cf-50d0-4a93-ac7a-395b2e214c52)[![Total Downloads](https://camo.githubusercontent.com/cb244d460caa919a559123ae31b28f5ce6b9795ffb0de387043b897ce911584e/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f6e69656c7369616e6f2f646d706c2d6275696c6465722e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/nielsiano/dmpl-builder)

DmplBuilder eases the process of creating DM/PL command instructions used for hardware pen plotters and cutters. Read more about the specific commands in this [very modern manual](https://www.summa.be/download/dmp-40v.pdf) by Summa.

Install
-------

[](#install)

Via Composer

```
$ composer require nielsiano/dmpl-builder
```

Requirements
------------

[](#requirements)

The following versions of PHP are supported by this version.

- PHP 7.0

Usage
-----

[](#usage)

DmplBuilder uses a fluent interface to chain all commands and plots before compiling the final instructions.

```
$builder = new Nielsiano\DmplBuilder();

$builder->penUp()
        ->plot(200, 200)
        ->penDown()
        ->velocity(100)
        ->flexCut()
        ->plot(0, 1400)
        ->plot(1900, 0)
        ->plot(0, -1400)
        ->plot(-1900, 0)
        ->penUp()
        ->cutOff();

return $builder->compile();
```

Sending the generated DM/PL instructions to your plotter through USB can be done like so:

```
echo ';: ECM,U H L0,P0;A100,100,V10;BP50;D,0,1400,1900,0,e' > /dev/usb/lp0
```

Available methods at the moment:

```
$builder->penUp()
$builder->cutOff()
$builder->penDown()
$builder->flexCut()
$builder->flipAxes()
$builder->regularCut()
$builder->changePen(int $pen)
$builder->plot(int $x, int $y)
$builder->compile(): string
$builder->setMeasuringUnit($unit)
$builder->velocity(int $velocity)
$builder->pressure(int $gramPressure)
$builder->pushCommand(string $command)
```

Change log
----------

[](#change-log)

Please see [CHANGELOG](CHANGELOG.md) for more information what has changed recently.

Testing
-------

[](#testing)

```
$ phpunit
```

Contributing
------------

[](#contributing)

Please see [CONTRIBUTING](CONTRIBUTING.md) for details.

Security
--------

[](#security)

If you discover any security related issues, please email  instead of using the issue tracker.

Credits
-------

[](#credits)

- [Niels Stampe](https://github.com/nielsiano)
- [Christian Rishøj](https://github.com/crishoj)
- [Audio Visionary Music](https://github.com/audiovisionarymusic)
- [All Contributors](../../contributors)

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

###  Health Score

29

—

LowBetter than 57% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity18

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity59

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 72.5% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~3 days

Total

2

Last Release

3725d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/947684?v=4)[Niels Skovrup Stampe](/maintainers/nielsiano)[@nielsiano](https://github.com/nielsiano)

---

Top Contributors

[![nielsiano](https://avatars.githubusercontent.com/u/947684?v=4)](https://github.com/nielsiano "nielsiano (29 commits)")[![crishoj](https://avatars.githubusercontent.com/u/20393?v=4)](https://github.com/crishoj "crishoj (11 commits)")

---

Tags

NielsianoNielsStampeDmplBuilderdmplsummasummacutplotter

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/nielsiano-dmpl-builder/health.svg)

```
[![Health](https://phpackages.com/badges/nielsiano-dmpl-builder/health.svg)](https://phpackages.com/packages/nielsiano-dmpl-builder)
```

###  Alternatives

[google/cloud-core

Google Cloud PHP shared dependency, providing functionality useful to all components.

346137.0M126](/packages/google-cloud-core)[livewire/flux

The official UI component library for Livewire.

9628.9M150](/packages/livewire-flux)[mediumjs/mediumjs

A tiny JavaScript library for making contenteditable beautiful (Like Medium's editor).

4.4k139.8k2](/packages/mediumjs-mediumjs)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
