Canon capt linux driver

Saved searches

Use saved searches to filter your results more quickly

You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session.

Instructions on how to install Canon CAPT-based printers (LBP-***) for Ubuntu 20.04 and CUPS

nerk/canon-capt-installation

This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?

Sign In Required

Please sign in to use Codespaces.

Launching GitHub Desktop

If nothing happens, download GitHub Desktop and try again.

Launching GitHub Desktop

If nothing happens, download GitHub Desktop and try again.

Launching Xcode

If nothing happens, download Xcode and try again.

Launching Visual Studio Code

Your codespace will open once ready.

There was a problem preparing your codespace, please try again.

Latest commit

Git stats

Files

Failed to load latest commit information.

README.adoc

Canon CAPT Printers on Ubuntu 16.04+ (64-bit)

I own an old Canon laser printer (LBP-2900), which is still going strong. Unfortunately, the printer uses the proprietary CAPT protocol and Canon drivers for Linux do no longer work with recent versions of CUPS.

There are several attemps to make this printer work again, for example

and several other repositories for older Linux versions. However, none of these methods worked for me on Ubuntu 20.04.

I think, parts of the proprietary parts of the printer drivers are just to old to work with recent versions of CUPS.

The solution is to run a minimal compatible version of Ubuntu (14.04, 32-bit) inside a Linux container (LXC).

The guest OS can directly use the kernel of the host machine, but provides an isolated environment for the processes to be executed. Compared to runninng a full virtualization solution like VMware or VirtualBox, this is much more lightweight and quite fast.

While full virtualization solutions are very powerful and feel a bit heavy, Docker with its ‘one process per container’ isn’t powerful enough for this task. LXC falls right in between the two.

Читайте также:  Удаленный доступ линукс минт

On my host system, the device node created for my printer sometimes changed from /dev/bus/usb/lp0 to /dev/bus/usb/lp1 on booting. It is also a good idea to give it a more meaningful name anyway. This can be achieved by creating a symbolic link to the actual device node. Create a the file /etc/udev/rules.d/60-persistent-printer.rules with the following content:

ACTION=="add", KERNEL=="lp*", SUBSYSTEMS=="usb", ATTRS=="Canon CAPT USB Device", SYMLINK+="lp/canon_printer", RUN+="/usr/local/bin/attach_printer" ACTION=="remove", KERNEL=="lp*", SUBSYSTEMS=="usb", ATTRS=="Canon CAPT USB Device", RUN+="/usr/local/bin/detach_printer"

The printer can now be accessed through /dev/lp/canon_printer instead of the generic device node (once the system has been rebooted).

In case the printer is not already switched on before the server boots, the device will not be correctly propagated to the container. Having the udev rule executing the script attach_printer in addition to creating the link solves this problem.

Create file /usr/local/bin/attach_printer with the following contents:

#!/bin/bash /usr/bin/lxc-device -n canon add /dev/lp/canon_printer

Detaching the printer is handled through /usr/local/bin/detach_printer :

#!/bin/bash /usr/bin/lxc-device -n canon del /dev/lp/canon_printer

Make the scripts executable:

sudo chmod 755 /usr/local/bin/attach_printer sudo chmod 755 /usr/local/bin/detach_printer

Since we want to be able to access the virtual print server from the LAN, we need to bridge its network interface to the physical ethernet port of the server.

First, you need to figure out the name of your pysical interface. At some point, Ubuntu introduced so called predictable network interface names , meaning that your first interface is not simply called eth0 anymore.

and look for an interface name starting with e , e.g. eno1 .

Open file /etc/network/interfaces in an editor and append the following:

auto br0 iface br0 inet dhcp bridge-ports eno1 (1)

Make sure there is no other line with auto eno1 in that file.

Make all changes above effective by booting the system:

You should now be able to access the printer through the created link pointing to the real device node:

Create a virtual container named canon with a minimal 32-bit Ubuntu 14.04 (Trusty Thar):

sudo lxc-create -t download -n canon

