[Nut-upsdev] HA: PowerCOM HID PDC non-compliance
Morozov Alexey
morozov at pcm.ru
Mon Jan 25 18:39:55 UTC 2010
Dear Arjen,
Thank you for your comments. I've forwarded it to software engineers to take into account in future development.
Sincerely yours
--
Alexey Morozov
distribution manager
________________________________
От: Arjen de Korte [mailto:nut+devel at de-korte.org]
Отправлено: Ср, 20.01.2010 11:50
Кому: Morozov Alexey
Копия: nut-upsdev
Тема: PowerCOM HID PDC non-compliance
Alexey,
I posted this before, but never got a reply. So I'm reposting this again.
In the present HID PDC implementation by PowerCOM, expect problems
with the non-compliant implementation of the DelayBeforeShutdown and
DelayBeforeStartup pages.
Third party applications will expect that these follow the HID PDC
specifications if you name them like this (and break terribly in the
process). In NUT we can (for now) easily implement the PowerCOM
specific formatting rules, but not all applications may be able to do
so. The same goes for UPS.PowerSummary.Voltage,
UPS.PowerSummary.ConfigVoltage, UPS.Battery.Voltage and
UPS.Battery.ConfigVoltage. These should deal with the battery voltage,
not the output voltage like implemented in the PowerCOM HID now.
If in the future (?) PowerCOM has newer UPS designs that unlike the
present one are native HID PDC from the start (instead of a serial
protocol encapsulated in HID PDC), this will be a problem. It would
require different ways to deal with these, based on the model of the
UPS (compliant or non-compliant versions). Generally it is *very* poor
design practice to *not* follow a specification. Please consider to
*not* use the standard Power Device Pages (x84) in cases like these,
but to create vendor specific ones instead (pages 0xFF00 to 0xFFFF are
reserved for that). It is almost always better to *not* have a HID PDC
path than to have an *incorrect* implemented one.
So instead of using 0x00840056 (DelayBeforeStartup) and 0x00840057
(DelayBeforeShutdown), use 0xFFFF0056 (PCMDelayBeforeStartup) and
0xFFFF0057 (PCMDelayBeforeShutdown) instead. This would allow
applications that know about the PowerCOM specific implementation to
use these values and not break ones that don't.
Best regards, Arjen
--
Please keep list traffic on the list
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.alioth.debian.org/pipermail/nut-upsdev/attachments/20100125/0e46cbab/attachment.htm>
More information about the Nut-upsdev
mailing list