<br><br><div class="gmail_quote">2009/10/7 Charles Lepple <span dir="ltr">&lt;<a href="mailto:clepple@gmail.com">clepple@gmail.com</a>&gt;</span><br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
[Let&#39;s move this over to the NUT-upsuser list, since we are not discussing source code. (The post you quoted was from a time when usbhid-ups was still under heavy development.) Thanks!]<br>
Info: <a href="http://lists.alioth.debian.org/mailman/listinfo/nut-upsuser" target="_blank">http://lists.alioth.debian.org/mailman/listinfo/nut-upsuser</a><div class="im"><br>
<br>
On Oct 6, 2009, at 9:22 AM, Zbigniew wrote:<br>
<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Hallo,<br>
<br>
Following the tips found at <a href="https://calomel.org/nut_ups.html" target="_blank">https://calomel.org/nut_ups.html</a> I was trying to<br>
make NUT operate &quot;APC Back UPS CS-350&quot;. The device introduces itself as:<br>
<br>
#v+<br>
 ugen0 at uhub0 port 1 &quot;American Power Conversion Back-UPS CS 350 FW:807.q7.I<br>
 USB FW:q7&quot; rev 1.10/0.06 addr 2<br>
#v-<br>
</blockquote>
<br></div>
So far, so good - the kernel sees it as a ugen device (versus uhid), which allows libusb to talk to it.<div class="im"><br>
<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
My config:<br>
<br>
#v+<br>
[apc]<br>
       driver = usbhid-ups<br>
       port = /dev/ugen0.00<br>
       pollfreq = 60<br>
       desc = &quot;Back UPS CS-350&quot;<br>
#v-<br>
<br>
<br>
Unfortunately, when I&#39;m trying to start UPS driver, it&#39;s complaining:<br>
<br>
#v+<br>
 # usbhid-ups -a apc<br>
 Network UPS Tools: 0.29 USB communication driver - core 0.33 (2.2.2)<br>
<br>
 No matching HID UPS found<br>
#v-<br>
</blockquote>
<br></div>
By default, running a driver as root will drop privileges to whatever user you set in the ./configure script (default: nobody).<br>
<br>
This post reports success on FreeBSD by adding &quot;-u root&quot; to the command line:<br>
<br>
<a href="http://www.mail-archive.com/nut-upsuser@lists.alioth.debian.org/msg04850.html" target="_blank">http://www.mail-archive.com/nut-upsuser@lists.alioth.debian.org/msg04850.html</a><br>
<br>
Not a good strategy for the long run, but it will let you see if things work.<br>
<br>
This email talks about using devd on FreeBSD to change permission on all of /dev/ugen[0-9]*:<br>
<br>
<a href="http://lists.alioth.debian.org/pipermail/nut-upsuser/2008-August/004345.html" target="_blank">http://lists.alioth.debian.org/pipermail/nut-upsuser/2008-August/004345.html</a><br>
<br>
I don&#39;t know if OpenBSD has something similar to devd, but the same principles should apply - libusb probably needs permission to the base /dev node for scanning the bus.</blockquote></div><br>just to add my cents here: iirc, there was also a need to set privileges on the bus, and not only on the device... we will have to track this to complete the user manual.<br>
<br>cheers,<br>Arnaud<br>-- <br>Linux / Unix Expert R&amp;D - Eaton - <a href="http://www.eaton.com/mgeops">http://www.eaton.com/mgeops</a><br>Network UPS Tools (NUT) Project Leader - <a href="http://www.networkupstools.org/">http://www.networkupstools.org/</a><br>
Debian Developer - <a href="http://www.debian.org">http://www.debian.org</a><br>Free Software Developer - <a href="http://arnaud.quette.free.fr/">http://arnaud.quette.free.fr/</a><br><br>