Choose ‘ubuntu’, ‘trusty’, and ‘i386’.

sudo vi /var/lib/lxc/canon/config
# Network configuration lxc.network.type = veth lxc.network.link = br0 (1) lxc.network.flags = up lxc.network.hwaddr = 00:16:3e:3e:7b:94 ### Add the following: # Autostart lxc.start.auto = 1 (2) lxc.start.delay = 5 # mount printer lxc.cgroup.devices.allow = c 180:* rwm (3) lxc.mount.entry = /dev/lp/canon_printer dev/lp/canon_printer none bind,optional,create=file (4)
  1. Change to br0 from lxcbr0 . Leave other entries in this block unchanged.
  2. Autostart this container when the host boots
  3. Allow access to printer devices on host
  4. Initially mount the printer on the host to /dev/lp/canon_printer in the container.

Start canon and verify it is running:

sudo lxc-start -n canon sudo lxc-ls --fancy

Since we need to be able to login to the print server, a user with appropriate settings must be created.

Enter the chroot environment of canon :

Источник

Canon CAPT

CAPT (Canon Advanced Printing Technology) is Canon’s proprietary driver, supporting the Canon i-Sensys series of laser printers. For more information, see Setting up CAPT printers on Ubuntu.

Читайте также:  Uncompressing files in linux

Installation

Install the capt-src AUR package. It depends on 32-bit library packages and requires enabling multilib.

There is also an open source CAPT driver in early alpha stage not described here, available as captdriver-git AUR .

Configuration

Canon’s driver uses a local daemon to communicate with the printer, and wraps that using a CUPS driver.

To configure the printer, follow the CUPS article, adding a CAPT printer and using a Printer URI of ccp://localhost:59787 . Find the right model using lpinfo -m , or check the table provided on the Ubuntu help page, which matches each supported printer with its corresponding PPD.

  • Installing CAPT printers via the CUPS web interface may not work [1]. Instead, use the CLI tools.
  • If port 59787 does not work, try port 59687 .
  • Some models have multiple PPDs, where the last letter indicates the regional model (J = Japan, K = United Kingdom, S = United States)

Next, register the printer with the CAPT driver itself via ccpdadmin. Replace queue_name with the queue descriptive name and printer_address with either the USB port (e.g. /dev/usb/lp0 ) in case of a local printer or the IP address, prefixed by net: (e.g. net:192.168.1.100 ), in case of a network printer:

# ccpdadmin -p queue_name -o printer_address 

For example, for a USB printer:

# ccpdadmin -p LBP6310 -o /dev/usb/lp0
# ccpdadmin -p LBP6310 -o net:192.168.1.100

Start/enable the CAPT daemon with ccpd.service .

# ccpdadmin -x queue_name 

CAPT status monitor

Local CUPS

The driver includes a status monitor which can be launched with

$ captstatusui -P printer_model 

If you only want the status monitor to pop up when a problem occurs, simply append the -e switch:

Remote CUPS

Unfortunately, a local installation of captstatusui will not detect CAPT printers on a remote CUPS server.

Remote print monitoring can be achieved, however, using SSH and X11 forwarding.

Warning: X11 forwarding has important security implications, especially when using the -Y switch (ForwardX11Trusted, required for the CAPT status monitor to work via X11 Forwarding). See X11 forwarding for further information.

Note: There are many ways to set up X11 forwarding. For security reasons, this example is based on public key authentication, a dedicated SSH user account, and SSH running on the CUPS server. Adapt these instructions to your specific configuration.

Client configuration

  • create a new SSH key ~/.ssh/capt and copy the public key to the remote server
  • create a file captstatusui.sh with the following content, make it executable and place it in your autostart folder:
#!/bin/sh ssh -T -Y -i ~/.ssh/capt remote_server_hostname_or_IP_address < /dev/null

Server configuration

  • create a new user capt
  • append the following section to /etc/ssh/sshd_config and restart the SSH daemon or socket
. Match User capt X11Forwarding yes PermitTTY no ForceCommand captstatusui -P printer_model -e AuthenticationMethods publickey
. Match User capt X11Forwarding yes PermitTTY no ForceCommand captstatusui -P LBP6310 -e AuthenticationMethods publickey

This can be extended to include multiple users (using a single, shared SSH key or each with a unique SSH key) by adding each user to a capt group, then using a Match Group rule:

. Match Group capt X11Forwarding yes PermitTTY no ForceCommand captstatusui -P LBP6310 -e AuthenticationMethods publickey

Troubleshooting

Conflict with CUPS

To prevent CUPS from accessing our CAPT-only printer (and confusing the firmware with multiple setup requests over USB), a list of unsupported VID/PID pairs may be added into /usr/share/cups/usb/ . See the issue on GitHub: Cups attempts to probe, configure unsupported Canon CAPT USB printers.

Читайте также:  Building webkit on linux

Источник

Установка драйвера Canon CAPT для принтеров Canon LBP

Установка драйвера Linux CAPT Printer Driver v2.60-1 для принтеров Canon LBP на Ubuntu 12.04, 12.10, 13.04, 13.10, 14.04, 32-битной и 64-битной архитектуры.

Поддерживаемые принтеры:
LBP-1210, LBP-1120, LBP-810, LBP2900, LBP3000, LBP3010, LBP3018, LBP3050, LBP3100, LBP3108, LBP3150, LBP3200, LBP3210, LBP3250, LBP3300, LBP3310, LBP3500, LBP5000, LBP5050, LBP5100, LBP5300, LBP6000, LBP6018, LBP6020, LBP6020B, LBP6200, LBP6300, LBP6300n, LBP6310, LBP7010C, LBP7018C, LBP7200C, LBP7210C, LBP9100C, LBP9200C.

Для установки драйвера необходимо в терминале выполнить следующие команды:

cd ~/Загрузки/

wget -c http://ubuntu-desktop.ru/wp-content/uploads/2015/01/canon_lbp_setup.sh

chmod +x canon_lbp_setup.sh

./canon_lbp_setup.sh

После запуска скрипта следуйте инструкции по установке

347657326769328478

Comments

Огромное спасибо! Коротко, ясно и продуктивно!Canon LBP 2900 установлен за 10 мин на
Linux Mint 17.1 Rebecca xfce 64-bit. До этого два вечера — танцы с бубном!Чувствовал себя
как обезьяна с гранатой! Опыт с LINUX — 2 месяца. ЧАЙНИК.
Удачи и здоровья!

Огромное спасибо!Кратко и конкретно! Установка — 5-6 мин.
Система: Linux Mint 17.2 и 17.3 с LBP 2900.
Стаж в Linux — 10 мес. Возраст -68 лет! Успехов Вам, liman28!

система линукс минт матэ 17ю3: сетевой принтер canon lbp 2900 установился, но сразу выскакивает сообщение communication error, что делать? при установке запрашивался ip-адрес принтера, я вводил адрес сетевого компа, к которому подключен принтер через кабель.

Merci!enfin j’ai réussi à installer canon lbp 1120 sur ubuntu 14.04.
Le tuto est excellent.
(arch.64bit)

Merci!enfin j’ai réussi à installer canon lbp 1120 sur ubuntu 14.04.
Le tuto est excellent.
(arch.64bit)

Отлично, но заработал принтер LBP 2900 только на 32 битной системе.Сначала Пытался на 14.04 64 бит, заработал только на Ubuntu 14.04 32 бит. Всем удачи.

Добрый день.При установке во время запроса:»Включите принтер», включаю, установщик ни как не реагирует.На нажатия клавиш выдает туже надпись. Принтер LBP6020B. В чем может быть причина?

У меня точно такой же принтер, в Ubuntu 14.04-15.04 подобных проблем не было. Попробуйте удалить драйвер, а потом установить заново.

тем же sh удалил. Перезагрузил, при попытке установки та же проблема. Может надо его в систему прописать руками полностью, хотя зачем тогда sh этот…

Источник

Оцените статью
Adblock
detector