news 2026/6/10 19:33:35

Linux上位机Windows上位机C++(QT)开发三菱上位机MC 1E 二进制通信 源码 C++快速实现三菱 MC 1E 二进制 支持三菱FX和A系列PLC A-1E 帧 国产化系统上位机

作者头像

张小明

前端开发工程师

1.2k 24
文章封面图
Linux上位机Windows上位机C++(QT)开发三菱上位机MC 1E 二进制通信 源码 C++快速实现三菱 MC 1E 二进制 支持三菱FX和A系列PLC A-1E 帧 国产化系统上位机

更多源码下载https://8ma.co/res/YBMV713F

<?xml version="1.0" encoding="UTF-8"?> <ui version="4.0"> <class>MitsubishiPlc</class> <widget class="QWidget" name="MitsubishiPlc"> <property name="geometry"> <rect> <x>0</x> <y>0</y> <width>1030</width> <height>646</height> </rect> </property> <property name="windowTitle"> <string>QT(C++)与三菱MC 1E 二进制协议通信</string> </property> <layout class="QGridLayout" name="gridLayout"> <item row="0" column="0"> <layout class="QVBoxLayout" name="verticalLayout" stretch="6,4"> <item> <layout class="QVBoxLayout" name="verticalLayout_2"> <item> <widget class="QWidget" name="widget" native="true"> <property name="sizePolicy"> <sizepolicy hsizetype="Preferred" vsizetype="Fixed"> <horstretch>0</horstretch> <verstretch>0</verstretch> </sizepolicy> </property> <property name="minimumSize"> <size> <width>0</width> <height>340</height> </size> </property> <widget class="QLineEdit" name="lineEdit_2"> <property name="geometry"> <rect> <x>460</x> <y>60</y> <width>81</width> <height>31</height> </rect> </property> <property name="text"> <string>6000</string> </property> </widget> <widget class="QLabel" name="label_4"> <property name="geometry"> <rect> <x>60</x> <y>140</y> <width>61</width> <height>16</height> </rect> </property> <property name="text"> <string>读地址:</string> </property> </widget> <widget class="QPushButton" name="bt_open"> <property name="geometry"> <rect> <x>570</x> <y>50</y> <width>91</width> <height>41</height> </rect> </property> <property name="text"> <string>连接</string> </property> <property name="type" stdset="0"> <string>primary</string> </property> </widget> <widget class="QLineEdit" name="lineEdit"> <property name="geometry"> <rect> <x>130</x> <y>60</y> <width>211</width> <height>31</height> </rect> </property> <property name="text"> <string>127.0.0.1</string> </property> </widget> <widget class="QLineEdit" name="lineEdit_4"> <property name="geometry"> <rect> <x>350</x> <y>130</y> <width>81</width> <height>31</height> </rect> </property> <property name="text"> <string>1</string> </property> </widget> <widget class="QLabel" name="label_2"> <property name="geometry"> <rect> <x>400</x> <y>70</y> <width>51</width> <height>16</height> </rect> </property> <property name="text"> <string>端口:</string> </property> </widget> <widget class="QLabel" name="label_5"> <property name="geometry"> <rect> <x>280</x> <y>140</y> <width>61</width> <height>16</height> </rect> </property> <property name="text"> <string>读数量:</string> </property> </widget> <widget class="QPushButton" name="bt_close"> <property name="geometry"> <rect> <x>690</x> <y>50</y> <width>91</width> <height>41</height> </rect> </property> <property name="text"> <string>断开</string> </property> <property name="type" stdset="0"> <string>danger</string> </property> </widget> <widget class="QLabel" name="label_3"> <property name="geometry"> <rect> <x>150</x> <y>10</y> <width>561</width> <height>31</height> </rect> </property> <property name="text"> <string>QT(C++)实现MC 1E 二进制协议与三菱PLC通信</string> </property> <property name="type" stdset="0"> <string>h3</string> </property> </widget> <widget class="QLabel" name="label"> <property name="geometry"> <rect> <x>60</x> <y>70</y> <width>61</width> <height>16</height> </rect> </property> <property name="text"> <string>IP地址:</string> </property> </widget> <widget class="QPushButton" name="bt_write"> <property name="geometry"> <rect> <x>620</x> <y>230</y> <width>130</width> <height>40</height> </rect> </property> <property name="text"> <string>写入short</string> </property> <property name="type" stdset="0"> <string>warning</string> </property> </widget> <widget class="QPushButton" name="bt_read"> <property name="geometry"> <rect> <x>120</x> <y>230</y> <width>130</width> <height>40</height> </rect> </property> <property name="text"> <string>short读取</string> </property> </widget> <widget class="QLineEdit" name="lineEdit_3"> <property name="geometry"> <rect> <x>130</x> <y>130</y> <width>121</width> <height>31</height> </rect> </property> <property name="text"> <string>D100</string> </property> </widget> <widget class="QLabel" name="label_6"> <property name="geometry"> <rect> <x>130</x> <y>100</y> <width>751</width> <height>21</height> </rect> </property> <property name="text"> <string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;位地址支持&lt;span style=&quot; color:#008000;&quot;&gt;X、Y、M、F、B&lt;/span&gt;,字地址支持&lt;span style=&quot; color:#008000;&quot;&gt;D、W、R&lt;/span&gt;,位的读取如M10,字的读写如D100&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string> </property> </widget> <widget class="QPushButton" name="bt_readBool"> <property name="geometry"> <rect> <x>120</x> <y>180</y> <width>130</width> <height>40</height> </rect> </property> <property name="text"> <string>bool读取</string> </property> </widget> <widget class="QPushButton" name="bt_readInt"> <property name="geometry"> <rect> <x>120</x> <y>280</y> <width>130</width> <height>40</height> </rect> </property> <property name="text"> <string>int读取</string> </property> </widget> <widget class="QLabel" name="label_10"> <property name="geometry"> <rect> <x>550</x> <y>140</y> <width>61</width> <height>16</height> </rect> </property> <property name="text"> <string>写地址:</string> </property> </widget> <widget class="QLabel" name="label_11"> <property name="geometry"> <rect> <x>750</x> <y>140</y> <width>41</width> <height>16</height> </rect> </property> <property name="text"> <string>写值:</string> </property> </widget> <widget class="QLineEdit" name="lineEdit_5"> <property name="geometry"> <rect> <x>810</x> <y>130</y> <width>81</width> <height>31</height> </rect> </property> <property name="text"> <string>1</string> </property> </widget> <widget class="QLineEdit" name="lineEdit_6"> <property name="geometry"> <rect> <x>610</x> <y>130</y> <width>121</width> <height>31</height> </rect> </property> <property name="text"> <string>D100</string> </property> </widget> <widget class="QPushButton" name="bt_write_2"> <property name="geometry"> <rect> <x>620</x> <y>180</y> <width>130</width> <height>40</height> </rect> </property> <property name="text"> <string>写入bool</string> </property> <property name="type" stdset="0"> <string>warning</string> </property> </widget> <widget class="QPushButton" name="bt_write_3"> <property name="geometry"> <rect> <x>620</x> <y>280</y> <width>130</width> <height>40</height> </rect> </property> <property name="text"> <string>写入Int</string> </property> <property name="type" stdset="0"> <string>warning</string> </property> </widget> <widget class="QPushButton" name="pushButton_35"> <property name="geometry"> <rect> <x>870</x> <y>10</y> <width>121</width> <height>41</height> </rect> </property> <property name="text"> <string>源码下载</string> </property> <property name="type" stdset="0"> <string>primary</string> </property> </widget> </widget> </item> </layout> </item> <item> <widget class="QListWidget" name="listWidget"/> </item> </layout> </item> </layout> </widget> <layoutdefault spacing="6" margin="11"/> <resources/> <connections/> </ui>

