[Nut-upsdev] megatec driver and usb-to-serial converters
carlos.efr at mail.telepac.pt
Wed Nov 1 21:07:19 CET 2006
Currently, the "megatec" driver only supports UPSes which have a
serial (RS232) interface.
However, I'm under the impression that most of the models that speak
the megatec protocol, and have an USB interface, just have a standard
serial-to-USB converter inside. This being the case, there should be a
"/dev/ttyUSBx" device which the megatec driver could use just as if it
were talking to the UPS over an RS232 cable.
But... either this isn't the case, or these converters aren't
recognized by the kernel's "usbserial" driver as such, and all that
needs to be done is just convice the kernel to see the converter.
This is something that I would like to know (even if just to be able
to point people who email me about not having serial ports available,
or with models that lack a serial interface, in the right direction).
So, if someone out there with an UPS supported by the "megatec" driver
(and with an USB interface) wants to try this, I would appreciate the
Here are the general steps:
1. Connect the UPS using the USB cable (AFAIK, the USB and serial
cables can't be connected simultaneously);
2. Run "lsusb -v" to find the vendorID and productID for the UPS;
3. "rmmod usbserial" if the module happens to be loaded already;
4. Load the module again with "modprobe usbserial vendor=0x...
product=0x..." (or add this to your "/etc/modprobe.conf" file as
"options usbserial vendor=0x... product=0x...");
5 .If there is now a "/dev/ttyUSBx" device available, configure
"megatec" to use it.
My Mustek PowerMust 600 doesn't have an USB interface, so I can't test
this myself, and I have no idea if this works with some models, all
models, or no models (*)...
(*) Or what happens if the usbserial driver gains successful control
of a device that happens to be something else entirely not a
usb-to-serial converter... Although I really doubt something bad would
happen, I'm just covering my ass here... :)
More information about the Nut-upsdev