It is currently April 28th, 2024, 10:26 am

PowerState STATUS2

Report bugs with the Rainmeter application and suggest features.
Alex Becherer

PowerState STATUS2

Post by Alex Becherer »

i just noticed that

Code: Select all

[MeasureBatteryStatus]
Measure=Plugin
Plugin=PowerPlugin.dll
PowerState=STATUS2
UpdateDivider=5
returns 9 when charging.
according to Microsoft it should be 8. http://msdn.microsoft.com/en-us/library/aa373232(VS.85).aspx
poiru
Developer
Posts: 2872
Joined: April 17th, 2009, 12:18 pm

Re: PowerState STATUS2

Post by poiru »

From MSDN:
BatteryFlag
The battery charge status. This member can contain one or more of the following flags.
The key part is "one or more of the following flags", which means that its value can be equal to a flag (e.g. 1 for High) or a combination of flags using the bitwise OR operation (e.g. 9 for High and Charging). To test for flags, you should use the bitwise AND operation with Calcs.
Alex Becherer

Re: PowerState STATUS2

Post by Alex Becherer »

my bad then. thanks.