Package Details: foo2zjs-nightly 20180519-1

Git Clone URL: https://aur.archlinux.org/foo2zjs-nightly.git (read-only)
Package Base: foo2zjs-nightly
Description: foo2zjs Printer Drivers (automatically updated). Includes also foo2hp, foo2hbpl, foo2oak, foo2xqx, foo2qpdl, foo2slx, foo2hiperc and foo2lava drivers.
Upstream URL: http://foo2zjs.rkkda.com/
Licenses: GPL, custom
Conflicts: foo2zjs
Provides: foo2zjs
Replaces: foo2zjs
Submitter: intelfx
Maintainer: intelfx
Last Packager: intelfx
Votes: 30
Popularity: 1.378326
First Submitted: 2016-11-12 03:35
Last Updated: 2018-06-02 23:08

Dependencies (7)

Required by (0)

Sources (35)

Pinned Comments

ahuillet commented on 2017-05-08 09:15

foo2zjs, when paired with Ghostscript9 as present in Archlinux, has a nasty color printing bug. The foo2zjs author is aware of it but hasn't, so far, appeared to fully describe the bug, report it upstream, or implement a fix/workaround in his software.
Instead, what he recommends is to install Ghostscript8 as /usr/bin/gs.foo.
http://foo2zjs.rkkda.com/forum/read.php?63,3189

intelfx commented on 2016-11-12 03:37

Package bumped. New package foo2zjs-nigtly has been uploaded which has a `pkgver()` function that extracts the timestamp from the driver's home page.

This should eliminate the need for frequent checksum mismatches and bump requests (provided that the patches will still apply). Please use that package, I'll request this one to be merged.

intelfx commented on 2016-10-23 00:02

@petres: Package bumped. I've completely rewritten printer firmware loading; please report if anything doesn't work (relevant for HP LaserJet printers).

intelfx commented on 2016-10-04 06:21

From now on, foo2zjs is decoupled from foomatic-db and does not require using the patched foomatic-db-foo2zjs package (nor does it require foomatic-db at all).

Latest Comments

1 2 3 4 5 6 ... Next › Last »

denixx commented on 2018-07-10 07:07

@intelfx Thank you very much, indeed it had installed flawlessly today (for some time i was blocked by ffmpeg2.8 as I don't removed orphans before today). Installed it via proxy.

ron2138 commented on 2018-06-11 14:57

Replying to intelfx comment on 2018-06-10 17:10:

It could be that using a systemd unit is better. It doesn't work for me. The following seems to work here:


--- a/usr/bin/foo2zjs-loadfw
+++ b/usr/bin/foo2zjs-loadfw
@@ -29,7 +29,8 @@ USB_BACKEND=/usr/lib/cups/backend/usb
 # Figure out how to log our messages
 #
 log() {
-   echo "$@" >&2
+#  echo "$@" >&2
+   /usr/bin/logger -p user.info "$0:" "$@"
 }

#


--- a/usr/lib/udev/rules.d/71-hplj10xx.rules
+++ b/usr/lib/udev/rules.d/71-hplj10xx.rules
@@ -16,6 +16,7 @@ ENV{FOO2ZJS_FW_MODEL}=="", GOTO="foo2zjs

# Inherit the instance name from the parent unit's instance name (or unit name, if there is no instance name). # In our case -- the printer's full devpath gets passed. -TAG+="systemd", ENV{SYSTEMD_WANTS}+="foo2zjs-loadfw@.service" +#TAG+="systemd", ENV{SYSTEMD_WANTS}+="foo2zjs-loadfw@.service" +RUN+="/bin/sh -c '/usr/bin/nohup /usr/bin/foo2zjs-loadfw $env{DEVPATH} $env{FOO2ZJS_FW_MODEL}'"

LABEL="foo2zjs_fw_end"

Replying to intelfx comment on 2018-06-11 12:40:

I comfirm the part of bitsfritz comment on 2018-06-11 00:01 that the kernel does see, and logs, the reappearance of the device.

systemd.device manual page explicitly mentions a "changed" event. Can it be that it ignores, or is not being sent to, more than 1 "add" event by design? Can it be that udev follows these steps for such devices? Doesn't such unit should end with the .device susffix? I mean, what implications are there for the .service suffix, which seems not as degined? If I will omit udev "TAG+="systemd"", will udev create the same device by itself?

intelfx commented on 2018-06-11 12:40

@bitsfritz

"after replugging" <...> foo2zjs-loadfw is not triggered

Aw, shit. This is a known (by me, no idea if upstream knows) bug somewhere in between kernel, udev, and systemd. tl;dr is that when a device is unplugged, its .device-unit remains activated, hence no state change happens when it is replugged again. I should really take time and report/debug this...

bitsfritz commented on 2018-06-11 11:32

@ron2138, @intelfix

udevadm test

only accepts DEVPATH as parameter.

The steps I go[1] at recent setup:

~] lsusb
..
Bus 001 Device 019: ID 03f0:0517 Hewlett-Packard LaserJet 1000
..

