AN-2590: Streamlining USB Type C Designs with Reliable Moisture Detection from MAX20342
The warning sign on a mobile while plugging the USB charger saying, “We have detected moisture or foreign material on your charging port” is a clear indicator that the USB port in the phone is protected from moisture.
Introduction
The widespread adoption of the USB Type-C standard has brought numerous benefits to the world of consumer electronics, allowing for faster data transfer, higher power delivery, and more versatile connectivity in a single connector. However, compared to other USB ports, the advancement in USB Type-C, including its high pin density and power handling capability (up to 20V), present challenges related to moisture ingress. Accidental exposure to the moisture can lead to the degradation or corrosion of USB port. To address this issue, Analog Devices has developed the MAX20342 USB Type-C port interface IC, a highly integrated device that features advanced moisture detection capabilities to safeguard connected systems from potential damage.
This article provides an overview of the MAX20342 and its key features, including the moisture detection feature. It also provides guidance on how to use the device in a typical USB Type-C system. In addition, the article includes a design example and a step-by-step guide for configuring the device using the MAX20342 evaluation kit.
By using the MAX20342 in a USB Type-C system, designers can protect their devices from accidental exposure to moisture and ensure reliable operation in a wide range of environments.
MAX20342 Overview
The MAX20342 is a highly integrated universal serial bus (USB) Type-C charger detector with advanced features, including VBUS overvoltage protection, USB Type-C detection logic, charger detection capability for BC1.2 compatible charger, negative swing audio capable hi-speed USB/universal asynchronous receiver transmitter (UART) switches, and electrostatic discharge (ESD) protection on CC, SBU, and D+/D− pins. However, one of the most notable features of the MAX20342 is its resistance detection capability, which can help USB type-C devices to detect the moisture in the USB connector and any accessory attached to it. The MAX20342 can be configured as upstream facing port or downstream facing port (UFP or DFP) depending on factory configuration.
Implementing moisture detection in USB Type-C systems can be a challenging task, as it requires specialized sensors and algorithms to accurately detect moisture levels. This can add complexity and cost to the design process, which is why the MAX20342 IC is a valuable solution for designers looking to simplify the process of incorporating moisture detection into their designs.
In the following sections, let us explore the key features and benefits of the MAX20342 IC in more detail, including how the moisture detection feature works and the advantages it provides for USB Type-C system designers. Let us also discuss some of the common challenges associated with moisture detection in USB Type-C systems and how the MAX20342 IC helps address these challenges.
Moisture Detection
Exposure to moisture, whether from environmental factors like humidity or water exposure, or from human error such as sweat or condensation, poses a significant risk to USB ports. When moisture infiltrates USB ports, it can trigger corrosion or short circuits, and potentially cause system failure or safety hazards. Devices equipped with on-the-go (OTG) mode are especially susceptible to moisture damage, as the lack of proper detection mechanisms can cause short circuits and irreversible damage to the device.
The MAX20342 IC employs a unique approach to moisture detection, allowing it to accurately detect the presence of moisture on the USB Type-C connector pins without relying on traditional humidity sensors. When moisture is present on the USB Type-C connector, it causes a change in the impedance of the CC pins, swiftly detected by the MAX20342. Additionally, if a change is detected, the MAX20342 may also measure the impedance of other pins. This information is then relayed to the system controller, enabling it to activate an alarm or shutdown sequence to safeguard the system from potential damage.
Moisture Detection Algorithm
The MAX20342 integrates a resistance measurement block in the CC, SBU, D+/D-, and VBUS pins, as illustrated in Figure 4. This resistance block comprises an 8-bit SAR ADC and four switchable pull-up currents, along with one bank of pull-up switches and one bank of pull-down switches. Each USB Type-C pin is equipped with one pull-down switch and two pull-up switches. The pull-down switch establishes a connection to ground, while the two pull-up switches connect the pin to the forced node, where the pull-up current source is connected, and to the sensed node, where the ADC is connected, respectively.
To measure the moisture on the CC1 pin, the CC1 pull-up switches are connected to the force node and sense node, while the pull-down switches of all the other pins are connected to ground. The resistance can then be determined, knowing the forced pull-up current and the sensed voltage. These pull-up and pull-down switches can be automatically or manually configured by writing into the MoistDetCtrl [4] ( MoistDetAutoCfg ) 0x51 register. The MAX20342 also supports manual triggering (MoistDetManEn = 1) or periodic triggering (MoistDetPerEn = 1). The moisture detection function is run only when the MAX20342 is not in shutdown mode and the USB cable is not attached.
The system designer can choose the threshold moisture level by selecting the RMOIST, which is a combination of ADC voltage threshold RMoistDetVth[7:0] and the selected pull-up current RMoistDetIpu[1:0]. When the measured resistance is below RMOIST, the ResMoistInt interrupt is asserted. After measuring the resistance of the CC line, the following outcomes are possible.
- Open: CC line is open. The final imposed pull-up current at CC pin is 2µA. The open result is reported with IpuResult[1:0] = 00 and ADCResultAvg = 0xFF.
- Abort: Abort indicates the device is unable to determine the resistance due to unfiltered noise or uncorrected measurement error on the node. The abort result is reported with IpuResult[1:0] = 0b00 and ADCResultAvg = 0x00.
- Finite or Moisture: If the CC line is terminated with finite resistance or has some moisture content. The MAX20342 monitors the pull-up current (IpuResult[1:0]) and average ADC voltage (ADCResultAvg[7:0]). When pull-up current is equal to the moisture detection pull-up current (RMoistDetIpu[1:0]) and average ADC result is less than moisture detection threshold voltage (RMoistDetVth[7:0]), or if the pull-up current is greater than moisture detection pullup current, the MAX20342 detects a moisture in the CC line. Figure 5 shows a flow diagram of the moisture detection in automatic mode.
Laboratory Testing: Evaluating Moisture Detection Performance
To assess the reliability of moisture detection in USB Type-C designs featuring the MAX20342 IC, a comprehensive laboratory testing was conducted using the MAX20342 Evaluation Board.
Experimental Setup: The MAX20342 evaluation board was subjected to controlled exposure to moisture by applying water droplets directly onto the USB Type-C connector, as shown in Figure 6. Refer to the EV kit data sheet to configure the EV kit for moisture detection.
The EV kit is set up for Enable Automatic Configuration and Enable Periodic Measurement, where the MAX20342 is used to measure the resistance between CC1 (alternatively CC2) and all other USB Type-C pins, which are grounded. Regarding periodic measurements, the MAX20342 updates the measured resistance every ten seconds. The moisture detection threshold impedance is set to 700KΩ.
Data Collection and Analysis: Real-time data on moisture levels and corresponding responses were collected and analyzed using the provided graphical user interface (GUI) for the MAX20342 evaluation board. The MAX20342 IC exhibited high sensitivity in detecting moisture, reliably identifying even minor traces of water on the USB Type-C connector.
The GUI shows the measured impedance between the different USB pins to ground. As shown in Figure 7, as the impedance of CC1 line (256kΩ) is less than the set threshold (700KΩ), the moisture interrupt is set to 1.
Summary
The moisture detection feature on the MAX20342 IC is highly configurable, allowing designers to customize the sensitivity and response time to meet the requirements of their specific applications. This flexibility ensures that the MAX20342 IC can be used in a wide range of USB Type-C systems, from consumer electronics to industrial applications.






