我们今天能为您提供什么帮助?

What is the difference between PackedBool and MaskedBool?

Issue:

The Device Importer in ION Enterprise / SPM 7 provides options for both PackedBool and MaskedBool, which appear identical in documentation and can cause confusion when selecting the appropriate data type.

Product Line:

Power Monitoring Expert 9.0

Power Monitoring Expert 2020

Power Monitoring Expert 2021

Power Monitoring Expert 2022

Power Monitoring Expert 2023

Power Monitoring Expert 2024

Environment:

Modbus Device Importer (Starting with PME 9.0 MDI was renamed to Device Type Editor)
Boolean register mapping

Cause:

The ION Enterprise User Guide and SPM 7 User Guide define MaskedBool and PackedBool using the same glossary description, grouping them together as equivalent data types. While this description is generally accurate, it does not explain the subtle implementation difference between the two.

Glossary definition (from the guides):
MaskedBool or PackedBool:
A 16‑bit value that is interpreted according to the bit pattern described by the Mask attribute. Bits exposed by the mask can be read or written without affecting the value of other bits. Unmasked bits are interpreted as 0 on a read and are unaffected on a write. Undeclared bits of a mask are interpreted as unmasked (for example, mask="0x7F" is interpreted as

0x007F). The value that is read or written is determined by using enumeration ordinals. If used for read‑only Boolean data, enumerations are not required. If no mask is specified, all bits are relevant.

Resolution:
Although the glossary groups them together, there is a subtle difference in how they are read:
  • PackedBool

    • Reads all bits of the register at once
    • Treats the register as a bit field
  • MaskedBool

    • Reads only the bit(s) defined by the mask
    • To read the entire register, all 16 bits would need to be read individually

In practice, both data types ultimately achieve the same goal, which is why the guides describe them together. When presented with a choice between PackedBool and MaskedBool, either selection is generally acceptable.

Recommendation:

If you are using an older version of PME, consider upgrading to the latest version for improved protocol support and security. For assistance with integration or upgrades, contact Schneider Electric Technical Support at: pmo.support@se.com

PME Version History

施耐德電機Taiwan

探索更多
系列:
探索更多
系列:
  • 產品文檔
  • 軟體下載
  • 產品選型工具
  • 產品替代和替換
  • 幫助和聯絡中心
  • 尋找我們的辦公室
  • 取得報價
  • 施耐德電機社群
  • 人才招募
  • 公司簡介
  • 舉報不當行為
  • 無障礙
  • 新聞中心
  • 投資者
  • 專業洞察
  • 台灣施耐德電機學院
  • 綠色影響力落差調查
  • Schneider Go Green 2025
  • 隱私政策
  • Cookie通告
  • 使用條款
  • Change your cookie settings