~] udevadm info -q path /dev/bus/usb/001/019 /devices/pci0000:00/0000:00:1a.7/usb1/1-5/1-5.4/1-5.4.4

~] udevadm test /devices/pci0000:00/0000:00:1a.7/usb1/1-5/1-5.4/1-5.4.4 ..

[1] described here: https://wiki.archlinux.org/index.php/CUPS/Troubleshooting#Bad_permissions

@ron2138:

/sys/dev/bus/usb/001/019
does not exist here..

P.S. answering here is a pain...

ron2138 commented on 2018-06-11 04:37

Replying intelfx comment at 2018-06-10 17:10:

  1. The first foo2zjs I ever had is 20180519-1. I never had an earlier version. The problem manifested itself right from the begining, though hplip was interfering too until I disabled it. Or so I think. I am not sure about the hplip interference now as I was a few days ago.
  2. Script started on 2018-06-11 04:17:44+00:00
    calling: test
    version 238
    This program is for debugging only, it does not run any program
    specified by a RUN key. It may show incorrect results, because
    some values may be different, or not available at a simulation run.

    Load module index Parsed configuration file /usr/lib/systemd/network/99-default.link Created link configuration context. Reading rules file: /usr/lib/udev/rules.d/10-dm.rules Reading rules file: /usr/lib/udev/rules.d/11-dm-lvm.rules Reading rules file: /usr/lib/udev/rules.d/13-dm-disk.rules Reading rules file: /etc/udev/rules.d/40-brscan4.rules Reading rules file: /usr/lib/udev/rules.d/40-gphoto.rules Reading rules file: /usr/lib/udev/rules.d/49-sane.rules Reading rules file: /usr/lib/udev/rules.d/50-udev-default.rules Reading rules file: /etc/udev/rules.d/56-hpmud.rules Reading rules file: /usr/lib/udev/rules.d/60-block.rules Reading rules file: /usr/lib/udev/rules.d/60-cdrom_id.rules Reading rules file: /usr/lib/udev/rules.d/60-drm.rules Reading rules file: /usr/lib/udev/rules.d/60-evdev.rules Reading rules file: /usr/lib/udev/rules.d/60-input-id.rules Reading rules file: /usr/lib/udev/rules.d/60-pcmcia.rules Reading rules file: /usr/lib/udev/rules.d/60-persistent-alsa.rules Reading rules file: /usr/lib/udev/rules.d/60-persistent-input.rules Reading rules file: /usr/lib/udev/rules.d/60-persistent-storage-tape.rules Reading rules file: /usr/lib/udev/rules.d/60-persistent-storage.rules Reading rules file: /usr/lib/udev/rules.d/60-persistent-v4l.rules Reading rules file: /usr/lib/udev/rules.d/60-rfkill.rules Reading rules file: /usr/lib/udev/rules.d/60-sensor.rules Reading rules file: /usr/lib/udev/rules.d/60-serial.rules Reading rules file: /usr/lib/udev/rules.d/63-md-raid-arrays.rules Reading rules file: /usr/lib/udev/rules.d/64-btrfs.rules Reading rules file: /usr/lib/udev/rules.d/64-md-raid-assembly.rules Reading rules file: /usr/lib/udev/rules.d/65-libwacom.rules Reading rules file: /usr/lib/udev/rules.d/69-cd-sensors.rules Reading rules file: /usr/lib/udev/rules.d/69-dm-lvm-metad.rules Reading rules file: /usr/lib/udev/rules.d/70-infrared.rules Reading rules file: /usr/lib/udev/rules.d/70-joystick.rules Reading rules file: /usr/lib/udev/rules.d/70-mouse.rules Reading rules file: /usr/lib/udev/rules.d/70-power-switch.rules Reading rules file: /usr/lib/udev/rules.d/70-touchpad.rules Reading rules file: /usr/lib/udev/rules.d/70-uaccess.rules Reading rules file: /usr/lib/udev/rules.d/71-hplj10xx.rules Reading rules file: /usr/lib/udev/rules.d/71-seat.rules Reading rules file: /usr/lib/udev/rules.d/73-seat-late.rules Reading rules file: /usr/lib/udev/rules.d/75-net-description.rules Reading rules file: /usr/lib/udev/rules.d/75-probe_mtd.rules Reading rules file: /usr/lib/udev/rules.d/78-sound-card.rules Reading rules file: /usr/lib/udev/rules.d/80-drivers.rules Reading rules file: /usr/lib/udev/rules.d/80-libinput-device-groups.rules Reading rules file: /usr/lib/udev/rules.d/80-net-setup-link.rules Reading rules file: /usr/lib/udev/rules.d/90-libinput-model-quirks.rules Reading rules file: /usr/lib/udev/rules.d/90-vconsole.rules Reading rules file: /usr/lib/udev/rules.d/95-cd-devices.rules Reading rules file: /usr/lib/udev/rules.d/95-dm-notify.rules Reading rules file: /usr/lib/udev/rules.d/99-fuse3.rules Reading rules file: /usr/lib/udev/rules.d/99-systemd.rules rules contain 196608 bytes tokens (16384 * 12 bytes), 23631 bytes strings 14354 strings (117309 bytes), 12015 de-duplicated (96018 bytes), 2340 trie nodes used unable to open device '/sys/dev/bus/usb/001/002' Unload module index Unloaded link configuration context.

    Script done on 2018-06-11 04:17:44+00:00

    /sys/dev/bus/usb/001/002 is there and points to the printer, as
    udevadm info /dev/bus/usb/001/002
    can show.
  3. As for not sensing cycling the printer power, or repluging the USB plug, the printer stop printing. Jobs are supposedly done, but no output from the printer. And the journal proves no attempt to download the firmware to the printer took place. If I manually force firmware download, the printer does print.

bitsfritz commented on 2018-06-11 00:01

@intelfix, after writing the bug report, my system decided to get back loading firmware at reboot, which it did not before..

Output of

~]$ udevadm test '/devices/pci0000:00/0000:00:1a.7/usb1/1-5/1-5.4/1-5.4.4' 
calling: test
version 238
...
Load module index
Parsed configuration file /usr/lib/systemd/network/99-default.link
Created link configuration context.
...
Reading rules file: /usr/lib/udev/rules.d/71-hplj10xx.rules
...
rules contain 393216 bytes tokens (32768 * 12 bytes), 40086 bytes strings
31927 strings (260161 bytes), 27861 de-duplicated (224142 bytes), 4067 trie nodes used
IMPORT builtin 'usb_id' /usr/lib/udev/rules.d/40-gphoto.rules:9
IMPORT builtin skip 'usb_id' /usr/lib/udev/rules.d/50-udev-default.rules:13
IMPORT builtin 'hwdb' /usr/lib/udev/rules.d/50-udev-default.rules:13
MODE 0664 /usr/lib/udev/rules.d/50-udev-default.rules:45
GROUP 7 /usr/lib/udev/rules.d/50-udev-default.rules:57
PROGRAM '/usr/sbin/obex-check-device 03f0 0517' /usr/lib/udev/rules.d/60-openobex.rules:3
starting '/usr/sbin/obex-check-device 03f0 0517'
Process '/usr/sbin/obex-check-device 03f0 0517' failed with exit code 1.
RUN '/usr/share/virtualbox/VBoxCreateUSBNode.sh $major $minor $attr{bDeviceClass} vboxusers' /usr/lib/udev/rules.d/60-vboxdrv.rules:6
PROGRAM '/usr/lib/udev/mtp-probe /sys/devices/pci0000:00/0000:00:1a.7/usb1/1-5/1-5.4/1-5.4.4 1 8' /usr/lib/udev/rules.d/69-libmtp.rules:2465
starting '/usr/lib/udev/mtp-probe /sys/devices/pci0000:00/0000:00:1a.7/usb1/1-5/1-5.4/1-5.4.4 1 8'
'/usr/lib/udev/mtp-probe /sys/devices/pci0000:00/0000:00:1a.7/usb1/1-5/1-5.4/1-5.4.4 1 8'(out) '0'
Process '/usr/lib/udev/mtp-probe /sys/devices/pci0000:00/0000:00:1a.7/usb1/1-5/1-5.4/1-5.4.4 1 8' succeeded.
RUN '/usr/lib/udev/tlp-usb-udev %p' /usr/lib/udev/rules.d/85-tlp.rules:10
handling device node '/dev/bus/usb/001/008', devnum=c189:7, mode=0664, uid=0, gid=7
preserve permissions /dev/bus/usb/001/008, 020664, uid=0, gid=7
preserve already existing symlink '/dev/char/189:7' to '../bus/usb/001/008'
ACTION=add
BUSNUM=001
DEVNAME=/dev/bus/usb/001/008
DEVNUM=008
DEVPATH=/devices/pci0000:00/0000:00:1a.7/usb1/1-5/1-5.4/1-5.4.4
DEVTYPE=usb_device
DRIVER=usb
FOO2ZJS_FW_MODEL=1000
ID_BUS=usb
ID_MODEL=hp_LaserJet_1000
ID_MODEL_ENC=hp\x20LaserJet\x201000
ID_MODEL_FROM_DATABASE=LaserJet 1000
ID_MODEL_ID=0517
ID_REVISION=0120
ID_SERIAL=Hewlett-Packard_hp_LaserJet_1000
ID_USB_INTERFACES=:070102:
ID_VENDOR=Hewlett-Packard
ID_VENDOR_ENC=Hewlett-Packard
ID_VENDOR_FROM_DATABASE=Hewlett-Packard
ID_VENDOR_ID=03f0
MAJOR=189
MINOR=7
PRODUCT=3f0/517/120
SUBSYSTEM=usb
SYSTEMD_WANTS=configure-printer@usb-001-008.service foo2zjs-loadfw@.service printer.target
TAGS=:systemd:
TYPE=0/0/0
USEC_INITIALIZED=6600380
run: '/usr/share/virtualbox/VBoxCreateUSBNode.sh 189 7 00 vboxusers'
run: '/usr/lib/udev/tlp-usb-udev /devices/pci0000:00/0000:00:1a.7/usb1/1-5/1-5.4/1-5.4.4'
Unload module index
Unloaded link configuration context.

