# GPIB

GPIB（General Purpose Interface Bus，通用接口总线），又称 IEEE 488，在[惠普](https://www.edgepedia.org/zh/hewlett-packard)（Hewlett-Packard）最初的命名中则称为 HP-IB，是一种数字式 8 位并行通信接口，用于将可编程仪器、计算机、打印机和绘图仪连接成自动化测试与测量系统。<sup>[1](https://www.ni.com/en/support/downloads/instrument-drivers/how-to-choose-the-right-hardware-bus-for-your-instrument-control.html)</sup><sup> • </sup><sup>[2](https://dl.cdn-anritsu.com/en-us/test-measurement/ohs/10450-00008L/Programming_Commands/PM_Ch1_GeneralInfo.02.3.html)</sup> 它由惠普于 20 世纪 60 至 70 年代创造，1975 年标准化为 IEEE 488，至今仍是独立仪器上最常见的 I/O 接口之一。<sup>[3](https://hpmemoryproject.org/wb_pages/wall_b_page_08.htm)</sup><sup> • </sup><sup>[1](https://www.ni.com/en/support/downloads/instrument-drivers/how-to-choose-the-right-hardware-bus-for-your-instrument-control.html)</sup>

| 关键事实 | 详情 |
|---|---|
| 接口类型 | 数字式 8 位并行总线；数据通过 16 条信号线一次传输一个字节<sup>[1](https://www.ni.com/en/support/downloads/instrument-drivers/how-to-choose-the-right-hardware-bus-for-your-instrument-control.html)</sup><sup> • </sup><sup>[2](https://dl.cdn-anritsu.com/en-us/test-measurement/ohs/10450-00008L/Programming_Commands/PM_Ch1_GeneralInfo.02.3.html)</sup> |
| 数据速率 | IEEE 488.1 下为 1.8 MB/s；采用 HS488 高速协议可达 8 MB/s<sup>[1](https://www.ni.com/en/support/downloads/instrument-drivers/how-to-choose-the-right-hardware-bus-for-your-instrument-control.html)</sup> |
| 设备数量限制 | 每条连续总线上最多 15 台设备（一个控者加最多 14 台仪器）<sup>[4](https://standards.ieee.org/ieee/488.1/716/)</sup><sup> • </sup><sup>[1](https://www.ni.com/en/support/downloads/instrument-drivers/how-to-choose-the-right-hardware-bus-for-your-instrument-control.html)</sup> |
| 电缆限制 | 传输路径总长 20 米，或相邻设备间 4 米、总线上平均 2 米<sup>[4](https://standards.ieee.org/ieee/488.1/716/)</sup><sup> • </sup><sup>[5](https://helpfiles.keysight.com/csg/e5080a/programming/learning_about_gpib/gp-ib_fundamentals.htm)</sup> |
| 握手方式 | 在 DAV、NRFD 和 NDAC 线上进行异步三线互锁握手<sup>[2](https://dl.cdn-anritsu.com/en-us/test-measurement/ohs/10450-00008L/Programming_Commands/PM_Ch1_GeneralInfo.02.3.html)</sup> |
| 起源 | 由惠普开发（HP-IB，1972 年 10 月首次描述）；1975 年被采纳为 IEEE 488<sup>[3](https://hpmemoryproject.org/wb_pages/wall_b_page_08.htm)</sup> |
| 延迟 | 30 微秒，用于仪器控制时低于 USB 和以太网<sup>[1](https://www.ni.com/en/support/downloads/instrument-drivers/how-to-choose-the-right-hardware-bus-for-your-instrument-control.html)</sup> |

## 历史

1965 年，惠普着手制定一项内部标准，用以连接公司未来所有的仪器和计算机，使独立设计的产品能够接入共同的系统。<sup>[6](https://hparchive.com/Catalogs/HP-Catalog-1985.pdf)</sup> 惠普的企业接口工程师唐·劳里（Don Loughry）将目标描述为：让不同地点、不同时间的不同工程师按照共同接口设计产品，然后将其组合成一个系统。<sup>[7](https://hp9845.net/9845_backup/tutorials/hpib/index.html)</sup> 惠普以极低的许可费向其他制造商提供 HP-IB 规范，许多公司采用了它。<sup>[8](https://ascii.jp/elem/000/004/188/4188527/2/)</sup>

HP 接口总线最早在 1972 年 10 月的《惠普杂志》（*Hewlett-Packard Journal*）上描述，惠普同时开始参与标准化组织。两年后，该设计经完善成为一项国际标准的模型，并于 1975 年 4 月被正式采纳为 IEEE 488。<sup>[3](https://hpmemoryproject.org/wb_pages/wall_b_page_08.htm)</sup><sup> • </sup><sup>[8](https://ascii.jp/elem/000/004/188/4188527/2/)</sup> 到 20 世纪 70 年代末，已有 200 多台惠普仪器兼容 HP-IB，该标准也逐渐以 GPIB 之名广为人知。<sup>[3](https://hpmemoryproject.org/wb_pages/wall_b_page_08.htm)</sup><sup> • </sup><sup>[9](https://www.hpmemoryproject.org/an/pdf/Hpnar101107.pdf)</sup> 惠普 1985 年的一份产品目录报告称，该标准已被 14 个国家的 170 多家制造商采用。<sup>[6](https://hparchive.com/Catalogs/HP-Catalog-1985.pdf)</sup>

## 总线结构与操作

GPIB 使用 16 条信号线，分为三组：8 线数据总线（DIO1 至 DIO8）、3 线数据字节传输控制总线和 5 线通用接口管理总线。<sup>[2](https://dl.cdn-anritsu.com/en-us/test-measurement/ohs/10450-00008L/Programming_Commands/PM_Ch1_GeneralInfo.02.3.html)</sup> 数据以字节串行、位并行方式传输，通常格式为七位 ASCII，第八位不使用。<sup>[2](https://dl.cdn-anritsu.com/en-us/test-measurement/ohs/10450-00008L/Programming_Commands/PM_Ch1_GeneralInfo.02.3.html)</sup>

**讲者、听者与控者。** 总线上的设备承担指定角色。讲者发送数据，听者接收数据，控者通过分配这些角色来管理总线。同一时刻只能有一台设备讲，但可以有任意数量的设备同时听。<sup>[10](https://www.ni.com/en/support/documentation/supplemental/06/gpib-messages.html)</sup> 一条总线有一个系统控者，它保留最终控制权，并可将当前控制权转交给另一台设备；系统控者始终掌控接口清除（IFC）和远程使能（REN）线，并可随时收回总线。<sup>[2](https://dl.cdn-anritsu.com/en-us/test-measurement/ohs/10450-00008L/Programming_Commands/PM_Ch1_GeneralInfo.02.3.html)</sup> 地址能力为 31 个主讲地址和 31 个主听地址，另有 961 个讲副地址和 961 个听副地址；任一时刻一条总线上有一个讲者和最多 14 个听者。<sup>[5](https://helpfiles.keysight.com/csg/e5080a/programming/learning_about_gpib/gp-ib_fundamentals.htm)</sup>

**三线握手。** 每次字节传输由三条线协调：DAV（数据有效），由讲者控制；NRFD（未准备好接收数据）和 NDAC（未接受数据），为所有活动听者共享的线或（wired-OR）线。讲者仅在所有听者都准备好时才将字节放到总线上，并保持到每个听者都已接受为止。这种互锁握手迫使传输以最慢听者的速度进行，从而保证多听者传输中的数据完整性。<sup>[2](https://dl.cdn-anritsu.com/en-us/test-measurement/ohs/10450-00008L/Programming_Commands/PM_Ch1_GeneralInfo.02.3.html)</sup><sup> • </sup><sup>[11](https://www.eit.edu.au/resources/data-communications-networking-and-protocols-for-industry/)</sup>

**命令与数据。** 注意（ATN）管理线区分两类通信。当 ATN 有效时，数据线上的字节是每台设备都会听到的命令消息，例如讲者和听者的分配；当 ATN 无效时，只有被寻址为听的设备才接收数据字节。<sup>[10](https://www.ni.com/en/support/documentation/supplemental/06/gpib-messages.html)</sup> 其余管理线为 IFC（接口清除）、SRQ（服务请求，由任何请求服务的设备置位）、REN（远程使能）和 EOI（结束或识别，标记一次传输的最后一个字节）。<sup>[2](https://dl.cdn-anritsu.com/en-us/test-measurement/ohs/10450-00008L/Programming_Commands/PM_Ch1_GeneralInfo.02.3.html)</sup>

## 物理限制与扩展

由于 GPIB 是传输线系统，IEEE 488 规范同时限制电缆长度和设备数量，以免接口电路过载。限制为：相邻设备间最大 4 米、总线上平均 2 米，电缆总长 20 米，每条总线 15 台设备，且至少三分之二的设备通电。<sup>[12](https://knowledge.ni.com/KnowledgeArticleDetails?id=kA00Z000000P8slSAC&l=en-US)</sup> 更长的电缆仍可通信，但无法达到全速传输速率，也不符合规范。<sup>[12](https://knowledge.ni.com/KnowledgeArticleDetails?id=kA00Z000000P8slSAC&l=en-US)</sup>

必须超出这些限制的系统使用总线延长器和扩展器。每套 NI GPIB-130 延长系统可将距离限制扩展 300 米，并将负载限制提高到 30 台设备（含延长器），而不牺牲速度。<sup>[13](https://manualzilla.com/doc/5974316/gpib-130-user-manual---national-instruments)</sup>

## 性能与更高速变体

在 IEEE 488.1 下，总线速率约为 1.8 MB/s；[国家仪器](https://www.edgepedia.org/zh/national-instruments)（National Instruments）的 HS488 高速协议通过在较短电缆上放宽握手将速率提高到 8 MB/s。HS488 仅在电缆总长 1 至 15 米时工作，通过一个两字节命令序列配置，告知兼容设备以米为单位的电缆长度。<sup>[1](https://www.ni.com/en/support/downloads/instrument-drivers/how-to-choose-the-right-hardware-bus-for-your-instrument-control.html)</sup><sup> • </sup><sup>[14](https://documentation.help/NI-488.2/gpib0tpv.html)</sup> GPIB 延迟约为 30 微秒，明显低于 USB（125 至 1,000 微秒）或以太网（1,000 微秒），这正是该总线在仪器间短命令序列中仍受青睐的原因。<sup>[1](https://www.ni.com/en/support/downloads/instrument-drivers/how-to-choose-the-right-hardware-bus-for-your-instrument-control.html)</sup>

物理连接器是该设计的一大优势：电缆可锁紧固定，且经过加固和屏蔽，使 GPIB 和 USB 成为电气噪声较大的制造车间环境的推荐选择。<sup>[1](https://www.ni.com/en/support/downloads/instrument-drivers/how-to-choose-the-right-hardware-bus-for-your-instrument-control.html)</sup> GPIB 很少原生集成在 PC 中；用户通过 PCI-GPIB 等插卡或 GPIB-USB 适配器等外部转换器来添加。<sup>[1](https://www.ni.com/en/support/downloads/instrument-drivers/how-to-choose-the-right-hardware-bus-for-your-instrument-control.html)</sup>

## 软件层

后来的两项标准建立在 488.1 硬件之上。IEEE 488.2（1987 年，1992 年修订）定义了在 488.1 总线上使用的代码、格式、协议和通用命令，包括标准状态报告和系统配置协议。<sup>[15](https://standards.ieee.org/ieee/488.2/718/)</sup> SCPI（Standard Commands for Programmable Instruments，可编程仪器标准命令）于 1990 年推出，层叠在 IEEE 488.2 之上，提供可跨同类仪器工作的设备专用命令语法。<sup>[5](https://helpfiles.keysight.com/csg/e5080a/programming/learning_about_gpib/gp-ib_fundamentals.htm)</sup> 相同的 SCPI 命令内容后来以相同的数据帧格式迁移到 USB 和以太网传输上。<sup>[16](https://prodcs.lwn.net/Articles/1000800/)</sup>

## 现状

几十年来，GPIB 一直是将测试仪器连接到 PC 的标准接口，但自 20 世纪 90 年代以来未再有重大改进，而 USB 和 LAN 接口则持续进步。<sup>[17](https://www.keysight.com/zz/en/assets/7018-05025/application-notes/5992-1205.pdf)</sup> 尽管如此，它仍被广泛使用：NI 统计到超过 10,000 种具有 GPIB 连接的仪器型号，该总线仍是自动化现有设备以及需要专用独立仪器的系统的常见选择。<sup>[18](https://www.ni.com/en/support/downloads/instrument-drivers/instrument-bus-performance---making-sense-of-competing-bus-techn.html)</sup>

现代平台上的支持仍在继续。Linux GPIB 软件包是一个 GPL 许可的支持包，包含内核驱动模块和与国家仪器 API 兼容的 C 库，自 2000 年代初以来一直得到维护。<sup>[19](https://linux-gpib.sourceforge.io/)</sup> GPIB 驱动以暂存形式进入 Linux 主线内核，并在 Linux 6.19 内核中被宣布为稳定并移出暂存区，此时距惠普推出该总线已过去 53 年。<sup>[20](https://www.techradar.com/pro/security/better-late-than-never-53-year-old-hp-bus-standard-finally-gets-a-linux-driver-boasting-8mb-s-bandwidth)</sup> [开源硬件](https://www.edgepedia.org/zh/open-source-hardware)也服务于现有设备群：XyphroLabs UsbGpib 适配器通过 USB 将传统 GPIB 仪器连接到现代计算机，版本 3 还增加了集成以太网端口并支持[以太网供电](https://www.edgepedia.org/zh/power-over-ethernet)。<sup>[21](https://www.tomshardware.com/peripherals/open-source-usb-to-gpib-adapter-v3-adds-integrated-ethernet-port-with-poe-support-new-version-of-legacy-gpib-and-ieee-488-support-hardware-expected-in-january)</sup>

## References

1. [How to Choose the Right Hardware Bus for Your Instrument Control System, NI](https://www.ni.com/en/support/downloads/instrument-drivers/how-to-choose-the-right-hardware-bus-for-your-instrument-control.html)
2. [IEEE 488 GPIB Description, Anritsu](https://dl.cdn-anritsu.com/en-us/test-measurement/ohs/10450-00008L/Programming_Commands/PM_Ch1_GeneralInfo.02.3.html)
3. [History and Facts: The Seventies, HP Memory Project](https://hpmemoryproject.org/wb_pages/wall_b_page_08.htm)
4. [IEEE 488.1-2003, IEEE Standards Association](https://standards.ieee.org/ieee/488.1/716/)
5. [GP-IB Fundamentals, Keysight](https://helpfiles.keysight.com/csg/e5080a/programming/learning_about_gpib/gp-ib_fundamentals.htm)
6. [HP Catalog 1985, HP Archive](https://hparchive.com/Catalogs/HP-Catalog-1985.pdf)
7. [The Hewlett-Packard Interface Bus (HP-IB), hp9845.net](https://hp9845.net/9845_backup/tutorials/hpib/index.html)
8. [消え去ったI/F史：GPIB, ASCII.jp](https://ascii.jp/elem/000/004/188/4188527/2/)
9. [A Narrative History of Hewlett-Packard, HP Memory Project](https://www.hpmemoryproject.org/an/pdf/Hpnar101107.pdf)
10. [GPIB Messages, NI](https://www.ni.com/en/support/documentation/supplemental/06/gpib-messages.html)
11. [Data Communications, Networking and Protocols for Industry, Engineering Institute of Technology](https://www.eit.edu.au/resources/data-communications-networking-and-protocols-for-industry/)
12. [NI GPIB Cabling Requirements and Limitations, NI](https://knowledge.ni.com/KnowledgeArticleDetails?id=kA00Z000000P8slSAC&l=en-US)
13. [GPIB-130 User Manual, National Instruments](https://manualzilla.com/doc/5974316/gpib-130-user-manual---national-instruments)
14. [Enabling HS488 Transfers, NI-488.2 Documentation](https://documentation.help/NI-488.2/gpib0tpv.html)
15. [IEEE 488.2-1992, IEEE Standards Association](https://standards.ieee.org/ieee/488.2/718/)
16. [GPIB still in use, LWN.net](https://prodcs.lwn.net/Articles/1000800/)
17. [USB and LAN Interfaces for Connecting Measurement Instruments, Keysight](https://www.keysight.com/zz/en/assets/7018-05025/application-notes/5992-1205.pdf)
18. [Instrument Bus Performance: Making Sense of Competing Bus Technologies, NI](https://www.ni.com/en/support/downloads/instrument-drivers/instrument-bus-performance---making-sense-of-competing-bus-techn.html)
19. [Linux GPIB Package Homepage](https://linux-gpib.sourceforge.io/)
20. [53-year-old HP bus standard finally gets a Linux driver, TechRadar](https://www.techradar.com/pro/security/better-late-than-never-53-year-old-hp-bus-standard-finally-gets-a-linux-driver-boasting-8mb-s-bandwidth)
21. [Open source project brings 53-year-old interface to USB, Tom's Hardware](https://www.tomshardware.com/peripherals/open-source-usb-to-gpib-adapter-v3-adds-integrated-ethernet-port-with-poe-support-new-version-of-legacy-gpib-and-ieee-488-support-hardware-expected-in-january)

---
*Initially written Oct 15, 2026 · Edited: Oct 25, 2026*

Topic: 技术与人造世界 › 计算技术与数字系统 › 计算机硬件 › Boards, peripherals & form factors › Peripherals & expansion hardware › External peripheral connectivity and adapters

Copyright 2026 Edgepedia

License: Edgepedia Community License 1.0, https://www.edgepedia.org/edgepedia/license

Source: https://www.edgepedia.org/zh/gpib

English original: https://www.edgepedia.org/gpib
