What's new

HID driver not present (UPS)

  • SNBForums Code of Conduct

    SNBForums is a community for everyone, no matter what their level of experience.

    Please be tolerant and patient of others, especially newcomers. We are all here to share and learn!

    The rules are simple: Be patient, be nice, be helpful or be gone!

Simone

New Around Here
Hi!
I'm running the Merlin 378.51 on a RT-AC68U, but when I connect my APC UPS via USB this is shown in the device list but HID driver seems not present (and apcupsd does then not work...):

T: Bus=03 Lev=01 Prnt=01 Port=01 Cnt=01 Dev#= 2 Spd=12 MxCh= 0
D: Ver= 1.10 Cls=00(>ifc ) Sub=00 Prot=00 MxPS=32 #Cfgs= 1
P: Vendor=051d ProdID=0002 Rev= 1.06
S: Manufacturer=American Power Conversion
S: Product=Back-UPS XS 1100CI FW:920.T2 .I USB FW:T3
S: SerialNumber=3B1348X30739
C:* #Ifs= 1 Cfg#= 1 Atr=e0 MxPwr= 24mA
I:* If#= 0 Alt= 0 #EPs= 1 Cls=03(HID ) Sub=00 Prot=00 Driver=(none)
E: Ad=81(I) Atr=03(Int.) MxPS= 6 Ivl=10ms


From the changelog I see that HID support have been re-added with
376.48 Beta 1 (18-Oct-2014):
- NEW: Added HID support to ARM kernel (AC56,AC68,AC87)
- FIXED: Re-added the USB HID kernel module needed for UPS monitoring
(patch by ryzhov_al)

Please can someone help??

Thanks a lot.
KR
Simone
 
HI
From the changelog I see that HID support have been re-added with 376.48 Beta 1 (18-Oct-2014):
- NEW: Added HID support to ARM kernel (AC56,AC68,AC87)
- FIXED: Re-added the USB HID kernel module needed for UPS monitoring
(patch by ryzhov_al)

Please can someone help??
It's added to kernel config, not to firmware image. You need to compile firmware and take appropriate modules from kernel dir (see how).

After then, put it to USB drive. It must be loaded before starting UPS software:
Code:
  MOD_DIR=/opt/usr/lib/modules
  insmod $MOD_DIR/input-core.ko
  insmod $MOD_DIR/hid.ko
  insmod $MOD_DIR/usbhid.ko
 
HI
It's added to kernel config, not to firmware image. You need to compile firmware and take appropriate modules from kernel dir (see how).

After then, put it to USB drive. It must be loaded before starting UPS software:
Code:
  MOD_DIR=/opt/usr/lib/modules
  insmod $MOD_DIR/input-core.ko
  insmod $MOD_DIR/hid.ko
  insmod $MOD_DIR/usbhid.ko

Hi ryzhov, I really thank you for your reply and information provided.
I have a very small experience in unix and I did not compiled very often. Anyway I have downloaded all the packages and followed the guide but till now I have problem when compiling the firmware, execution stops after 2/3 minutes for Arc devices and after 13/14 min minutes for Broadcom devices, in all the case the images are not created.
I'll try to debug the issues and enjoy the modules.

KR
Simone
 
Hi,

I am trying to get an APC UPS working with apcupsd in merlin on a Asus RT-AC5300 router. I can see the APC detected in dmesg but I am missing the usb drivers. I saw you posted a few messages regarding building your own firmware and copying the drivers but the link you provided then is no longer working. Can you please share with me how to do this on the latest firmware version?

Thanks!
 
Hi! ryzhov_al and other fellows,

I know that this thread is pretty old and certainly outdated but I will take a chance that someone can help.

I have the same problem as the original requestor:

Trying to monitor an APC BACK-UPS SE 750 on my ASUS RT-AC3200 router running merlin 384.13_10
Linux RT-AC3200 2.6.36.4brcmarm #1 SMP PREEMPT Sun Jun 28 14:08:42 EDT 2020 armv7l ASUSWRT-Merlin

It seems that I need to add the 'module' ohci_hcd to my merlin-end-of-support modem.

# ls -l /sys/bus/usb/drivers/
drwxr-xr-x 2 admin root 0 Oct 13 23:23 asix
drwxr-xr-x 2 admin root 0 Oct 13 23:23 cdc_acm
drwxr-xr-x 2 admin root 0 Oct 13 23:23 cdc_ether
drwxr-xr-x 2 admin root 0 Oct 13 23:23 cdc_mbim
drwxr-xr-x 2 admin root 0 Oct 13 23:23 cdc_ncm
drwxr-xr-x 2 admin root 0 Oct 13 23:23 cdc_wdm
drwxr-xr-x 2 admin root 0 Oct 13 23:23 hub
drwxr-xr-x 2 admin root 0 Oct 13 23:23 qmi_wwan
drwxr-xr-x 2 admin root 0 Oct 13 23:23 rndis_host
drwxr-xr-x 2 admin root 0 Oct 13 23:23 usb
drwxr-xr-x 2 admin root 0 Oct 13 23:23 usb-storage
drwxr-xr-x 2 admin root 0 Oct 13 23:23 usbfs
drwxr-xr-x 2 admin root 0 Oct 13 23:23 usblp

Can you help me ?

Thanks
 
Last edited:
Chances are you do not need to compile a custom firmware. If you are using the latest firmware builds, the required kernel modules are likely already in the firmware, just not loaded.

SSH into your router and search in /lib/modules/xxxxx directory, where xxxx will be the kernel version for your router. You will likely find the required modules there. You just need to load them them insmod.

As an example, here is my startup script for NUT;

Code:
#!/bin/sh

if [ -f /jffs/ups-powerdownflag ]; then
    rm /jffs/ups-powerdownflag
fi

insmod /lib/modules/4.1.27/kernel/drivers/input/input-core.ko
insmod /lib/modules/4.1.27/kernel/drivers/hid/hid.ko
insmod /lib/modules/4.1.27/kernel/drivers/hid/usbhid/usbhid.ko

upsdrvctl -u ClientAdmin start
sleep 4
upsd -u ClientAdmin
sleep 4
upsmon -p

Doing a quick search on my AC86U, the modules you are looking for is in /lib/modules/4.1.27/drivers/usb/host
 
Hi! Jeffrey,

Your suggestion is perfect, apcupsd now works correctly

Here is my new startup script /opt/etc/init.d/S17apcupsd for apcupsd environment:

#!/bin/sh

if [ -f /jffs/ups-powerdownflag ]; then
rm /jffs/ups-powerdownflag
fi

KERNELVAL=`ls /lib/modules/`
insmod /lib/modules/$KERNELVAL/kernel/drivers/input/input-core.ko
insmod /lib/modules/$KERNELVAL/kernel/drivers/hid/hid.ko
insmod /lib/modules/$KERNELVAL/kernel/drivers/hid/usbhid.ko

sleep 4

ENABLED=yes
PROCS=apcupsd
ARGS=""
PREARGS=""
DESC=$PROCS
PATH=/opt/sbin:/opt/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin

. /opt/etc/init.d/rc.func

Thanks
 
Last edited:

Latest threads

Support SNBForums w/ Amazon

If you'd like to support SNBForums, just use this link and buy anything on Amazon. Thanks!

Sign Up For SNBForums Daily Digest

Get an update of what's new every day delivered to your mailbox. Sign up here!
Top