三菱FX 系列A 系列PLC 在使用MC 协议(MELSEC Communication Protocol)时,通常采用的是A 兼容 1E 帧(A-1E),而不是 QnA-3E。


✅ 正确对应关系如下:

PLC 系列推荐使用的 MC 协议帧格式说明
FX 系列(如 FX3U、FX5U 等)A-1E 帧(A兼容1E)FX3U 需加装以太网模块(如 FX3U-ENET-ADP),使用 A-1E;FX5U 内置以太网,可支持 QnA-3E,但传统上仍常按 A-1E 处理。
A 系列A-1E 帧A 系列是早期产品,仅支持 A-1E 帧格式。
Q 系列 / L 系列 / iQ-R / iQ-FQnA-3E 帧(或 4E)新一代 PLC,支持更广地址范围和更多数据类型。

🔍 补充说明:

  • A-1E 帧

    • 属于较早期的 MC 协议格式。
    • 仅支持有限地址范围,例如:
      • D 寄存器:D0~D6143、D9000~D9255
      • 不支持扩展寄存器(如 D10000+)
    • 通常使用二进制格式(Binary)通信。
    • 适用于 FX(带以太网模块)、A 系列。
  • QnA-3E 帧

    • 更现代、功能更强。
    • 支持D0~D12287甚至更大范围(依型号而定)。
    • 支持位/字随机读写、浮点数、批量操作等高级功能。
    • FX5U 虽属 FX 系列,但因内置以太网且架构升级,官方文档明确支持 QnA-3E
  • 如果你使用的是FX3U + 以太网模块A 系列 PLC→ 使用MC A-1E 协议
  • 如果你使用的是FX5U、Q 系列等新型 PLC→ 推荐使用MC QnA-3E 协议
