[Nut-upsdev] MGE NMC and NutShutdownModule (and other stuff)

Arjen de Korte nut+devel at de-korte.org
Fri Nov 6 21:04:22 UTC 2009


Citeren Marco Chiappero <marco op absence.it>:

> And the netxml_get_page(subdriver->summary) should be called before  
> parsing alarms (let's suppose we used the test button, the  
> BelowCapacity flag is read, set and soon after cleared).

We can't do that. If you press the 'Shutdown Test' button on the same  
page, the NMC sends the following three alarm messages:

<ALARM level="2" object="UPS.PowerSummary.PresentStatus.ACPresent"  
value="0" date="2009/11/06-21:52:01" messageID="BF37RY"> Normal AC NOK  
</ALARM>
<ALARM level="2" object="UPS.PowerSummary.PresentStatus.Discharging"  
value="1" date="2009/11/06-21:52:06" messageID="TI6VK"> UPS on battery  
</ALARM>
<ALARM level="3"  
object="UPS.PowerSummary.PresentStatus.BelowRemainingCapacityLimit"  
value="1" date="2009/11/06-21:52:37" messageID="9EERW0"> Low battery  
</ALARM>

When you read the corresponding values from the summary page, the  
values are reversed however. If we would parse the summary page  
between these alarms (be it right after parsing an alarm or just  
before receiving the next), with every new incoming alarm, the  
previous status would be reset again. So if we want to keep the alarms  
as they are, we should disregard the values set by the summary page.  
However, since the above alarm bits are never cleared by an alarm  
message after the test, this would mean that pressing this test button  
once would effectively permanently disable the outlet.

During 'normal' operation, the values received through alarm messages  
will be the same as the values that are read through the summary page.  
In that case, the order in which we process them, is irrelevant. We  
might even not parse the alarms at all.

Best regards, Arjen
-- 
Please keep list traffic on the list




More information about the Nut-upsdev mailing list