~~NOCACHE~~ ====== lamaPLC Communication: Wiegand ====== {{ :com:wiegand_logo.png?150|Wiegand logo}} The Wiegand interface is a de facto wiring standard which arose from the popularity of Wiegand effect card readers in the 1980s. It is commonly used to connect a card swipe mechanism to the rest of an access control system. The sensor in such a system is often a //"Wiegand wire"//, based on the Wiegand effect, discovered by //John R. Wiegand//. A Wiegand-compatible reader is normally connected to a Wiegand-compatible security panel. ===== Physical layer ===== The Wiegand interface uses three wires, one of which is a common ground and two of which are data transmission wires usually called DATA0 and DATA1, alternatively labeled "**D0**" and "**D1**" or //"Data Low"// and //"Data High"//. When no data is being sent, both DATA0 and DATA1 are pulled up to the //"high"// voltage level - usually +5 VDC. When a 0 is sent the DATA0 wire is pulled to a low voltage while the DATA1 wire stays at a high voltage. When a 1 is sent the DATA1 wire is pulled to a low voltage while DATA0 stays at a high voltage. The high signaling level of 5 VDC is used to accommodate long cable runs from card readers to the associated access control panel, typically located in a secure closet. Most card reader manufacturers publish a **maximum cable run of 150 m**. An advantage of the Wiegand signalling format is that it allows very long cable runs, far longer than other interface standards of its day allowed. ===== Protocol ===== The communications protocol used on a Wiegand interface is known as the Wiegand protocol. The original Wiegand format had one parity bit, 8 bits of facility code, 16 bits of ID code, and a trailing parity bit for a total of 26 bits. The first parity bit is calculated from the first 12 bits of the code and the trailing parity bit from the last 12 bits. However, many inconsistent implementations and extensions to the basic format exist. Many access control system manufacturers adopted Wiegand technology, but were unhappy with the limitations of only 8 bits for site codes (0-255) and 16 bits for card numbers (0-65535), so they designed their own formats with varying complexity of field numbers and lengths and parity checking. The physical size limitations of the card dictated that a maximum of 37 Wiegand wire filaments could be placed in a standard credit card, as dictated by CR80 or ISO/IEC 7810 standards, before misreads would affect reliability. Therefore, most Wiegand formats used in physical access control are less than 37 bits in length. ===== Wiegand 26 ===== The 26-bit Wiegand format is a format for binary encoded data used mainly on access control devices. It’s an extremely common open format, and most access control systems are automatically designed to be able to read 26-bit Wiegand. Because it’s an open format, anybody can buy and use cards in this format, and it is possible for duplicate cards to exist. Although various companies make access control systems, one of the most popular brands is HID. The brand is so popular that people often refer to any access control system as an HID system. However, various brands and manufacturers make 26-bit Wiegand format access cards, not just HID. If you buy or use any basic access system, it’s highly likely that the system runs using the 26-bit Wiegand format. This format is an industry standard known as **H10301**. The term //“bit”// refers to the numbers in the code, so each code consists of 26 numbers. Wiegand refers to the Wiegand protocol, which is the name for the wiring standard. It’s named after //John R. Wiegand//, whose discoveries in the 1970s laid the basis for the standard 26 bit format. The first and last numbers in the 26-bit Wiegand format are beginning and ending bits known as parity bits. They are not part of the unique identification laid out in the code. Bits two through nine make up the facility code. The facility code consists of eight bits. Bits 10 through 25 make up the ID number. The ID number consists of 16 bits. Here is how the code in 26-bit Wiegand appears when P stands for parity bit, F stands for facility code bit, and I stands for ID number bit: \\ \\ **PFFFFFFFFIIIIIIIIIIIIIIIIP**\\ \\ The 26-bit Wiegand format allows for 256 possible facility codes and 65,535 possible ID numbers. When combining both unique identifiers, this allows for 16,711,425 unique access cards. ===== Wiegand interfaces ===== === Wiegand interface (26-bit format) === {{ :com:wiegand_26.png |Wiegand interface (26-bit format)}} === Wiegand interface (32-bit format) === {{ :com:wiegand_32.png |Wiegand interface (32-bit format)}} === Wiegand interface (34-bit format) === {{ :com:wiegand_34.png |Wiegand interface (34-bit format)}} === Wiegand interface (35-bit format) === {{ :com:wiegand_35.png |Wiegand interface (35-bit format)}} === Wiegand interface (37-bit format) === {{ :com:wiegand_37.png |Wiegand interface (37-bit format)}} === Wiegand interface (38-bit format) === {{ :com:wiegand_38.png |Wiegand interface (38-bit format)}} === Wiegand interface (42-bit format) === {{ :com:wiegand_42.png |Wiegand interface (42-bit format)}} ===== Wiegand 26/34 ===== Wiegand 26/34 has become a kind of standard, these two interface types are used most often in practice. === Wiring === The device below is a universal Wiegand 26/34 RFID card reader description. |{{ :com:wiegand_1.png |}}|{{ :com:wiegand_2.png |}}| ===== Sources ===== Wikipedia ([[https://en.wikipedia.org/wiki/Wiegand_interface|here]]) \\ ===== Wiegand topics on lamaPLC ===== {{topic>Wiegand}} \\ \\ {{tag>Wiegand communication interface CR80 IEC_7810 H10301 HID Wiegand_26 Wiegand_32 Wiegand_34 Wiegand_35 Wiegand_37 Wiegand_38 Wiegand_42}} \\ This page has been accessed for: Today: {{counter|today}}, Until now: {{counter|total}}