''while booting''

~]$ journalctl -b | grep foo2
Jun 10 19:45:33 dumbledore systemd[1]: Created slice system-foo2zjs\x2dloadfw.slice.
Jun 10 19:45:33 dumbledore foo2zjs-loadfw[958]: Downloading firmware for printer model '1000' serial '' at devpath '/devices/pci0000:00/0000:00:1a.7/usb1/1-5/1-5.4/1-5.4.4'
Jun 10 19:45:33 dumbledore foo2zjs-loadfw[958]: Serial number is empty, working around
Jun 10 19:45:33 dumbledore foo2zjs-loadfw[958]: Got printer: URI='usb://HP/LaserJet%201000' deviceid='MFG:Hewlett-Packard;MDL:hp LaserJet 1000;CMD:ZJS;CLS:PRINTER;DES:hp LaserJet 1000;'
Jun 10 19:45:34 dumbledore foo2zjs-loadfw[958]: Firmware download OK

everything fine until here..

''after replugging'' journalctl -f results in

...
Jun 11 01:38:17 dumbledore kernel: usb 1-5.4.4: new full-speed USB device number 20 using ehci-pci
Jun 11 01:38:17 dumbledore kernel: usb 1-5.4.4: New USB device found, idVendor=03f0, idProduct=0517
Jun 11 01:38:17 dumbledore kernel: usb 1-5.4.4: New USB device strings: Mfr=1, Product=2, SerialNumber=0
Jun 11 01:38:17 dumbledore kernel: usb 1-5.4.4: Product: hp LaserJet 1000
Jun 11 01:38:17 dumbledore kernel: usb 1-5.4.4: Manufacturer: Hewlett-Packard
Jun 11 01:38:17 dumbledore mtp-probe[6668]: checking bus 1, device 20: "/sys/devices/pci0000:00/0000:00:1a.7/usb1/1-5/1-5.4/1-5.4.4"
Jun 11 01:38:17 dumbledore mtp-probe[6668]: bus: 1, device: 20 was not an MTP device
Jun 11 01:38:18 dumbledore upowerd[1322]: unhandled action 'bind' on /sys/devices/pci0000:00/0000:00:1a.7/usb1/1-5/1-5.4/1-5.4.4