版权声明: 本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若内容造成侵权/违法违规/事实不符,请联系邮箱:809451989@qq.com进行投诉反馈,一经查实,立即删除!
网站建设 2026/6/10 10:58:47

云原生热点聚焦:OpenTofu 1.11.0 发布与关键工具更新

OpenTofu 1.11.0 正式发布&#xff1a;强化基础设施代码安全性 OpenTofu 是由 Linux 基金会支持的开源基础设施即代码工具&#xff0c;用于以声明式方式管理云上及本地资源。该项目源于 Terraform 最后一个 MPL 许可版本的分支&#xff0c;致力于保持开源与社区驱动的发展模式…

作者头像 李华
网站建设 2026/6/10 14:50:09

自考ScrumMaster-PSM:经验分享~

很多人问我要不要考个敏捷认证&#xff0c;可以提升个人在企业中的竞争力&#xff0c;作为上个月自考通过PSMI的人&#xff0c;我想聊聊自己的真实经历和想法。 一、我为什么选择了自考PSM&#xff1f; 说实话&#xff0c;朋友圈里晒CSM证书的人不少。但当我深入了解后&#xf…

作者头像 李华
网站建设 2026/6/10 12:51:38

1+1>2”的融合哲学,组合导航如何进行数据融合

“11>2”的融合哲学&#xff0c;是组合导航区别于任何简单传感器拼接的根本所在。它并非简单的GNSS与INS的拼接&#xff0c;而是一种信息层面的、动态的、智能化的数据融合&#xff0c;要达到这种融合&#xff0c;我们就必须要学习一个核心东西—卡尔曼滤波器数据融合的根本…

作者头像 李华
网站建设 2026/6/10 12:48:16

清华GUAVA:一张照片就能搞定3D人

目录 清华GUAVA&#xff1a;一张照片就能搞定3D人&#xff0c;速度1分钟左右&#xff0c;流程比较长 EHM-Tracker 模型&#xff1a;stylematte_synth.pt 清华GUAVA&#xff1a;一张照片就能搞定3D人&#xff0c;速度1分钟左右&#xff0c;流程比较长 论文地址: https://arxi…

作者头像 李华
网站建设 2026/6/9 19:49:32

AR1105六向音源定位模组:让智能设备“耳听八方”

声源定位模组小智机器人当智能设备需要精准捕捉声音方向&#xff0c;当小型化设计与高效能需求碰撞&#xff0c;德宇科创AR1105六向音源定位模组&#xff0c;以革新性技术方案给出完美答案。专注声学&#xff0c;传递美好&#xff0c;我们让每一台智能设备都拥有灵敏的“听觉定…

作者头像 李华