Google

Monday, March 10, 2008

1- Wire Technology

The 1-Wire net is a low-cost bus based on a PC or microcontroller communicating digitally over twisted-pair cable with 1-Wire components. The network is defined with an open-drain (wired-AND) master/slave multidrop architecture that uses a resistor pull-up to a nominal 5V supply at the master. A 1-Wire net-based system consists of three main elements:
1) a bus master with controlling software such as the TMEX iButton® viewer;

2) wiring and associated connectors; and

3) 1-Wire devices.

The system permits tight control because no node is authorized to speak unless requested by the master, and no communication is allowed between slaves except through the master.

The 1-Wire protocol uses conventional CMOS/TTL logic levels with operation specified over a supply voltage range of 2.8V to 6V. Both master and slaves are configured as transceivers permitting bit sequential data to flow in either direction, but only one direction at a time, with data read and written least significant bit (LSB) first. An economical DS9097U COM port adapter interfaces the RS-232 to the net. A DS2480 serial 1-Wire line driver chip is also available to generate the proper signals and programmable waveforms that maximize performance.
Data on the 1-Wire net is transferred by time slots. For example, to write a logic one to a slave, the master pullsthe bus low for 15µs or less. To write a logic zero, the master pulls the bus low for at least 60µs to providetiming margin for worst-case conditions. A system clock is not required, as each 1-Wire part is self-clocked by its own internal oscillator synchronized to the falling edge of the master. Power for chip operation is derived fromthe bus during idle communication periods when the DATA line is at 5V by including a half-wave rectifier on each
slave.
Whenever the data line is pulled high, the diode in the half-wave rectifier turns on and charges an on-chipcapacitor. When the voltage on the net drops below the voltage on the capacitor, the diode is reverse biased,which isolates the charge. The resulting charge provides the energy source to power the slave during theintervals when the net is pulled low. The amount of charge lost during these periods is replenished when thedata line returns high. This concept of "stealing" power from the net using a half-wave rectifier is referred to as "parasite power"."
When communicating, the master resets the network by holding the bus low for at least 480µs, releasing it, andthen looking for a responding presence pulse from a slave connected to the line. If a presence pulse is detected,it then accesses the slave by calling its address, controlling the information transfer by generating time slots and examining the response from the slave. Once this handshake is successful, the master issues necessary device-specific commands and performs any needed data transfers between it and the slave. The master can select a single slave from many on the net because of its unique digital address.

A Unique Address for Every Part?

Within each 1-Wire slave is stored a lasered ROM section with its own guaranteed unique, 64-bit serial number that acts as its node address. This globally unique address is composed of eight bytes divided into three mainsections. Starting with the LSB, the first byte stores the 8-bit family codes that identify the device type. The next six bytes store a customizable 48-bit individual address. The last byte, the most significant byte (MSB), contains a cyclic redundancy check (CRC) with a value based on the data contained in the first seven bytes. This allows 48 the master to determine if an address was read without error. With a 2 serial number pool, conflicting or duplicate node addresses on the net are never a problem.Because 1-Wire devices can be formatted with a file directory like a floppy disk, files can be randomly accessed and changed without disturbing other records. Information is read or written when the master addresses a device connected to the bus, or an iButton is touched to a probe somewhere along the 1-Wire net. The inclusion of up to 64k of memory in 1-Wire chips allows standard information such as employee name, ID number, and security level to be stored within the device. Maximum data security can be provided by 1-Wire chipimplementation of the US government-certified Secure Hash Algorithm (SHA-1).Historically, the 1-Wire net was envisioned as a single twisted pair routed throughout the area of interest with 1-Wire slaves daisy-chained where needed. However, if the network is heavily loaded, it may be preferable or even necessary to separate the bus into sections. This has the added benefit of providing information about the physical location of a 1-Wire device on the bus, which facilitates troubleshooting. By using one section as the main "trunk" and adding or removing segment "branches" with a DS2409 as needed, a true 1-Wire net is created. This also reduces the load seen by the bus master to that of the trunk and those segments connected to it by activated DS2409s.

Consequently, the DS2409 MicroLAN coupler is a key component for creating complex 1-Wire nets. It contains MAIN and AUX transmission-gate outputs and an open-drain output transistor (CONT), each of which can be remotely controlled by the bus master. A simple 1-Wire branch with DS2430 EEPROM connected to label the node provides tagging information specific to that particular node such as location and function. The LEDattached to the CONT output provides visual indication of the specific branch being addressed and can be blinked by software for extra visual impact.1-Wire technology made possible the combination of electronic communication and instrumentation based on positive identification of individual nodes on a single self-powered net. Continued development of the technology has increased the array of 1-Wire chips able to interface with the environment, measuring events, voltage,current, temperature, position, etc. In turn, these chips enabled the construction of sensors that measure a host of environmental parameters on a single twisted-pair cable as described within this article.

Including ROM, EPROM, and EEPROM in 1-Wire slaves in a stainless-steel case called an iButton further enabled a personal electronic authentication. Personal and data security advanced with the creation of SHA-1-based 1-Wire chips in iButtons for use with monetary transactions. Whether housed in an armored stainless-steel iButton or standard IC packages, 1-Wire communication uses a noncritical two-contact interface. 1-Wire technology is now used for transportation tokens, identification badges, entry security, and after-market control. New applications are continually being added.

For More Info

No comments: