我在zcl_electrical_measurement.h中,电流,电压,功率这些属性参数,已经上报成功,但是电量属性不清楚是哪个?
#define ATTRID_ELECTRICAL_MEASUREMENT_ACTIVE_POWER 0x050B //功率
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_VOLTAGE 0x0505 //电压
但是以下哪个是耗电量呢?
// Server Attributes
#define ATTRID_ELECTRICAL_MEASUREMENT_MEASUREMENT_TYPE 0x0000 // M, R, BITMAP 32
#define ATTRID_ELECTRICAL_MEASUREMENT_DC_VOLTAGE 0x0100 // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_DC_VOLTAGE_MIN 0x0101 // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_DC_VOLTAGE_MAX 0x0102 // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_DC_CURRENT 0x0103 // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_DC_CURRENT_MIN 0x0104 // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_DC_CURRENT_MAX 0x0105 // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_DC_POWER 0x0106 // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_DC_POWER_MIN 0x0107 // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_DC_POWER_MAX 0x0108 // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_DC_VOLTAGE_MULTIPLIER 0x0200 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_DC_VOLTAGE_DIVISOR 0x0201 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_DC_CURRENT_MULTIPLIER 0x0202 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_DC_CURRENT_DIVISOR 0x0203 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_DC_POWER_MULTIPLIER 0x0204 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_DC_POWER_DIVISOR 0x0205 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_AC_FREQUENCY 0x0300 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_AC_FREQUENCY_MIN 0x0301 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_AC_FREQUENCY_MAX 0x0302 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_NEUTRAL_CURRENT 0x0303 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_TOTAL_ACTIVE_POWER 0x0304 // O, R, INT32
#define ATTRID_ELECTRICAL_MEASUREMENT_TOTAL_REACTIVE_POWER 0x0305 // O, R, INT32
#define ATTRID_ELECTRICAL_MEASUREMENT_TOTAL_APPARENT_POWER 0x0306 // O, R, UINT32
#define ATTRID_ELECTRICAL_MEASUREMENT_MEASURED_1ST_HARMONIC_CURRENT 0x0307 // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_MEASURED_3RD_HARMONIC_CURRENT 0x0308 // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_MEASURED_5TH_HARMONIC_CURRENT 0x0309 // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_MEASURED_7TH_HARMONIC_CURRENT 0x030A // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_MEASURED_9TH_HARMONIC_CURRENT 0x030B // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_MEASURED_11TH_HARMONIC_CURRENT 0x030C // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_MEASURED_PHASE_1ST_HARMONIC_CURRENT 0x030D // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_MEASURED_PHASE_3RD_HARMONIC_CURRENT 0x030E // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_MEASURED_PHASE_5TH_HARMONIC_CURRENT 0x030F // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_MEASURED_PHASE_7TH_HARMONIC_CURRENT 0x0310 // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_MEASURED_PHASE_9TH_HARMONIC_CURRENT 0x0311 // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_MEASURED_PHASE_11TH_HARMONIC_CURRENT 0x0312 // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_AC_FREQUENCY_MULTIPLIER 0x0400 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_AC_FREQUENCY_DIVISOR 0x0401 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_POWER_MULTIPLIER 0x0402 // O, R, UINT32
#define ATTRID_ELECTRICAL_MEASUREMENT_POWER_DIVISOR 0x0403 // O, R, UINT32
#define ATTRID_ELECTRICAL_MEASUREMENT_HARMONIC_CURRENT_MULTIPLIER 0x0404 // O, R, INT8
#define ATTRID_ELECTRICAL_MEASUREMENT_PHASE_HARMONIC_CURRENT_MULTIPLIER 0x0405 // O, R, INT8
#define ATTRID_ELECTRICAL_MEASUREMENT_INSTANTANEOUS_VOLTAGE 0x0500 // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_INSTANTANEOUS_LINE_CURRENT 0x0501 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_INSTANTANEOUS_ACTIVE_CURRENT 0x0502 // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_INSTANTANEOUS_REACTIVE_CURRENT 0x0503 // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_INSTANTANEOUS_POWER 0x0504 // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_VOLTAGE 0x0505 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_VOLTAGE_MIN 0x0506 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_VOLTAGE_MAX 0x0507 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_CURRENT 0x0508 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_CURRENT_MIN 0x0509 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_CURRENT_MAX 0x050A // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_ACTIVE_POWER 0x050B // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_ACTIVE_POWER_MIN 0x050C // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_ACTIVE_POWER_MAX 0x050D // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_REACTIVE_POWER 0x050E // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_APPARENT_POWER 0x050F // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_POWER_FACTOR 0x0510 // O, R, INT8
#define ATTRID_ELECTRICAL_MEASUREMENT_AVERAGE_RMS_VOLTAGE_MEASUREMENT_PERIOD 0x0511 // O, R/W, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_AVERAGE_RMS_OVER_VOLTAGE_COUNTER 0x0512 // O, R/W, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_AVERAGE_RMS_UNDER_VOLTAGE_COUNTER 0x0513 // O, R/W, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_EXTREME_OVER_VOLTAGE_PERIOD 0x0514 // O, R/W, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_EXTREME_UNDER_VOLTAGE_PERIOD 0x0515 // O, R/W, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_VOLTAGE_SAG_PERIOD 0x0516 // O, R/W, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_VOLTAGE_SWELL_PERIOD 0x0517 // O, R/W, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_AC_VOLTAGE_MULTIPLIER 0x0600 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_AC_VOLTAGE_DIVISOR 0x0601 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_AC_CURRENT_MULTIPLIER 0x0602 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_AC_CURRENT_DIVISOR 0x0603 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_AC_POWER_MULTIPLIER 0x0604 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_AC_POWER_DIVISOR 0x0605 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_DC_OVERLOAD_ALARMS_MASK 0x0700 // O, R/W, BITMAP8
#define ATTRID_ELECTRICAL_MEASUREMENT_DC_VOLTAGE_OVERLOAD 0x0701 // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_DC_CURRENT_OVERLOAD 0x0702 // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_AC_ALARMS_MASK 0x0800 // O, R/W, BITMAP16
#define ATTRID_ELECTRICAL_MEASUREMENT_AC_VOLTAGE_OVERLOAD 0x0801 // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_AC_CURRENT_OVERLOAD 0x0802 // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_AC_ACTIVE_POWER_OVERLOAD 0x0803 // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_AC_REACTIVE_POWER_OVERLOAD 0x0804 // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_AVERAGE_RMS_OVER_VOLTAGE 0x0805 // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_AVERAGE_RMS_UNDER_VOLTAGE 0x0806 // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_EXTREME_OVER_VOLTAGE 0x0807 // O, R/W, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_EXTREME_UNDER_VOLTAGE 0x0808 // O, R/W, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_VOLTAGE_SAG 0x0809 // O, R/W, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_VOLTAGE_SWELL 0x080A // O, R/W, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_LINE_CURRENT_PH_B 0x0901 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_ACTIVE_CURRENT_PH_B 0x0902 // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_REACTIVE_CURRENT_PH_B 0x0903 // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_VOLTAGE_PH_B 0x0905 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_VOLTAGE_MIN_PH_B 0x0906 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_VOLTAGE_MAX_PH_B 0x0907 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_CURRENT_PH_B 0x0908 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_CURRENT_MIN_PH_B 0x0909 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_CURRENT_MAX_PH_B 0x090A // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_ACTIVE_POWER_PH_B 0x090B // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_ACTIVE_POWER_MIN_PH_B 0x090C // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_ACTIVE_POWER_MAX_PH_B 0x090D // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_REACTIVE_POWER_PH_B 0x090E // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_APPARENT_POWER_PH_B 0x090F // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_POWER_FACTOR_PH_B 0x0910 // O, R, INT8
#define ATTRID_ELECTRICAL_MEASUREMENT_AVERAGE_RMS_VOLTAGE_MEASURE_PERIOD_PH_B 0x0911 // O, R/W, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_AVERAGE_RMS_OVER_VOLTAGE_COUNTER_PH_B 0x0912 // O, R/W, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_AVERAGE_UNDER_VOLTAGE_COUNTER_PH_B 0x0913 // O, R/W, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_EXTREME_OVER_VOLTAGE_PERIOD_PH_B 0x0914 // O, R/W, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_EXTREME_UNDER_VOLTAGE_PERIOD_PH_B 0x0915 // O, R/W, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_VOLTAGE_SAG_PERIOD_PH_B 0x0916 // O, R/W, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_VOLTAGE_SWELL_PERIOD_PH_B 0x0917 // O, R/W, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_LINE_CURRENT_PH_C 0x0A01 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_ACTIVE_CURRENT_PH_C 0x0A02 // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_REACTIVE_CURRENT_PH_C 0x0A03 // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_VOLTAGE_PH_C 0x0A05 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_VOLTAGE_MIN_PH_C 0x0A06 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_VOLTAGE_MAX_PH_C 0x0A07 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_CURRENT_PH_C 0x0A08 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_CURRENT_MIN_PH_C 0x0A09 // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_CURRENT_MAX_PH_C 0x0A0A // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_ACTIVE_POWER_PH_C 0x0A0B // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_ACTIVE_POWER_MIN_PH_C 0x0A0C // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_ACTIVE_POWER_MAX_PH_C 0x0A0D // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_REACTIVE_POWER_PH_C 0x0A0E // O, R, INT16
#define ATTRID_ELECTRICAL_MEASUREMENT_APPARENT_POWER_PH_C 0x0A0F // O, R, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_POWER_FACTOR_PH_C 0x0A10 // O, R, INT8
#define ATTRID_ELECTRICAL_MEASUREMENT_AVERAGE_RMS_VOLTAGE_MEASURE_PERIOD_PH_C 0x0A11 // O, R/W, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_AVERAGE_RMS_OVER_VOLTAGE_COUNTER_PH_C 0x0A12 // O, R/W, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_AVERAGE_UNDER_VOLTAGE_COUNTER_PH_C 0x0A13 // O, R/W, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_EXTREME_OVER_VOLTAGE_PERIOD_PH_C 0x0A14 // O, R/W, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_EXTREME_UNDER_VOLTAGE_PERIOD_PH_C 0x0A15 // O, R/W, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_VOLTAGE_SAG_PERIOD_PH_C 0x0A16 // O, R/W, UINT16
#define ATTRID_ELECTRICAL_MEASUREMENT_RMS_VOLTAGE_SWELL_PERIOD_PH_C 0x0A17 // O, R/W, UINT16
Alvin Chen:
// Battery Information
#define ATTRID_POWER_CFG_BATTERY_VOLTAGE0x0020
#define ATTRID_POWER_CFG_BATTERY_PERCENTAGE_REMAINING0x0021
这是剩余电量
YiKai Chen:
你可以查一下 zcl spec.
user4381970:
回复 YiKai Chen:
他问的应该是插座检测ac的设备用电量吧。不是dc电池设备。手册4.9有电压电流功率 没有电量呢