OpenWrt Forum Archive

Topic: Can't get USB Printer to work on TL-WR1042ND

The content of this topic has been archived on 1 May 2018. There are no obvious gaps in this topic, but there may still be some posts missing at the end.

Hello,

I installed stable Backfire 10.03.1 on my TL-WR1042ND, everything is working fine, except of my printer. I followed the wiki howto, checked if every USB packages were installed, but the printer does not work. A cat test.txt > /dev/lp0 does nothing, no error, no output, no activity on the printer. Here's my dmesg when plugging in my printer, which is a Brother MFC-250C (it's a USB 2.0 printer):

usb 1-1.3: new full speed USB device using ar71xx-ehci and address 5
usb 1-1.3: configuration #1 chosen from 1 choice
usblp0: USB Bidirectional printer dev 5 if 0 alt 0 proto 2 vid 0x04F9 pid 0x01FE
scsi1 : SCSI emulation for USB Mass Storage devices
usb-storage: device found at 5
usb-storage: waiting for device to settle before scanning
scsi 1:0:0:0: Direct-Access     Brother  MFC-250C         1.00 PQ: 0 ANSI: 2
usb-storage: device scan complete
sd 1:0:0:0: [sda] Attached SCSI removable disk

Here's an lsmod output:
Module                  Size  Used by    Not tainted
ftdi_sio               29712  1
usb_storage            32720  0
usbserial              24352  3 ftdi_sio
usblp                   8512  0
uhci_hcd               17728  0
ohci_hcd               16912  0
nf_nat_tftp              432  0
nf_conntrack_tftp       2400  1 nf_nat_tftp
nf_nat_irc               816  0
nf_conntrack_irc        2512  1 nf_nat_irc
nf_nat_ftp              1328  0
nf_conntrack_ftp        4640  1 nf_nat_ftp
ipt_MASQUERADE           992  1
iptable_nat             2768  1
nf_nat                 10912  5 nf_nat_tftp,nf_nat_irc,nf_nat_ftp,ipt_MASQUERADE,iptable_nat
xt_NOTRACK               544  0
iptable_raw              656  1
xt_state                 768  6
nf_conntrack_ipv4       7920  9 iptable_nat,nf_nat
nf_defrag_ipv4           624  1 nf_conntrack_ipv4
nf_conntrack           38848 12 nf_nat_tftp,nf_conntrack_tftp,nf_nat_irc,nf_conntrack_irc,nf_nat_ftp,nf_conntrack_ftp,ipt_MASQUERADE,iptable_nat,nf_nat,xt_NOTRACK,xt_state,nf_conntrack_ipv4
ehci_hcd               31456  0
sd_mod                 21696  0
ipt_REJECT              1680  2
xt_TCPMSS               2560  1
ipt_LOG                 4176  0
xt_comment               464  0
xt_multiport            1792  0
xt_mac                   576  0
xt_limit                1008  1
iptable_mangle           992  1
iptable_filter           768  1
ip_tables               8544  4 iptable_nat,iptable_raw,iptable_mangle,iptable_filter
xt_tcpudp               1760  8
x_tables                9296 13 ipt_MASQUERADE,iptable_nat,xt_NOTRACK,xt_state,ipt_REJECT,xt_TCPMSS,ipt_LOG,xt_comment,xt_multiport,xt_mac,xt_limit,ip_tables,xt_tcpudp
ppp_async               6400  0
ath9k                  86656  0
ath9k_common            1200  1 ath9k
ath9k_hw              338384  2 ath9k,ath9k_common
ath                    14160  3 ath9k,ath9k_common,ath9k_hw
mac80211              229696  1 ath9k
usbcore                97616  8 ftdi_sio,usb_storage,usbserial,usblp,uhci_hcd,ohci_hcd,ehci_hcd
scsi_mod               68272  2 usb_storage,sd_mod
nls_base                4800  1 usbcore
crc_ccitt                976  1 ppp_async
cfg80211              139760  3 ath9k,ath,mac80211
pppoe                   8304  2
pppox                   1216  1 pppoe
ppp_generic            18864  7 ppp_async,pppoe,pppox
slhc                    4160  1 ppp_generic
compat                 16496  3 ath9k,mac80211,cfg80211
arc4                     816  2
aes_generic            30256  4
deflate                 1360  0
ecb                     1328  0
cbc                     2016  0
leds_gpio               1456  0
button_hotplug          2576  0
gpio_buttons            2128  0
input_polldev           1360  1 gpio_buttons
input_core             17056  4 button_hotplug,gpio_buttons,input_polldev

ls -lFs /dev/lp0
4 -rw-r--r--    1 root     root          722 Aug 23 08:24 /dev/lp0

Any advice or help would be very appreciated what I should do to test out why it's not working. Thanks a lot.

(Last edited by knuddel on 23 Aug 2012, 07:30)

Hello!

1. As you posted, the device is at usblp0, not lp0. The output of ls shows, that lp0 is not a link.
2. I guess, that the MFC-250C is a GDI-Printer, but I can't tell for sure from the specifications from the brother homepage. So the "cat" into lp0 or usblp0 will not show the wanted effects.
3. You will probably want to try p910nd and luci-app-p910nd in combination with the correct printer driver.

Regards
epek

But /dev/lp0 appears when I plug in the printer, somewhere in the changelogs (here ... "It depends on the kernel version: 2.6.x: /dev/lp<n> 2.4.x: /dev/usb/lp<n>") it says they changed the link from /dev/usb/lp0 to /dev/lp0, whatever reason for. I have already installed p910nd, that doesnt do any favor though, because the printer has to work at first. What's a GDI printer? So how do I get it to work, what drivers, where should I get AR71xx compiled drivers for that printer from... Shouldnt usblp handle it alone?

(Last edited by knuddel on 23 Aug 2012, 10:14)

bump...

The specification¹ of your printer does not tell, what emulations it is capable of.
A GDI Printer is describen on wikipedia² as a printer that does not use hardware for print preprocessing. Instead, the driver will render it. (that's probably why a simple cat "x" >/dev/lp0 won't work as expected.)
What you may want to do is just forwarding the USB-protocol data with usbip, but up to my current knowledge, that will only work well on linux, despite there is a driver for Windows³ too.
Since 910nd (4) does also just passes data through, it should also work, but the driver needs to be installed on the client machine (not the router itself). Printing from the router itself won't work, I guess for the same reasons as (2). I am probably wrong.
To be sure about the correct device check dmesg | grep lp.

On Windows you may install the driver for a local printer and install a generic network card afterwards (see driver/port settings). That should do the trick.

1: http://welcome.solutions.brother.com/bs … index.html
2: http://en.wikipedia.org/wiki/Gdi_printer#GDI_printers
3: http://usbip.sourceforge.net/
4: http://p910nd.sourceforge.net/

knuddel wrote:

Hello,

I installed stable Backfire 10.03.1 on my TL-WR1042ND, everything is working fine...

Do you really be able to install OpenWrt on TL-WR1042ND?? or you mean TL-WR1043ND ??

same question, I need to verify also.

The discussion might have continued from here.