Wiegand Wire Interface: D0/D1 Pinout, Pull-Up Resistors, and 26/34-Bit Protocol Reference
This is a free printable wiegand wire: download the diagram as SVG or open it and print to paper or PDF.
Wiegand wire describes the serial access-control interface using two active-low data lines, D0 (green) and D1 (white), to transmit card reader data as pulse-width-encoded bits.
The Wiegand interface is the de facto standard for short-range data communication between access control readers — card readers, keypads, biometric readers — and a host controller or access panel. Despite being decades old, it remains ubiquitous in door access systems, car park barriers, and attendance systems worldwide because of its simplicity and the enormous installed base of Wiegand-compatible hardware.
The interface uses three signal conductors: D0 (Data 0, conventionally green wire), D1 (Data 1, conventionally white wire), and a common GND. Power is supplied separately, typically at 12 V DC on red and black wires, making a standard Wiegand cable a 4-core (or 6-core with tamper/LED lines) arrangement.
Data transmission is open-drain and active-low. Both D0 and D1 are held high by pull-up resistors on the reader side, typically 1 kΩ to 4.7 kΩ, connected to the reader supply voltage (usually 5 V). When transmitting a '0' bit, the reader pulls D0 low for approximately 50 microseconds while D1 remains high. When transmitting a '1' bit, the reader pulls D1 low for approximately 50 microseconds while D0 remains high. The inter-bit gap (pulse interval) is typically 1 ms, giving a data rate of roughly 1 kbit/s — far slower than modern serial interfaces, but highly noise-immune over the cable runs typical in building installations (up to approximately 150 metres).
The most common data format is 26-bit Wiegand (H10301), which encodes a 1-bit even parity prefix, an 8-bit facility code, a 16-bit card number, and a 1-bit odd parity suffix. The 34-bit Wiegand format (commonly used in corporate and government applications) uses a 1-bit even parity prefix, a 16-bit facility code, a 16-bit card number, and a 1-bit odd parity suffix.
The host controller (access panel) reads D0 and D1 through optoisolated or high-impedance inputs and decodes the pulse sequence. The panel does not transmit data back to the reader over the Wiegand lines; it is a one-way data path. Any reader-to-panel bi-directional communication (for example, LED or buzzer control from the panel) uses separate, dedicated signal lines — not the D0/D1 pair.
Cable length is limited by capacitance and line resistance. Shielded cable with the shield tied to GND at the panel end (one-point earth) reduces interference pickup in electrically noisy environments such as buildings with variable-frequency motor drives or fluorescent lighting.
How to wire wiegand wire
- Identify reader wires using the SIA DC-100 colour code Locate the reader's wiring pigtail or terminal block. Identify: Red (+12 V DC), Black (GND), Green (D0), White (D1). Additional wires may include Orange (LED from panel), Blue (buzzer from panel), and a shield drain wire. Confirm against the specific reader installation manual before making any connections.
- Run cable from reader to access panel Use shielded multi-conductor cable, minimum 22 AWG per conductor. Route away from high-voltage mains wiring and motor cables. Do not run Wiegand cable parallel to mains runs for extended distances; cross at 90 degrees where crossing is unavoidable. Terminate the cable shield at the panel end to chassis GND only — leave the reader end of the shield floating to avoid ground loops.
- Connect power conductors Connect red to the panel's 12 V DC reader power output and black to GND at the panel terminal block. Verify the power supply is rated for the combined current draw of all readers on that supply. Most readers draw 100–250 mA at 12 V; add tamper and LED loads where applicable.
- Connect D0 and D1 to the panel Connect the green D0 wire to the panel's D0 (Data 0) input terminal and the white D1 wire to the D1 (Data 1) input terminal. These inputs are typically optoisolated on commercial access panels. Confirm terminal polarity in the panel installation manual — polarity matters; reversing D0 and D1 inverts all bits and no card data will decode correctly.
- Verify pull-up configuration Check whether the reader datasheet states internal pull-ups are fitted on D0 and D1. If connecting to a custom microcontroller or a panel with no internal pull-ups, fit 1 kΩ to 4.7 kΩ resistors from D0 to the reader supply and from D1 to the reader supply at the panel end of the cable. Overly large pull-up values (>10 kΩ) slow the pull-up time constant and may cause pulse-width errors at longer cable runs.
- Configure the access panel for the correct bit count In the access panel software or DIP switches, configure the expected Wiegand format (26-bit, 34-bit, or custom). Present a test card to the reader and verify the panel log shows the expected facility code and card number. Compare against the card's printed number if available.
- Test tamper and LED/buzzer control lines If the reader has a tamper circuit, confirm the access panel shows the tamper-closed state when the reader cover is fitted. Test LED feedback by granting and denying access from the panel and confirming the reader LED changes correctly. Test buzzer output if fitted.
Specifications
| D0 / D1 Idle State | Logic HIGH, held by pull-up resistors (typically to +5 V reader supply) |
|---|---|
| Pulse Width (data pulse duration) | Approximately 50 µs (typical; range 20–100 µs depending on reader) |
| Pulse Interval (inter-bit period) | Approximately 1 ms (typical; range 1–2 ms) |
| Recommended Pull-Up Resistance | 1 kΩ to 4.7 kΩ to reader supply voltage |
| Standard Cable Gauge | 22 AWG (0.33 mm²) minimum, shielded multi-conductor |
| Maximum Recommended Cable Length | Approximately 150 m (500 ft) at 22 AWG |
| 26-Bit Format (H10301) | 1 even parity + 8-bit facility code + 16-bit card number + 1 odd parity = 26 bits |
| 34-Bit Format | 1 even parity + 16-bit facility code + 16-bit card number + 1 odd parity = 34 bits |
Safety warnings
- Access control systems directly affect physical security. Any installation, modification, or maintenance of access control wiring must be performed by a qualified and appropriately licensed security installer in accordance with local regulations and standards (such as AS/NZS 2201, EN 50131, UL 294, or equivalent).
- Always isolate the 12 V DC reader power supply and verify it is de-energised before making or disconnecting wiring at either the reader or the panel. Even low-voltage DC systems can cause sparking at terminal blocks, and some access panels share DC rails with alarm loops.
- Do not run Wiegand cabling in the same conduit as mains (AC power) wiring. Mains induction on signal cables can cause spurious access-granted pulses or continuous data errors, undermining the security of the installation.
- The Wiegand protocol has no encryption or authentication. In high-security environments, treat the physical cable path as part of the security perimeter — accessible cable runs in unsecured areas allow simple relay or replay attacks. Consider OSDP over RS-485 with AES-128 encryption for security-critical applications.
Tools needed
- Digital multimeter (DC voltage, continuity, resistance)
- Cable continuity tester or tone generator/probe set
- Wire strippers and crimping tool
- Insulated terminal screwdrivers
- Wiegand protocol analyser or logic analyser (optional, for diagnosing data errors)
- Voltage source (5 V or 12 V bench supply, for bench testing reader outside installation)
Common mistakes
- Reversing D0 (green) and D1 (white) at the panel terminal block — all card bits are inverted and the panel will never decode a valid card number, producing a mysterious 'no read' that appears intermittent if the inverted data happens to match another card format.
- Failing to earth the cable shield, or earthing it at both ends — a floating shield provides no shielding benefit, while earthing at both ends creates a ground loop that introduces hum and false pulses on the data lines. Earth the shield at the panel (controller) end only.
- Using unshielded cable in electrically noisy environments — in a building with fluorescent lighting ballasts or VFD motor drives, unshielded Wiegand cable will pick up interference that manifests as phantom card reads or consistent read failures.
- Exceeding 150 m cable runs without considering voltage drop and capacitance — long runs cause the D0/D1 pull-up rise time to exceed the inter-bit gap, causing bits to merge and card data to be misread. Use a Wiegand repeater/extender for longer runs.
- Configuring the panel for 26-bit Wiegand when the reader outputs 34-bit (or vice versa) — the panel will either reject all cards or decode an incorrect facility code and card number, making the fault appear to be a card enrollment problem rather than a format mismatch.
Troubleshooting
- Reader is powered but panel shows no card reads
- Cause: D0/D1 wires reversed, wrong bit format configured, or open-circuit data cable Fix: Verify D0 (green) and D1 (white) are connected to the correct panel terminals. Confirm panel is configured for the reader's output format (26-bit vs 34-bit). Use a multimeter to verify continuity on D0 and D1 from reader to panel. Use a logic analyser on D0/D1 to confirm pulses are present when a card is presented.
- Intermittent or phantom card reads with no card presented
- Cause: Interference on D0 or D1 lines, typically from adjacent mains or motor wiring; or insufficient pull-up voltage Fix: Check cable routing for proximity to mains wiring. Verify cable shield is grounded at panel end only. Measure D0 and D1 idle voltage — should be at pull-up voltage (5 V or reader supply). If idle voltage is low or noisy, add external pull-up resistors closer to the panel input. Replace unshielded cable with shielded type.
- Reader reads only some cards correctly; others fail or produce wrong numbers
- Cause: Bit count mismatch (e.g., reader outputs 34-bit but panel expects 26-bit) or parity errors from pulse timing issues Fix: Confirm reader output format from its datasheet and match panel configuration. Use a Wiegand protocol analyser to capture the raw bit stream and count bits. Check D0/D1 pulse width — should be approximately 50 µs; if pulses are shorter or wider, investigate cable capacitance, pull-up resistor values, or reader supply voltage.
Frequently asked questions
What are the standard wire colours for Wiegand interfaces?
The SIA (Security Industry Association) DC-100 standard defines the conventional colour code: Red = +12 V DC power, Black = GND, Green = D0 (Data 0), White = D1 (Data 1). Additional conductors are Orange (LED control from panel), Blue (buzzer control from panel), and Yellow/Brown for tamper. Always verify against the specific reader datasheet as some manufacturers deviate.
What is the difference between 26-bit and 34-bit Wiegand?
26-bit Wiegand (H10301) carries an 8-bit facility code (0–255) and 16-bit card number (0–65535), bounded by parity bits, for 16.7 million unique combinations. 34-bit Wiegand expands the facility code to 16 bits, yielding over 4.2 billion unique card-facility combinations. The electrical interface is identical; the host controller is configured to accept the appropriate bit count.
Why do pull-up resistors matter on Wiegand D0 and D1 lines?
Wiegand lines use open-drain (open-collector) signalling. Without pull-up resistors the idle line is floating, which causes random noise to be misread as data pulses. Pull-up resistors, typically 1 kΩ to 4.7 kΩ to the reader supply voltage, hold the lines firmly high at idle. Most commercial readers have these resistors built in; external pull-ups are needed only when interfacing Wiegand readers to microcontrollers or custom panels without on-board termination.
How far can a Wiegand cable run, and does shielding matter?
The practical maximum cable run for Wiegand is approximately 150 metres (500 feet) using 22 AWG shielded cable, limited by line capacitance and resistive voltage drop. Beyond this, pulse shapes degrade and the panel may miss bits. Shielded cable with a single-point earth at the panel significantly reduces interference in environments with motor drives, switching power supplies, or fluorescent ballasts.
Is Wiegand a secure interface, and what are its known vulnerabilities?
Wiegand is not a secure interface by modern standards. Data is transmitted in clear text with only parity checking — there is no encryption or mutual authentication. An attacker can trivially capture and replay Wiegand data with simple electronics. Organisations with high-security requirements should use OSDP (Open Supervised Device Protocol), which provides AES-128 encryption, mutual authentication, and tamper detection over RS-485.
Related diagrams
- 1 wire alternator wiring diagram
- 1 wire oil pressure switch wiring diagram
- 12 wire motor wiring diagram
- 2 wire 220 volt wiring diagram
- 2 wire 240 volt wiring diagram
- 2 wire alternator wiring diagram