# Printer makes only garbage from CM3

**URL:** <https://forum.clockworkpi.com/t/printer-makes-only-garbage-from-cm3/9592>\
**Category:** DevTerm\
**Created:** [February 7, 2023, 6:07am UTC](https://forum.clockworkpi.com/t/printer-makes-only-garbage-from-cm3/9592 "2023-02-07T06:07:15Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![natevw](https://yyz1.discourse-cdn.com/flex029/user_avatar/forum.clockworkpi.com/natevw/32/6877_2.png) [@natevw](https://forum.clockworkpi.com/u/natevw)\
**Post date:** [February 7, 2023, 6:07am UTC](https://forum.clockworkpi.com/t/printer-makes-only-garbage-from-cm3/9592/1 "2023-02-07T06:07:16Z")

</div>

I am having trouble getting any consistent or useful output from my DevTerm printer with a CM3 module and image installed. It prints only a short part and then either turns to random mojibake for a little, or just stops totally.

See this picture of many different attempts:

 ![PXL_20230207_053748374](https://canada1.discourse-cdn.com/flex029/uploads/clockworkpi/original/2X/e/eef52e7aed4166ed19acac39187477a9644df9f4.jpeg)

- Firefox trying to print a very simple webpage ([http://ipcalf.com](http://ipcalf.com)) it kind of gets the header but then just goes to random little wing-ding characters
- Chrome is even worse, just a short little bit of random garbage nothing like the print preview shows
- from LibreOffice Draw it kind of works but only for the first ~1mm or so and then it just stops
- even printing plain text from notepad type app or piped into `lp` it does maybe one line but then overlaps and stops and just all messed up

This is with the CM3 image on SD Card + `sudo apt update && sudo apt full-upgrade`.

Funny, with the R-01 it actually Just Worked® really well, I could print from Qutebrowser and Inkscape and pretty much anything and I’d get a reasonable tiny printout! Very fun!

But with the CM3 it is **not** any fun, just short scraps of useless random mess no matter what I try to print or what app I print from. Is there something I can try to fix this?

---

<div class="post-metadata">

**Author:** ![Petrakis](https://yyz1.discourse-cdn.com/flex029/user_avatar/forum.clockworkpi.com/petrakis/32/256_2.png) [@Petrakis](https://forum.clockworkpi.com/u/Petrakis)\
**Post date:** [February 7, 2023, 10:13am UTC](https://forum.clockworkpi.com/t/printer-makes-only-garbage-from-cm3/9592/2 "2023-02-07T10:13:02Z")

</div>

Does the test print get printed fine?

`echo -en "\x12\x54" > /tmp/DEVTERM_PRINTER_IN` This command will print the test page

---

<div class="post-metadata">

**Author:** ![natevw](https://yyz1.discourse-cdn.com/flex029/user_avatar/forum.clockworkpi.com/natevw/32/6877_2.png) [@natevw](https://forum.clockworkpi.com/u/natevw)\
**Post date:** [February 7, 2023, 5:13pm UTC](https://forum.clockworkpi.com/t/printer-makes-only-garbage-from-cm3/9592/3 "2023-02-07T17:13:47Z")

</div>

Thanks, yes the test print works. Picture is of test print which is not _perfect_ with some stripes and blotches but is basically fine overall (Fun logo, Temperature 0ºC, Firmware version 0.10, etc.)

Then in picture followed by other tests:

- `help cd | lp` repeated many times (the half lines of text)
- print of clipart file via `lp ~/Downloads/clipart1574.png` several times (the five dark blotches)
- print of clipart from browser with headers/footers on (just the “clipart157… file:///hom…” line result, the space above/below is from manually tugging on paper not the feed setting it is supposed to have!)
- print of clipart from browser with headers/footers off (the final short blotchy section pulled out manually)

 ![PXL_20230207_063059630](https://canada1.discourse-cdn.com/flex029/uploads/clockworkpi/original/2X/f/f028d9e6bcc07aa906c9535b74786a880f83a0a7.jpeg)

You can see the random clipart PNG file I found on the DevTerm screen, basically what gets printed is sort of a correct **start** but then it always just stops after a millimeter or two. (Although sometimes in earlier tests as in my first post it would either switch to random [dingbat](https://en.wikipedia.org/wiki/Dingbat) characters or other mess sometimes too.)

Update: maybe from [Printer Troubleshooting on R-01 - #4 by guu](https://forum.clockworkpi.com/t/printer-troubleshooting-on-r-01/8560/4) the printer driver does not automatically update? I can try more things tonight but as I said I did already `sudo apt update && sudo apt upgrade` and the update does fetch from the clockwork repository, just no new packages from them! And that post was re. different platform/architecture where it was working fine for me too; it’s the more common CM3 distro where it’s broken for me!)

---

<div class="post-metadata">

**Author:** ![natevw](https://yyz1.discourse-cdn.com/flex029/user_avatar/forum.clockworkpi.com/natevw/32/6877_2.png) [@natevw](https://forum.clockworkpi.com/u/natevw)\
**Post date:** [February 8, 2023, 1:59am UTC](https://forum.clockworkpi.com/t/printer-makes-only-garbage-from-cm3/9592/4 "2023-02-08T01:59:15Z")

</div>

> [@natevw](#):
>
> Update: maybe from [Printer Troubleshooting on R-01 - #4 by guu](https://forum.clockworkpi.com/t/printer-troubleshooting-on-r-01/8560/4) the printer driver does not automatically update?

No luck, it looks like I already have the latest releases for armhf/CM3:

```auto
pi@clockworkpi:~ $ apt show devterm-thermal-printer
Package: devterm-thermal-printer
Version: 0.35
Priority: optional
Section: utils
Maintainer: cuu <gnubsd@me.com>
Installed-Size: 168 kB
Depends: socat, fonts-noto-cjk
Homepage: https://github.com/clockworkpi/thermal_printer
Download-Size: 46.0 kB
APT-Manual-Installed: yes
APT-Sources: https://raw.githubusercontent.com/clockworkpi/apt/main/debian stable/main armhf Packages
Description: Thermal printer daemon for DevTerm

pi@clockworkpi:~ $ sudo apt install devterm-thermal-printer devterm-thermal-printer-cups
Reading package lists... Done
Building dependency tree
Reading state information... Done
devterm-thermal-printer is already the newest version (0.35).
devterm-thermal-printer-cups is already the newest version (0.1).
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.

```

But the armhf repository has a `devterm-thermal-printer` version ([0.35](https://github.com/clockworkpi/apt/blob/a1e9ea1/debian/dists/stable/main/binary-armhf/Packages#L162)) lower than in arm64 ([0.37](https://github.com/clockworkpi/apt/blob/86e0db3/debian/dists/stable/main/binary-arm64/Packages#L293)) and RiscV ([0.39](https://github.com/clockworkpi/apt/blob/90f9b8b/debian/dists/stable/main/binary-riscv64/Packages#L95)). Is this my problem, that Clockwork doesn’t update their distros? Or is there something else?

Did the printer just work out-of-box for everyone else on CM3 or is this a known issue?

---

<div class="post-metadata">

**Author:** ![natevw](https://yyz1.discourse-cdn.com/flex029/user_avatar/forum.clockworkpi.com/natevw/32/6877_2.png) [@natevw](https://forum.clockworkpi.com/u/natevw)\
**Post date:** [February 8, 2023, 2:17am UTC](https://forum.clockworkpi.com/t/printer-makes-only-garbage-from-cm3/9592/5 "2023-02-08T02:17:07Z")

</div>

Found one clue in /var/log/syslog, entries like:

```auto
Feb 7 18:11:15 raspberrypi systemd[1]: devterm-printer.service: Main process exited, code=killed, status=11/SEGV
Feb 7 18:11:15 raspberrypi systemd[1]: devterm-printer.service: Failed with result 'signal'.

```

But why does it SEGV for me? This is basically just stock [http://dl.clockworkpi.com/DevTerm\_CM3\_v0.1a.img.bz2](http://dl.clockworkpi.com/DevTerm_CM3_v0.1a.img.bz2) brought up-to-date and a few unrelated packages (just random stuff like gnome-mahjongg and jstest-gtk) installed.

---

<div class="post-metadata">

**Author:** ![adcockm](https://yyz1.discourse-cdn.com/flex029/user_avatar/forum.clockworkpi.com/adcockm/32/1664_2.png) [@adcockm](https://forum.clockworkpi.com/u/adcockm)\
**Post date:** [February 8, 2023, 4:30am UTC](https://forum.clockworkpi.com/t/printer-makes-only-garbage-from-cm3/9592/6 "2023-02-08T04:30:23Z")

</div>

Did you install snapd and something else requiring snap? This was an issue before, and I wouldn’t be surprised if it never got fixed in the OS image. I’m not sure if it was a CM3 issue though, but maybe it affects all the platfiorms.

> [@Thermal printer service doesn't start](https://forum.clockworkpi.com/t/thermal-printer-service-doesnt-start/7552/14):
>
> I fixed the apparmor issue by adding # devterm printer /tmp/DEVTERM\_PRINTER\_IN wr, /dev/pts/1 wr, to /etc/apparmor.d/usr.sbin.cupsd within block /usr/sbin/cupsd flags=(attach\_disconnected) {} Devterm should ship that apparmor rule as part of the printer package

---

<div class="post-metadata">

**Author:** ![guu](https://avatars.discourse-cdn.com/v4/letter/g/7ab992/32.png) [@guu](https://forum.clockworkpi.com/u/guu)\
**Post date:** [February 8, 2023, 8:08am UTC](https://forum.clockworkpi.com/t/printer-makes-only-garbage-from-cm3/9592/7 "2023-02-08T08:08:16Z")

</div>

For cm3:

```auto
sudo apt update
sudo apt install -y devterm-thermal-printer
sudo reboot

```

just updated ,hope can fix this issue

---

<div class="post-metadata">

**Author:** ![natevw](https://yyz1.discourse-cdn.com/flex029/user_avatar/forum.clockworkpi.com/natevw/32/6877_2.png) [@natevw](https://forum.clockworkpi.com/u/natevw)\
**Post date:** [February 10, 2023, 4:17am UTC](https://forum.clockworkpi.com/t/printer-makes-only-garbage-from-cm3/9592/8 "2023-02-10T04:17:45Z")

</div>

> [@guu](#):
>
> just updated ,hope can fix this issue

I was able to try this tonight, and the updated driver works great! Thanks for the quick fix. I can print from `lp` and from browser and everything works as expected. 🥳

 ![Holding receipt paper with two good printouts on it above DevTerm](https://canada1.discourse-cdn.com/flex029/uploads/clockworkpi/original/2X/e/e9b1d40fa35bcff73f7d152aca12dfb28052e2b6.jpeg)
