Abstract:
A process and a circuit are described for detecting collisions between packets being transmitted over a network and signaling the detection of collisions. Peak-detection is used to facilitate the detection of collisions. Embodiments of the process and circuit may also include the detection and signaling of packet transmissions by a transceiver coupled to the network. In a preferred embodiment, the detection of collisions and transmissions are signaled by the lighting of a corresponding light-emitting diode for at least a minimum duration.

Description:
FIELD OF THE INVENTION 
     The present invention relates to a circuit for detecting collisions on a local area network and signalling the detection of collision. 
     BACKGROUND OF THE INVENTION 
     Packet switching is often used to allow multiple computing devices to communicate over a local area network. Using packet switching, a computing device is at all times connected to the network but transmits data in the form of individual packets. In Ethernet systems with data rates of 10 Megabits/second, for example, packets contain approximately 6,000 bits and are approximately 60 microseconds in duration. 
     Because packets may be transmitted by any computing device on the network, collisions may occur when two devices transmit packets simultaneously. To insure the reliable transmission of data over the network, collisions must be detected so that remedial action, such as retransmission of the colliding packets, may be taken. 
     One technique for detecting collisions is a listen-while-talk protocol. This system allows a device to begin transmitting a packet if no other transmission is detected on the network. Once the transmission of the packet begins, the transmitting device monitors the network for errors in its own transmission. If a collision occurs, the transmitting device detects an error in its transmission and aborts its transmission. Some such systems, as described in U.S. Pat. No. 4,210,780, impose a random delay on the devices prior to retransmission to avoid continual collisions between multiple devices. 
     Other methods for detecting collisions on local area networks employ the transmission of collision-detecting packets with each transmission of data. U.S. Pat. No. 4,584,678 describes such a method in which the collision-detecting packets have a predetermined duration and pulse pattern and precede the data packets by a fixed time period. The transmitting station detects collisions by comparing the pattern of pulses which form the collision-detecting packet during transmission with the pattern of pulses actually received. 
     Another technique for detecting collisions on a packet switching network uses a high-amplitude pulse embedded in the preamble of the packet. In the absence of collisions, the minimum separation between successive high-amplitude pulses is the duration of a packet plus the delay between successive packets. A collision is detected when two high-amplitude pulses violate this minimum separation. Collisions resulting in coincident high-amplitude pulses, however, are not detected by this method. As described in U.S. Pat. No. 4,888,763, such collisions are detected by a secondary examination of the contents of the preamble, which contains a specified code. If the preamble does not contain the specified code upon receipt, a collision is detected. 
     Accordingly, the above described techniques for detecting collisions require the device to read data from the network in digital format and compare the digital data to an expected value. Some such techniques also require the transmission of specialized collision detection data, or additional circuitry to create and detect specialized collision detection signals. 
     Therefore, it is desirable to have an inexpensive device that can detect collisions on a local area network without requiring the transmission of a dedicated signal or code. It is further desirable that this device be capable of detecting collisions based solely on the signal observed on the network, without the requirement of digitally comparing data on the network with expected data. Finally, it is desirable that this inexpensive collision detection device include a light emitting diode to signal the detection of collisions. 
     SUMMARY OF THE INVENTION 
     A broad aspect of the invention relates to a circuit for detecting collisions between packets being transmitted over a network and signaling the detection of collisions. In a narrower sense, the invention relates to the use of a comparator and a peak detecting circuit to detect packet collisions. 
     A further aspect of the invention relates to a circuit for detecting the transmission of packets on a network by a transceiver and signaling the detection of the transmission. 
     In a preferred embodiment, a light-emitting diode is lit, for at least a minimum duration, in response to the detection of packet collisions. A second light-emitting diode is lit, also for at least a minimum duration, in response to the detection of a packet transmission by a transceiver. 
     A further aspect of the invention relates to a process for detecting collisions between packets being transmitted over a network and signaling the detection of collisions. Another aspect of the invention relates to a process for detecting the transmission of packets on a network by a transceiver and signaling the detection of the transmission. 
     These and other features and advantages of the present invention will become apparent from a reading of the detailed description in conjunction with the attached drawings. 
    
    
     BRIEF DESCRIPTION OF THE DRAWINGS 
     FIG. 1 is a block diagram showing the collision and transmit detectors in the context of a network environment. 
     FIG. 2A is an isometric diagram of the front of an enclosure with a transceiver and a circuit according to the principles of the invention. 
     FIG. 2B is an isometric diagram of the rear of the enclosure of FIG. 2A. 
     FIG. 3 is a schematic diagram of a circuit according to the principles of the invention. 
     FIG. 4 is a timing diagram of selected waveforms related to the detection and signaling of collisions from the circuit of FIG. 3. 
     FIG. 5 is a timing diagram of selected waveforms related to the detection and signaling of transmissions from the circuit of FIG. 3. 
    
    
     DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENT 
     The disclosed invention detects collisions on a network resulting from overlapping transmissions by multiple nodes on a network, and activates a signaling device to signal the detection of collisions. The basic environment within which the invention operates is illustrated in the block diagram of FIG. 1. 
     FIG. 1 shows a network 2 which carries electrically encoded messages, also known as packets, among nodes 4 which are tied to the network 2. In a preferred embodiment, the network 2 is a local area network, such as ETHERNET, and physically comprises a coaxial wire. The center conductor of the coaxial wire, which carries the network signals, is referred to as the medium, and is shown in FIG. 3 as element 6. The node 4, which is typically a digital computer, may send or receive packets to or from other nodes on the network 2. 
     As shown in FIG. 1, the node 4, instead of being connected directly to the network 2, is coupled to the network 2 through a transceiver 8. The transceiver 8 translates the electrical waveforms carried by the medium 6 into signals which are more suitable for interpretation by the node 4. For example, in the embodiment shown in Figure 1, the signals carried between the node 4 and the transceiver 8 are square waves which alternate between +1.0 volt and -1.0 volt. The transceiver 8 also translates packets being sent from the node 4, which are encoded in a +/-1.0 volt square wave signal, into the corresponding electrical waveforms carried by the medium 6. 
     As shown in FIG. 1, a detector group 10 works in conjunction with the transceiver 8 to detect and signal the status of the network 2 and the transceiver 8. The collision detector 12 monitors the medium 6 and activates a light-emitting diode 14 when two or more packets collide on the network 2. The mechanism for detecting and signaling such collisions is described in more detail in conjunction with FIGS. 3 and 4. In place of, or in addition to, the light-emitting diode, the collision detector 12 may signal a collision with other visible or audible means, such as with a liquid crystal display or a speaker. Similarly, the collision detector 12 may be coupled to a data storage device (not shown) to record the collision history of the network 2. 
     As shown in FIG. 1, the detector group 10 also includes a transmit detector 16, a receive detector 18, and a status detector 20. The transmit detector 16 monitors the transceiver 8 and activates a light-emitting diode 14 when the transceiver 8 transmits a packet. The receive detector 18 activates a light-emitting diode 14 when the transceiver 8 detects a packet on the network 2, and the status detector 20 activates a light-emitting diode 14 when power is supplied to the transceiver 8. In place of, or in addition to, the light-emitting diode, the transmit, receive, and status detectors 14, 18, and 20 may signal their respective detections by other visible, audible, or data storage means, similar to those described for the collision detector 12. 
     FIGS. 2A and 2B show a transceiver/detector assembly 30 according to the invention. Housed within the transceiver/detector assembly 30 is the transceiver 8, the detector group 10, and the light-emitting diodes 14 of FIG. 1. Also part of the transceiver/detector assembly 30 are ports 32 and 34 for connection to the network node 4 and to the network 2 respectively. The embodiment shown in FIGS. 2A and 2B may be plugged directly into a connector (not shown) on the network node 4, without the need for a connecting cable. As shown in FIG. 2A, the light emitting diodes 14 extend to the outer portion of the transceiver/detector assembly 30 such that they may be viewed by the user of the network node 4. 
     Alternatively, the transceiver 8 and detector block 10 may be housed in separate enclosures (not shown.) The detector block 10 may also be housed within the enclosure containing the network node 4. In such a configuration, the light-emitting diodes 14, or other signaling means, may be made visible or otherwise accessible through apertures in the network node enclosure (not shown,) as appropriate. 
     FIG. 3 shows a circuit embodying the collision detector 12 and the transmit detector 16. As shown, the circuit of FIG. 3 includes a transceiver 8 which is based on a DP8392 integrated circuit 40 manufactured by National Semiconductor. An input port 7 of the transceiver 8 is connected to the medium 6, allowing the transceiver 8 to receive packets transmitted on the medium 6. An output port 9 of the transceiver 8 is connected to the medium 6 through a rectifier diode 42, the cathode terminal of the diode 42 being connected to the transceiver 8. The transceiver 8 normally holds the voltage potential of the cathode terminal of the diode 42 at ground. The diode 42 insulates the medium 6, which carries negative-going signals, from the transceiver 8. During a transmission, however, the transceiver 8 selectively asserts negative voltages at the cathode terminal of the diode 42, thus transmitting a packet on the medium 6. 
     The collision detector 12 includes two comparators 44 and 46, each of which are supplied by voltages of ground and -9 volts. The positive input port of the first of the two collision comparators 44 is connected, through a resistor 48, to the anode terminal of a rectifier diode 50. The cathode terminal of the diode 50 is connected to the medium 6. The negative input port of the first collision comparator 44 is connected between voltage divider resistors 52 and 54. The voltage potential produced by the voltage divider is labeled as V ref1 . The output port of the first collision comparator 44 is connected to the positive input port of the second collision comparator 46. The output of the first collision comparator 44 is modified by a pulse stretcher, formed by resistor 56 and capacitor 58. The negative input port of the second collision comparator 46 is supplied by a reference voltage, which in FIG. 3 is also generated by the voltage divider resistors 52 and 54. The output port of the second collision comparator 46 is then connected to the cathode terminal of the collision detection light-emitting diode 14, whose anode terminal is connected to ground through a resistor 59. 
     The transmit detector 16, like the collision detector 12, includes two comparators 64 and 66, each of which are supplied by voltages of ground and -9 volts. The positive input port of the first of the two transmit comparators 64 is connected, through a resistor 68, to the transceiver output port 9. The negative input port of the first transmit comparator 64 is connected between voltage divider resistors 72 and 74. The voltage potential generated by the voltage divider is labeled V ref2 . The output of the first transmit comparator 64 is connected to the positive input port of the second transmit comparator 66. The output of the first transmit comparator 64 is modified by a pulse stretcher, formed by resistor 76 and capacitor 78. The negative input of the second comparator 66 is supplied by a reference voltage, V ref1 , which in FIG. 3 is also generated by collision detector voltage divider resistors 52 and 54. This reference voltage may be generated independently from the collision voltage divider, but V ref1  is used in the embodiment of FIG. 3 to reduce the component count. The output port of the second transmit comparator 66 is then connected to the cathode terminal of the transmit detection light-emitting diode 14, whose anode terminal is connected to ground through resistor 79. 
     The comparators 44, 46, 64, and 66 in the circuit of FIG. 3 are LM339 integrated circuits. The first comparators 44 and 64 for each the collision and transmit detectors 12 and 16 must have input impedances sufficiently high to preserve the signal integrity of the medium 6. Generally, for ETHERNET, the input impedance must exceed 7.5 KΩ at 10 Mhz, and exceed 250 KΩ at DC. The LM339 satisfies these criteria. The LM339 offers an additional functional advantage by bleeding off charge from the diode 50 at the positive input of the first collision comparator 44. This is discussed further in conjunction with FIG. 4. 
     FIG. 4 shows a timing diagram of four waveforms for the collision detector 12. From top to bottom, the diagram includes the network waveform 80, the peak waveform 82, the output waveform 84, and the collision detection waveform 86. The network waveform 80 represents the voltage potential of the medium 6 during the transmission of packets on the network 2. The peak waveform 82 represents the voltage potential at the positive input port of the first collision detector comparator 44. The output waveform 84 represents the voltage potential at the output port of the first collision detector comparator 44 and at the positive input port of the second collision detector comparator 46. The collision detection waveform 86 represents the voltage potential applied to the cathode terminal of the light-emitting diode 14 for the collision detector 12. 
     At time t 0  on the network waveform 80, FIG. 4 shows the medium 6 to have a voltage potential at ground. This indicates that no packets transmissions are detectable by the transceiver 8. Under this condition, the peak waveform 82 is also at ground. The reference voltage V ref1  is shown to be approximately -2.1 volts, as produced by voltage divider resistors 52 and 54 having values of approximately 10 KΩ and 3 KΩ respectively. With the peak waveform 82 at a voltage above V ref1 , the output waveform 84 is held at the ground potential. With the output waveform 84 also at a voltage above V ref1 , the collision detection waveform 86 is also held at the ground potential. The value of V ref1  is chosen such that normal packets on the medium x maintain a network waveform x voltage above V ref1 , but that colliding packets create a voltage below V ref1 . 
     At time t 1 , a packet is transmitted on the network 2, resulting in a signal between ground and approximately -2 volts on the medium 6. Between times t 1  and t 2 , the negative-going signals of the network waveform 80 drive the peak waveform 82 to a voltage of approximately -1.2 volts. The diode 50 at the positive input of the first collision comparator 44 acts as a peak detector, holding the negative-going voltage extremes achieved by the network waveform 80. After the packet has passed, at tine t 2 , the peak waveform 82 decays toward ground as leakage current is drawn from the positive input of the first collision comparator 44. 
     A low-cost comparator, such as the LM339 integrated circuit used in the circuit of FIG. 3, requires that the voltage at its inputs be separated by 1.5 volts or more from the respective voltage rail for proper operation. In the embodiment of FIG. 3, this requires that V ref1  be less than -1.5 volts. This insures that the positive input of the first collision comparator 44 is more than 1.5 volts from ground when it crosses the reference voltage V ref1 . During some collisions between packets on the network 2, however, the average voltage does not fall below -1.48 volts. Therefore, an averaging circuit at the input of the first collision comparator 44, without the peak-detecting diode 50, would fail to detect these collisions. One alternative is to use a more expensive comparator which allows V ref1  to be closer to ground. The use of the peak-detecting diode 50, however, avoids the problem of undetected collisions while still allowing the use of a low-cost comparator, such as the LM339. 
     At tine t 3 , the beginning of a packet transmission is again shown, and the network waveform 80 reacts as described above. At time t 4 , however, a second packet transmission begins, overlapping with the first. The resulting network waveform 80 varies between ground and approximately -4 volts, which drives the peak waveform 82 to approximately -3.2 volts, due to the voltage drop across the diode 50. When the peak waveform 82 falls below V ref1 , the first collision comparator 44 pulls the output waveform 84 to the low supply voltage of approximately -9 volts. With the voltage of the positive input port of the second collision comparator 44 below V ref1 , the collision detection waveform 86 is also pulled to the low supply voltage of approximately -9 volts. The voltage potential generated across the collision light-emitting diode 14 by the collision detection waveform 86 causes the collision light-emitting diode 14 to be lit. 
     At time t 5 , the first packet transmission is completed, reducing the network waveform 80 to a minimum of approximately -2 volts. The peak waveform 82 then rises toward its potential prior to the packet overlap, -1.2  volts. This rise in voltage is due to a leakage current drawn from the positive input port of the first collision comparator 44. At time t 6 , the peak waveform 82 rises past the V ref1  threshold. With its positive input exceeding its negative input, the first collision comparator 44 increases its output voltage toward its high supply voltage, which is at ground. The rise time of the output waveform 84 is increased by a pulse stretcher formed from a resistor 56 and a capacitor 58. The pulse stretcher is used to lengthen the time during which the collision light-emitting diode 14 is lit in response to a collision, to insure that it is visible to a person who is observing the collision light-emitting diode 14. In the embodiment of FIG. 3, the values of the resistor 56 and capacitor 58 are, respectively, 100 KΩ and 0.1 μf, resulting in a time constant of 10 Ms. 
     At tine t 7 , the output waveform 84 exceeds the V ref1  threshold, causing the positive input of the second collision comparator 46 to exceed its negative input. The voltage differential applied across the collision light-emitting diode 14 is thereby removed at time t 7 . Thus, in response to the collision between two packets, the collision light-emitting diode 14 is lit from approximately time t 4  through time t 7 . Due to the pulse stretching effect of the resistor 56 and capacitor 58, the collision light-emitting diode 14 may remain lit for more than 1000 times longer than the duration of a collision. This precludes the collision light-emitting diode 14 from indicating the precise number of collisions, but allows it to remain lit long enough for a person observing to easily see the collision light-emitting diode 14 and to note the relative frequency with which collisions occur. 
     To improve the clarity of timing diagram, the horizontal time scale of FIG. 4, including time points t 0  through t 7 , is not linear. Using the embodiment of FIG. 3, the relative times shown in FIG. 4 are approximately as follow: 
     
         t.sub.2 =t.sub.1 +60μs 
    
     
         t.sub.4 =t.sub.3 +40μs 
    
     
         t.sub.5 =t.sub.3 +55μs 
    
     
         t.sub.6 =t.sub.3 +100μs 
    
     
         t.sub.7 =t.sub.3 +10.1μs 
    
     FIG. 5 shows a timing diagram of four waveforms for the transmit detector 16. From top to bottom, the diagram includes the transmit waveform 90, the averaged waveform 92, the transmit output waveform 94, and the transmit detection waveform 96. The transmit waveform 90 represents the voltage potential applied to the cathode of diode 42 of FIG. 3 by the transceiver 8 during the transmission of a packet by the transceiver 8. The averaged waveform 92 represents approximately the average of the transmit waveform 90, and is measured at the positive input of the first transmit comparator 64. The transmit output waveform 94 represents the voltage potential at the output of the first transmit detector comparator 64 and at the positive input of the second transmit detector comparator 66. The transmit detection waveform 96 represents the voltage potential applied to the cathode terminal of the light-emitting diode 14 for the transmit detector 16. 
     As shown at time to in FIG. 5, the transceiver 8 maintains a voltage potential of ground at the cathode terminal of the diode 42 during periods when the transceiver 8 is not transmitting packets on the network 2. The reference voltage V ref2  is shown to be approximately -1.8 volts, as produced by voltage divider resistors 72 and 74 having values of approximately 10 KΩ and 2.49 KΩ respectively. With the averaged waveform 92 at a voltage above V ref2 , the transmit output waveform 94 is held at the ground potential. The value of V ref2  is chosen such that the voltage of the averaged waveform 92 is less than V ref2  only while the transceiver 8 is transmitting packets on the network 2. With the transmit output waveform 94 also at a voltage above V ref1 , the collision detection waveform 96 is also held at the ground potential. 
     At time t 1 , the transceiver 8 begins transmitting a packet and asserts a signal which causes the transmit waveform 90 to vary between approximately -0.8 volts and -3 volts. In response to the transmit waveform 90, the averaged waveform 92 drops from ground to approximately -1.9 volts, as shown in FIG. 5. As the transmit waveform 90 drops below the reference voltage V ref2  the first transmit comparator 64 pulls the transmit output waveform 94 to the low supply voltage of approximately -9 volts. With the positive input of the second transmit comparator 66 below V ref1 , the transmit detection waveform 96 is also pulled to the low supply voltage of approximately -9 volts. The voltage potential generated across the transmit light-emitting diode 14 by the transmit detection waveform 96 causes the transmit light-emitting diode 14 to be lit. 
     At time t 2 , the transceiver 8 completes its transmission and reasserts a ground potential on the transmit waveform 90. With its positive input exceeding its negative input, the first transmit comparator 64 increases its output voltage toward its high supply voltage, which is at ground. The rise time of the transmit output waveform 94 is increased by a pulse stretcher formed from a resistor 76 and a capacitor 78. The pulse stretcher is used to lengthen the time during which the transmit light-emitting diode 14 is lit in response to a transmission by the transceiver 8 to insure that it is visible to a person who is observing the transmit light-emitting diode 14. In the embodiment of FIG. 3, the values of the resistor 76 and capacitor 78 are, respectively, 100 KΩ and 0.1 μf, resulting in a time constant of 10 ms. 
     At tine t 3 , the transmit output waveform 94 exceeds the V ref1  threshold, causing the positive input of the second transmit comparator 66 to exceed its negative input. The voltage differential applied across the transmit light-emitting diode 14 is thereby removed at tine t 3 . Thus, in response to the transmission by the transceiver 8, the transmit light-emitting diode 14 is lit from approximately time t 1  through time t 3 . Similar to the operation of the collision light-emitting diode 14, the transmit light-emitting diode 14 is lit for a duration to allow it to be easily observed by a person. 
     To improve the clarity of timing diagram, the horizontal time scale of FIG. 5, including time points t o  through t 3 , is not linear. Using the embodiment of FIG. 3, the times shown in FIG. 5 are approximately as follows: 
     
         t.sub.2 =t.sub.1 +60 μs 
    
     
         t.sub.3 =t.sub.1 +10.06 ms 
    
     It is apparent that, within the scope of the invention, modifications and different arrangements may be made other than as herein disclosed. The present disclosure is merely illustrative, the invention comprehending all variations thereof.