beaglebone g_printer module and windows host

How did you load g_printer on the beaglebone board? Did you have to unload something first? I’m trying to get windows to see it as a printer, also.

root@beaglebone:~# modprobe g_printer
ERROR: could not insert ‘g_printer’: No such device
root@beaglebone:~# modinfo g_printer
filename: /lib/modules/3.8.13/kernel/drivers/usb/gadget/g_printer.ko
license: GPL
author: Craig Nadler
description: Printer Gadget
srcversion: DDF852A83CCE4691D9F9B96
depends: libcomposite
intree: Y
vermagic: 3.8.13 SMP mod_unload modversions ARMv7 thumb2 p2v8
parm: idVendor:USB Vendor ID (ushort)
parm: idProduct:USB Product ID (ushort)
parm: bcdDevice:USB Device version (BCD) (ushort)
parm: iSerialNumber:SerialNumber string (charp)
parm: iManufacturer:USB Manufacturer string (charp)
parm: iProduct:USB Product string (charp)
parm: iSerialNum:1 (charp)
parm: iPNPstring:MFG:linux;MDL:g_printer;CLS:PRINTER;SN:1; (charp)
parm: qlen:uint

root@beaglebone:~# modprobe g_printer idVendor=0x3f0 idProduct=0x3404 bcdDevice=0x2 iSerialNumber=0x3 iManufacturer=HP iPNPstring:MFG:hp:MDL:deskjet 6122:CLS:PRINTER:SN:MY53A3B04P66
ERROR: could not insert ‘g_printer’: Invalid argument
root@beaglebone:~# modprobe g_printer idVendor=0x3f0 idProduct=0x3404 bcdDevice=0x2 iSerialNumber=0x3 iManufacturer=HP
ERROR: could not insert ‘g_printer’: No such device
root@beaglebone:~# modprobe g_printer idVendor=0x3f0 idProduct=0x3404
ERROR: could not insert ‘g_printer’: No such device

I come across the problem, too.

root@beaglebone:/home/debian# modprobe g_printer iProduct=“Test” idVendor=0x1d6b idProduct=0x0002 iManufacturer=“Canon” iPNPstring=“something” iSerialNum=“1234” bcdDevice=261
modprobe: ERROR: could not insert ‘g_printer’: No such device

How did you solve this?

在 2013年10月24日星期四 UTC+8上午7:57:58,spot…@gmail.com写道:

Did you enable the g_printer driver?

Regards,

Did you mean the g_printer.ko?

root@beaglebone:/lib/modules/4.4.30-ti-r64/kernel/drivers/usb/gadget/legacy# file g_printer.ko
g_printer.ko: ELF 32-bit LSB relocatable, ARM, EABI5 version 1 (SYSV), BuildID[sha1]=146c9f734be9bcf8b24a26b3368a7443bfbab22e, not stripped

I flashed firmware image bone-debian-8.6-iot-armhf-2016-11-06-4gb.img from
https://beagleboard.org/latest-images

在 2018年8月14日星期二 UTC+8下午10:29:49,RobertCNelson写道:

Did you mean mknod g_printer nod?

root@beaglebone:/lib/modules/4.4.30-ti-r64/kernel/drivers/usb/gadget/legacy# file g_printer.ko
g_printer.ko: ELF 32-bit LSB relocatable, ARM, EABI5 version 1 (SYSV), BuildID[sha1]=146c9f734be9bcf8b24a26b3368a7443bfbab22e, not stripped

I flashed bone-debian-8.6-iot-armhf-2016-11-06-4gb.img from https://beagleboard.org/latest-images.

在 2018年8月14日星期二 UTC+8下午10:29:49,RobertCNelson写道:

Did you mean mknod g_printer nod?

root@beaglebone:/lib/modules/4.4.30-ti-r64/kernel/drivers/usb/gadget/legacy# file g_printer.ko
g_printer.ko: ELF 32-bit LSB relocatable, ARM, EABI5 version 1 (SYSV), BuildID[sha1]=146c9f734be9bcf8b24a26b3368a7443bfbab22e, not stripped

Okay, it's built/installed

I flashed bone-debian-8.6-iot-armhf-2016-11-06-4gb.img from Latest Software Images - BeagleBoard.

did you disable the currently loaded configfs gadget? by default
that's loaded thru the systemd service script: "generic-board-startup"

Regards,

Thanks, I will try it later.

Robert Nelson <robertcnelson@gmail.com> 于 2018年8月15日周三 00:17写道: