LM393DG
AI

The **LM393DG** is a widely used, low-power, dual-voltage comparator integrated circuit (IC). It is designed to operate from a single power supply across a wide range of voltages.
### 1. Key Technical Specifications
| Parameter | Specification |
| :--- | :--- |
| **Number of Channels** | 2 (Dual) |
| **Supply Voltage (Single)** | 2.0V to 36V |
| **Supply Voltage (Dual)** | ±1.0V to ±18V |
| **Output Type** | Open Collector |
| **Response Time** | 1.3 μs (typical) |
| **Package Type** | SOIC-8 (The 'D' in DG refers to SOIC, 'G' refers to Green/Pb-free) |
| **Input Offset Voltage** | 5.0 mV (max) |
---
### 2. Internal Architecture & Pinout
The LM393DG consists of two independent precision voltage comparators.
#### Pin Configuration (SOIC-8)
1. **OUTPUT A:** Output of the first comparator.
2. **INPUT A (-):** Inverting input of the first comparator.
3. **INPUT A (+):** Non-inverting input of the first comparator.
4. **GND:** Ground (or negative supply).
5. **INPUT B (+):** Non-inverting input of the second comparator.
6. **INPUT B (-):** Inverting input of the second comparator.
7. **OUTPUT B:** Output of the second comparator.
8. **Vcc:** Positive supply voltage.
---
### 3. Core Features & Functional Behavior
#### Open Collector Output
The output stage of the LM393DG is an **Open Collector**. This is a critical electronic characteristic:
* It requires an external **pull-up resistor** to function correctly.
* This allows the output to interface with various logic levels (e.g., interfacing a 12V comparator circuit with a 5V microcontroller) by connecting the pull-up resistor to the desired logic voltage.
#### Differential Input Voltage Range
The IC is designed to handle a differential input voltage equal to the power supply voltage. Even when operating from a single supply, the input common-mode voltage range includes ground.
---
### 4. Typical Applications
Because of its versatility, the LM393DG is found in many common electronic circuits:
* **Zero-Crossing Detectors:** Detecting when an AC signal passes through 0V.
* **Level Translators:** Converting signals between different voltage domains.
* **Limit Comparators:** Monitoring if a sensor voltage stays within a specific "window."
* **Oscillators:** Creating square wave generators when used with RC networks.
---
### 5. Implementation Example
Below is a simple Python-like pseudocode representation of how the LM393 logic works in a physical circuit:
```python
# Conceptual logic of an LM393 comparator
def lm393_logic(v_plus, v_minus, v_pullup):
if v_plus > v_minus:
# Open collector is "OFF", output pulled high by resistor
return v_pullup
else:
# Internal transistor is "ON", output connected to GND
return 0.0
```
- ⤷
Why is a pull-up resistor required for the LM393DG?
- ⤷ What is the difference between a voltage comparator and an operational amplifier?
- ⤷ Can the LM393DG be used with a split power supply (+/- 15V)?