foo2zjs-loadfw is not triggered.

Output of

udevadm test...

appears to be equal apart from the new usb device number and it's relatives.

intelfx commented on 2018-06-10 17:10

@ron2138:

Can some one explain, real slow, why the systemd unit is required in the first place? Why not use a udev RUN command?

Because everything is better with systemd, of course. ;)

Only slightly joking here. udev is not a process supervisor. Programs started via RUN:

  • are executed synchronously (udev waits while the program runs)
  • are SIGKILLed after indeterminate amount of time
  • can have runaway children
  • are not monitored
  • do not have their logs properly tagged

..and so on.

In addition, I don't understand how this setup is supposed to deal with the case that one repeatedly turns his printer on and off while the PC is running. As far as I can tell, it won't run again the systemd unit, which makes the printer uninitialized.

The systemd unit is not RemainAfterExit=true. It should trigger every time the add or change event fires. If the printer is turned off, it should behave exactly as if the printer was unplugged and then replugged again. If it does not work for you, could you please elaborate further?

intelfx commented on 2018-06-10 16:49

@bitsfritz, @ron2138: When did this error first manifest? Can you run udevadm info /dev/bus/usb/BUS/DEV or, better, udevadm test /dev/bus/usb/BUS/DEV on the printer?

ron2138 commented on 2018-06-10 11:01

@bitsfritz (commented on 2018-06-09 21:19): I confirm. I get this too. A workaround for those having only one printer is to replace line 40 of /usr/bin/foo2zjs-loadfw, currently

MODEL="$FOO2ZJS_FW_MODEL"

with

MODEL=(replace this parenthesis with the model as /usr/lib/udev/rules/71-hplj10xx.rules records it in ENV{FOO2ZJS_FW_MODEL}.)

Can some one explain, real slow, why the systemd unit is required in the first place? Why not use a udev RUN command? In addition, I don't understand how this setup is supposed to deal with the case that one repeatedly turns his printer on and off while the PC is running. As far as I can tell, it won't run again the systemd unit, which makes the printer uninitialized.

bitsfritz commented on 2018-06-09 21:19

again cannot connect my Laserjet 1000

... Jun 09 22:21:22 dumbledore systemd[1]: Starting Load HP ZJS/XQX printer firmware for /sys/devices/pci0000:00/0000:00:1a.7/usb1/1-5/1-5.4/1-5.4.4... Jun 09 22:21:22 dumbledore udev-configure-printer[1114]: add usb-001-009 Jun 09 22:21:22 dumbledore foo2zjs-loadfw[1115]: Downloading firmware for printer model '' serial '' at devpath '/devices/pci0000:00/0000:00:1a.7/usb1/1-5/1-5.4/1-5.4.4' Jun 09 22:21:22 dumbledore foo2zjs-loadfw[1115]: Model number is empty (borked udev configuration?) ...

is this a regression from "bitsfritz commented on 2016-11-01 15:14" ?