在电能质量监测设备中我们通常需要对设备的1 ~ 50次谐波有效值进行统计并记录,
但由于IEC61850-7-4的逻辑节点MHAI中对相电压和相电流的谐波和间谐波有效值仅分别使用了一个数据对象HRmsA和HRmsPhV进行描述,
在查找了部分资料后自己根据常规的应用方式YY了两种,通过IEDScout检验解析无错,如果哪位高手有更高端的方法,欢迎留言指正。
«/span>LN lnType=“MHAI_TYPE” lnClass=“MHAI” inst=“1”>
<span class="kwrd"><</span><span class="html">DOI</span> <span class="attr">name</span><span class="kwrd">="HRmsA1"</span> <span class="attr">desc</span><span class="kwrd">="1次谐波电流有效值"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="phsA"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="cVal"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="mag"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">DAI</span> <span class="attr">name</span><span class="kwrd">="f"</span> <span class="attr">sAddr</span> = <span class="kwrd">"HRMSVAL 0 1"</span> <span class="kwrd">/></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="phsB"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="cVal"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="mag"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">DAI</span> <span class="attr">name</span><span class="kwrd">="f"</span> <span class="attr">sAddr</span> = <span class="kwrd">"HRMSVAL 0 2"</span> <span class="kwrd">/></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="phsC"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="cVal"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="mag"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">DAI</span> <span class="attr">name</span><span class="kwrd">="f"</span> <span class="attr">sAddr</span> = <span class="kwrd">"HRMSVAL 0 3"</span> <span class="kwrd">/></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"></</span><span class="html">DOI</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">DOI</span> <span class="attr">name</span><span class="kwrd">="HRmsA2"</span> <span class="attr">desc</span><span class="kwrd">="2次谐波电流有效值"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="phsA"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="cVal"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="mag"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">DAI</span> <span class="attr">name</span><span class="kwrd">="f"</span> <span class="attr">sAddr</span> = <span class="kwrd">"HRMSVAL 0 4"</span> <span class="kwrd">/></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="phsB"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="cVal"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="mag"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">DAI</span> <span class="attr">name</span><span class="kwrd">="f"</span> <span class="attr">sAddr</span> = <span class="kwrd">"HRMSVAL 0 5"</span> <span class="kwrd">/></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="phsC"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="cVal"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="mag"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">DAI</span> <span class="attr">name</span><span class="kwrd">="f"</span> <span class="attr">sAddr</span> = <span class="kwrd">"HRMSVAL 0 6"</span> <span class="kwrd">/></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"></</span><span class="html">DOI</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">DOI</span> <span class="attr">name</span><span class="kwrd">="HRmsA3"</span> <span class="attr">desc</span><span class="kwrd">="3次谐波电流有效值"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="phsA"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="cVal"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="mag"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">DAI</span> <span class="attr">name</span><span class="kwrd">="f"</span> <span class="attr">sAddr</span> = <span class="kwrd">"HRMSVAL 0 7"</span> <span class="kwrd">/></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="phsB"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="cVal"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="mag"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">DAI</span> <span class="attr">name</span><span class="kwrd">="f"</span> <span class="attr">sAddr</span> = <span class="kwrd">"HRMSVAL 0 8"</span> <span class="kwrd">/></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="phsC"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="cVal"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="mag"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">DAI</span> <span class="attr">name</span><span class="kwrd">="f"</span> <span class="attr">sAddr</span> = <span class="kwrd">"HRMSVAL 0 9"</span> <span class="kwrd">/></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"></</span><span class="html">DOI</span><span class="kwrd">></span>
..........部分已省略 ..............
LN>
«/span>LNodeType id=“MHAI_TYPE” lnClass=“MHAI”>
..........部分已省略 ..............
<span class="kwrd"><</span><span class="html">DO</span> <span class="attr">name</span><span class="kwrd">="HRmsA1"</span> <span class="attr">type</span><span class="kwrd">="WYE"</span> <span class="kwrd">/></span>
<span class="kwrd"><</span><span class="html">DO</span> <span class="attr">name</span><span class="kwrd">="HRmsA2"</span> <span class="attr">type</span><span class="kwrd">="WYE"</span> <span class="kwrd">/></span>
<span class="kwrd"><</span><span class="html">DO</span> <span class="attr">name</span><span class="kwrd">="HRmsA3"</span> <span class="attr">type</span><span class="kwrd">="WYE"</span> <span class="kwrd">/></span>
..........部分已省略 ..............
LNodeType>
«/span>DOType id=“WYE” cdc=“WYE”>
<span class="kwrd"><</span><span class="html">SDO</span> <span class="attr">name</span><span class="kwrd">="phsA"</span> <span class="attr">type</span><span class="kwrd">="CMV"</span> <span class="kwrd">/></span>
<span class="kwrd"><</span><span class="html">SDO</span> <span class="attr">name</span><span class="kwrd">="phsB"</span> <span class="attr">type</span><span class="kwrd">="CMV"</span> <span class="kwrd">/></span>
<span class="kwrd"><</span><span class="html">SDO</span> <span class="attr">name</span><span class="kwrd">="phsC"</span> <span class="attr">type</span><span class="kwrd">="CMV"</span> <span class="kwrd">/></span>
DOType>
«/span>DOType id=“CMV” cdc=“CMV”>
<span class="kwrd"><</span><span class="html">DA</span> <span class="attr">name</span><span class="kwrd">="cVal"</span> <span class="attr">bType</span><span class="kwrd">="Struct"</span> <span class="attr">type</span><span class="kwrd">="Vector"</span> <span class="attr">dchg</span><span class="kwrd">="true"</span> <span class="attr">fc</span><span class="kwrd">="MX"</span> <span class="kwrd">/></span>
<span class="kwrd"><</span><span class="html">DA</span> <span class="attr">name</span><span class="kwrd">="q"</span> <span class="attr">bType</span><span class="kwrd">="Quality"</span> <span class="attr">qchg</span><span class="kwrd">="true"</span> <span class="attr">fc</span><span class="kwrd">="MX"</span> <span class="kwrd">/></span>
<span class="kwrd"><</span><span class="html">DA</span> <span class="attr">name</span><span class="kwrd">="t"</span> <span class="attr">bType</span><span class="kwrd">="Timestamp"</span> <span class="attr">fc</span><span class="kwrd">="MX"</span> <span class="kwrd">/></span>
DOType>
«/span>DAType id=“Vector”>
<span class="kwrd"><</span><span class="html">BDA</span> <span class="attr">name</span><span class="kwrd">="mag"</span> <span class="attr">bType</span><span class="kwrd">="Struct"</span> <span class="attr">type</span><span class="kwrd">="AnalogueValue"</span> <span class="kwrd">/></span>
DAType>
«/span>DAType id=“AnalogueValue”>
<span class="kwrd"><</span><span class="html">BDA</span> <span class="attr">name</span><span class="kwrd">="f"</span> <span class="attr">bType</span><span class="kwrd">="FLOAT32"</span> <span class="kwrd">/></span>
DAType>
«/span>LN lnType=“MHAI_TYPE” lnClass=“MHAI” inst=“1”>
<span class="kwrd"><</span><span class="html">DOI</span> <span class="attr">name</span><span class="kwrd">="HRmsA"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="phsAHar"</span> <span class="attr">ix</span><span class="kwrd">="0"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="mag"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">DAI</span> <span class="attr">name</span><span class="kwrd">="f"</span> <span class="attr">sAddr</span><span class="kwrd">="HARM 0 1"</span><span class="kwrd">/></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="phsAHar"</span> <span class="attr">ix</span><span class="kwrd">="1"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="mag"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">DAI</span> <span class="attr">name</span><span class="kwrd">="f"</span> <span class="attr">sAddr</span><span class="kwrd">="HARM 0 4"</span><span class="kwrd">/></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="phsAHar"</span> <span class="attr">ix</span><span class="kwrd">="2"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="mag"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">DAI</span> <span class="attr">name</span><span class="kwrd">="f"</span> <span class="attr">sAddr</span><span class="kwrd">="HARM 0 7"</span><span class="kwrd">/></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="phsBHar"</span> <span class="attr">ix</span><span class="kwrd">="0"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="mag"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">DAI</span> <span class="attr">name</span><span class="kwrd">="f"</span> <span class="attr">sAddr</span><span class="kwrd">="HARM 0 2"</span><span class="kwrd">/></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="phsBHar"</span> <span class="attr">ix</span><span class="kwrd">="1"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="mag"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">DAI</span> <span class="attr">name</span><span class="kwrd">="f"</span> <span class="attr">sAddr</span><span class="kwrd">="HARM 0 5"</span><span class="kwrd">/></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="phsBHar"</span> <span class="attr">ix</span><span class="kwrd">="2"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="mag"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">DAI</span> <span class="attr">name</span><span class="kwrd">="f"</span> <span class="attr">sAddr</span><span class="kwrd">="HARM 0 8"</span><span class="kwrd">/></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="phsCHar"</span> <span class="attr">ix</span><span class="kwrd">="0"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="mag"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">DAI</span> <span class="attr">name</span><span class="kwrd">="f"</span> <span class="attr">sAddr</span><span class="kwrd">="HARM 0 3"</span><span class="kwrd">/></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="phsCHar"</span> <span class="attr">ix</span><span class="kwrd">="1"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="mag"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">DAI</span> <span class="attr">name</span><span class="kwrd">="f"</span> <span class="attr">sAddr</span><span class="kwrd">="HARM 0 6"</span><span class="kwrd">/></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="phsCHar"</span> <span class="attr">ix</span><span class="kwrd">="2"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">SDI</span> <span class="attr">name</span><span class="kwrd">="mag"</span><span class="kwrd">></span>
<span class="kwrd"><</span><span class="html">DAI</span> <span class="attr">name</span><span class="kwrd">="f"</span> <span class="attr">sAddr</span><span class="kwrd">="HARM 0 9"</span><span class="kwrd">/></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"></</span><span class="html">SDI</span><span class="kwrd">></span>
<span class="kwrd"></</span><span class="html">DOI</span><span class="kwrd">></span>
........ 部分已省略 .........
LN>
«/span>LNodeType id=“MHAI_TYPE” lnClass=“MHAI”>
........ 部分已省略 .........
<span class="kwrd"><</span><span class="html">DO</span> <span class="attr">name</span><span class="kwrd">="HRmsA"</span> <span class="attr">type</span><span class="kwrd">="HWYE"</span> <span class="kwrd">/></span>
........ 部分已省略 .........
LNodeType>
«/span>DOType id=“HWYE” cdc=“HWYE”>
<span class="kwrd"><</span><span class="html">DA</span> <span class="attr">count</span><span class="kwrd">="3"</span> <span class="attr">name</span><span class="kwrd">="phsAHar"</span> <span class="attr">bType</span><span class="kwrd">="Struct"</span> <span class="attr">type</span><span class="kwrd">="Vector"</span> <span class="attr">dchg</span><span class="kwrd">="true"</span> <span class="attr">dupd</span><span class="kwrd">="true"</span> <span class="attr">fc</span><span class="kwrd">="MX"</span> <span class="kwrd">/></span>
<span class="kwrd"><</span><span class="html">DA</span> <span class="attr">count</span><span class="kwrd">="3"</span> <span class="attr">name</span><span class="kwrd">="phsBHar"</span> <span class="attr">bType</span><span class="kwrd">="Struct"</span> <span class="attr">type</span><span class="kwrd">="Vector"</span> <span class="attr">dchg</span><span class="kwrd">="true"</span> <span class="attr">dupd</span><span class="kwrd">="true"</span> <span class="attr">fc</span><span class="kwrd">="MX"</span> <span class="kwrd">/></span>
<span class="kwrd"><</span><span class="html">DA</span> <span class="attr">count</span><span class="kwrd">="3"</span> <span class="attr">name</span><span class="kwrd">="phsCHar"</span> <span class="attr">bType</span><span class="kwrd">="Struct"</span> <span class="attr">type</span><span class="kwrd">="Vector"</span> <span class="attr">dchg</span><span class="kwrd">="true"</span> <span class="attr">dupd</span><span class="kwrd">="true"</span> <span class="attr">fc</span><span class="kwrd">="MX"</span> <span class="kwrd">/></span>
<span class="kwrd"><</span><span class="html">DA</span> <span class="attr">name</span><span class="kwrd">="q"</span> <span class="attr">bType</span><span class="kwrd">="Quality"</span> <span class="attr">qchg</span><span class="kwrd">="true"</span> <span class="attr">fc</span><span class="kwrd">="MX"</span> <span class="kwrd">/></span>
<span class="kwrd"><</span><span class="html">DA</span> <span class="attr">name</span><span class="kwrd">="t"</span> <span class="attr">bType</span><span class="kwrd">="Timestamp"</span> <span class="attr">fc</span><span class="kwrd">="MX"</span> <span class="kwrd">/></span>
<span class="kwrd"><</span><span class="html">DA</span> <span class="attr">name</span><span class="kwrd">="numHar"</span> <span class="attr">bType</span><span class="kwrd">="INT16U"</span> <span class="attr">fc</span><span class="kwrd">="CF"</span> <span class="kwrd">/></span>
DOType>
«/span>DAType id=“Vector”>
<span class="kwrd"><</span><span class="html">BDA</span> <span class="attr">name</span><span class="kwrd">="mag"</span> <span class="attr">bType</span><span class="kwrd">="Struct"</span> <span class="attr">type</span><span class="kwrd">="AnalogueValue"</span> <span class="kwrd">/></span>
DAType>
«/span>DAType id=“AnalogueValue”>
<span class="kwrd"><</span><span class="html">BDA</span> <span class="attr">name</span><span class="kwrd">="f"</span> <span class="attr">bType</span><span class="kwrd">="FLOAT32"</span> <span class="kwrd">/></span>
DAType>