PP logo

AP01

Audio Polarity Tester.

Contents


Introduction.

An Audio polarity tester is an invaluable tool for testing the polarity of microphones and loudspeakers.
The original circuit was designed to run off 2 22 V batteries supplying 22 V for the electronics and 44 V for microphone phantom power.
As 22 V batteries are almost impossible to get anymore, the circuit was re-designed to run from a 9 V battery.
Inputs include phantom powered or dynamic microphone, balanced or unbalanced line inputs or a built-in microphone.
Outputs include balanced or unbalanced microphone / line outputs or an internal or external loudspeaker.
Testing is done by applying a pulse-train to the system under test and measuring the polarity of its output signal.
The generator and detector works independently of each other so two units can be used if you have a large distance between input and output.


Detector.

Measurement speaker/microphone response.
Fig.1: Measurement speaker/microphone response.

Lime: Loudspeaker signal.
Blue: Amplified microphone signal ( electrically inverted ).

The plot above was measured with the loudspeaker laying on the table and the microphone hanging in its wires approximately 5 cm above it.
This is the cause of the undamped ringing. It can be reduced by placing a 10 Ω resistor across the voice-coil and will be reduced when the speaker is mounted in an enclosure.
The pulse into the loudspeaker is generated by discharging a capacitor into it. The repetition rate is around 1 s.
I tried testing with some different speakers, including a 2-way system, and in some cases the second pulse to arrive ( around 5.5 ms ) has a higher amplitude than the first one.
To detect the polarity of the signal, it is necessary to measure the polarity of the first signal that arrives at the microphone.

AP01 detector schematic.
Fig.2: AP01 detector. VCC is 9 V.

The circuit around U3B and U3C ( a LM339 ) is a window comparator with a sensitivity of 75 mV.
The sensitivity can be increased to 20 mV by reducing R76 and R80 to 50 Ω ( do not go lower - it may cause problems with the comparator's offset voltage and current ).
The different values of R66 and R82 is to place VREF in the center of U3's common mode input voltage range.
R78 centers the input bias voltage in the comparator window.
C60 is AC coupling and R65 is current limiting. Without R65, the LM358 that drives VDET can sink sufficient current to drive U3 into latch-up. A current limited power supply saved U3 from destruction during testing.
U3D and U3E detects which of U3B and U3C goes low first.

When the detector is idle, we have the following voltages:
V(D13) = 3.6 V
V(D14) = 3.7 V
V(D15) = 3.5 V
V(D16) = V(D17) = 8.8 V
V(D18) = V(D19) = 8.8 V
V(D20) = V(D21) = 4.3 V
V(D22) = V(D23) = 8.6 V

When V(D13) goes below V(D15):
V(D16) will go low, pulling V(D19) down to 0.8 V
V(D23) will go low, pulling V(D21) low, preventing U30D to change state.
The waveforms are shown in the following 2 plots:

AP01 waveform plot, 100ms.
Fig.3: AP01 waveform plot, 100 ms.

AP01 waveform plot, 2s.
Fig.4: AP01 waveform plot, 2 s.

Lime: V(D15).
Blue: V(D13).
Red: V(D16).
Cyan: V(D19).
Magenta: V(C23).
Maroon: V(C17).
Green: V(D22).

Fig.4 shows that the LED showing the polarity will flash.
There are 2 reasons for that:
The circuit must reset between pulses to show the correct polarity.
It is possible to put a delay on the LEDs so they stay on and show the correct polarity, but then you can not see which signal that trigs it.


Input Amplifier.

The input amplifier is a differential type with adjustable gain.

Fixed and variable gain differential amplifier schematic.
Fig.5: Fixed and variable gain differential amplifier.

Fig.5(a) shown a very common differential amplifier.
The voltage gain of this circuit is:
Av = VOUT / ( IN_P - IN_N ) = RB / RA.
In order to change the gain, you will need to change 2 resistors.

Fig.5(b) is the same circuit, but modified for variable gain.
Av ( min ) = VOUT / ( IN_P - IN_N ) = RB / RA.
Av ( max ) = VOUT / ( IN_P - IN_N ) = ( RB / RA ) * ( 1 + RC / RD ).

AP01 input amplifier schematic.
Fig.6: AP01 input amplifier

The amplifier used here is the same as shown in Fig.5(b), except that its DC reference is VREF ( from the detector ) rather than ground.
This is the reason to AC-couple the potmeter.
R50 is used to trim the potmeter law.
Setting the sensitivity potmeter in the center works in most cases.
For low-impedance dynamic microphones a higher gain is normally required.
If the "background" noise is so loud it can trig the detector, use a lower gain.
There are a number of inputs to choose from. All connectors are just summed on the board. Only plug in the one you want to use. The internal microphone must have a switch.

Table 1: AP01 inputs.
InputConnectorPin-outUse
IN1XLR3F1:GND, 2:+, 3:-Balanced or unbalanced line.
Dynamic microphone.
Capacitor microphone with phantom power.
IN2¼" Jack socketSleeve:GND, Ring:-, Tip:+Same as IN1, but there is no phantom power.
IN3XLR3F1:GND, 2:+, 3:+9 V9 V powered measurement microphone.
IN4RCA socketGND:GND, Tip:+Unbalanced line input.
IN5Internal microphone For internal electret microphone with a switch in series.
Maximum microphone current is 0.5 mA.

If you want to change the gain of the circuit, change the input resistors or R55 / R51. If you need more gain, you may have to find an OP-AMP with a higher GBW.
Do not increase R53, R59 if you want to use the circuit with an electret microphone. The microphone bias current flows in R59.

The resistors shown for the phantom supply is for the standard P48. For other systems, see Appendix B: Other Phantom Voltages.


Pulse Generator.

Pulse generator schematic.
Fig.7: Pulse generator.

The circuit around U1B is a standard astable multi-vibrator running at around 1 Hz.
C20 is connected to VCC so the circuit starts with a pause rather than a pulse.
C21, R29 and D23 is a differentiator that reshapes the square wave from U1B into a pulse train.
The circuit around Q20 is an amplifier that will deliver 3 V..5 V into an 8 Ω speaker.
R22 limits the peak current in Q20 to 400 mA.
R21 and C24 is supply decoupling to prevent a dip in the supply voltage for each pulse.
The internal speaker is connected across the SP+ and SP- terminals in series with a switch.
The terminals for the external speaker is connected directly to SP+ and SP-.
The UO+ and UOG terminals are connected to a RCA socket.
The BO+, BO- and BOG terminals are connected to a XLR3M and a ¼" jack socket in parallel.
C22 and C23 are DC blocking capacitors allowing the output to be connected to a phantom powered input.


Power Supply.

Power Supply schematic.
Fig.8: Power Supply.

D1 is included for battery holders without mechanical reverse voltage protection.
If you use a holder with reverse voltage protection, replace D1 with a short.
A 1N5817 would be a better choice due to its lower forward voltage drop, but I need the high-voltage STPS1150 in the phantom supply, so I reused it here.
The upper switch is for the polarity tester circuit and the lower switch for the phantom supply.
R2, C1..C4 is decoupling for the polarity tester supply. C2..C4 are ceramic types placed close to the ICs.

The circuit around U5 is a simple 9 V to 48 V 100 kHz step-up converter designed for a maximum load current of 50 mA.
The efficiency of this regulator at low currents is quite poor making it useless for general purpose battery powered applications, but for intermittent use, like this, I find it acceptable.
R7 and C10 is a low-pass filter that reduce the amount of 100 kHz ripple on the output by a little over 70 dB ( if you calculate it at 86 dB, you forgot C10's ESR ).
C11 reduce the high-frequency content of the switcher noise.
The switcher's output voltage is set in the upper end of the phantom specification window ( 44 V..52 V ) to allow the highest possible value for R7.
The phantom supply requires quite a lot of current from the battery so it will only work with batteries with low internal resistance.
It does work with Alkaline batteries. It does not work with slightly used carbon-zinc types. I have not tested Li-Ion batteries, so I do not know if they will work.
The value for R7 is suitable for P48 phantom supply. For other systems, see Appendix B: Other Phantom Voltages.

Table 2: Phantom supply current requirement.
Output currentBattery currentBattery lifeComment
020 mA20 hours
2 mA40 mA10 hours"Typical" microphone current.
10 mA100 mA4 hoursMaximum P48 current.
15 mA130 mA3 hoursP48 short circuit current.
22 mA170 mA2 hoursMaximum SP48 current.
44 mA300 mA1 hoursSP48 short circuit current.

Battery life estimate is for a 400 mAh battery assuming battery capacity is load-independent ( it is not ).


Component Selection.

Resistors

Use 1% metal film resistors with a 0.25 W power rating except as noted.
You should find a suitable value for the LED series resistors ( R1, R3, R75 and R81 ) before you start to mount the PCB.
Their value will depend on the LED type you use.

Film capacitors

I originally intended to use ceramic 100 V types for the 100 nF and 470 nF capacitors, but these days film capacitors are cheaper.
63 V film capacitors can be used.
Note that the available width for C62 and C63 is 3.5 mm. If you cannot get 470 nF in this width, use 330 nF.

Electrolytic capacitors

Use 20% general purpose types with sufficient voltage rating.
C21 and C22 should be 63 V or 100 V types.
The ripple current in C9 is up to 150 mA so it must be able to handle that.
Use a type designed for switch-mode supplies for C9.
C10 can be a general purpose type, but a type designed for switch-mode supplies will give lower output ripple.

Ceramic capacitors

C2..C4, C7 and C11 must be ceramic types. C11 must have a voltage rating of at least 100 V.
C54 and C55 are general purpose NP0 capacitors.

Inductor

The inductor is an ∅11 * 19 mm type with 2 or 4 pins. The footprint will fit a 4-pin with a 4 * 5 mm pattern or a 2-pin type with 6 mm or 6.4 mm pin-spacing.

Switches

The test setup was made with 4 toggle switches and was not very easy to use.
In the final unit, I used 2 rotary switches.

Transistors

Q20 must have a current rating of at least 0.5 A and a hfe of 200 or more.

Loudspeaker

I have tried with several of the small speakers that are used inside PCs, but results were not very good and they are difficult to mount.
The polarity depended on where in front of the speaker the microphone was located.
I ended with a 10 cm 8 Ω type ( I would have preferred around 5 cm, but could not easily get one ).
Get one where the cone can move so much you can see it and test the polarity with a 1.5 V battery ( the one I have is incorrectly marked ).

Microphone

The microphone is a standard ∅10 mm electret microphone.
The microphone must give a positive output for air compression ( I think most do, but I have one with the opposite polarity ).
It may be possible to use a microphone with "wrong" polarity by connecting it between the 9VM and IN5+ terminals ( I have not tested this ).
The microphone supply current must be <0.5 mA ( most are ).

Measurements.

This is some measurements on the prototype.

Generator/detector supply current: 2.6 mA.
Output voltage into an 8 Ω speaker: 4 V-p.
Line output voltage: 0..0.5 V-p.
Input sensitivity: 5 mV-p to 0.5 V-p.

Phantom supply start-up voltage: 3.5 V.

Table 3: Efficiency ( or in-efficiency ) of the phantom voltage regulator.
Input voltageSupply currentOutput voltageOutput currentEfficiency
9.00 V20.0 mA49.8 V0
9.00 V29.3 mA49.4 V1.0 mA19%
9.00 V41.0 mA49.1 V2.0 mA27%
9.00 V63.3 mA48.1 V5.0 mA42%
9.00 V102 mA46.3 V10 mA50%
9.00 V131 mA44.6 V15 mA57%
9.00 V172 mA42.1 V22 mA60%
9.00 V302 mA34.3 V44 mA56%
9.00 V340 mA32.4 V50 mA53%

The input voltage is measured between the BAT- and the PHA terminals.
The output voltage is measured across C10.
Note that the maximum long term current in R7 is 40 mA ( 348 Ω / 0.6 W in the prototype ).
The primary reasons for the low efficiency is the LM2585 supply current and the power loss in R7.
The measurements above 15 mA load current is just to see the supply current ( the load current of a shorted P48 suply is 15 mA ).

Although noise performance is irrelevant for this application, I measured it out of curiosity:

Table 4: Noise measurements.
Output current02 mA10 mA
Noise, 10 Hz - >300 kHz BW-70 dBu ( 245 µV )-69 dBu ( 275 µV )-69 dBu ( 275 µV )
Noise, 400 Hz - 22 kHz BW-118 dBu ( 0.98 µV )-118 dBu ( 0.98 µV )-113 dBu ( 1.7 µV )
Noise, 22 Hz - 22 kHz BW-109 dBu ( 2.8 µV )-100 dBu ( 7.8 µV )-100 dBu ( 7.8 µV )
Noise, 100 kHz Bandpass-84 dBu ( 49 µV )-77 dBu ( 109 µV )-73 dBu ( 173 µV )

The supply was a 9 V battery.
The output voltage is measured across C10.
The high levels of noise in the 22 Hz - 22 kHz bandwidth is mains hum ( the board was just laying on the table ).
The 100 kHz bandpass filter is ⅓ octave.


PCB.

AP01 PCB photo.
Fig.9: Photo of mounted PCB. Dimension is 90x53 mm.

The LM2585 on this photo is a SMD type mounted on an adapter board rather than a through hole type.

I have boards available for this project. See the PCBs page.


Downloads.

AP01B design files.


Known Issues / updates.

AP01B:
No known issues.


Appendix A: Board Wiring.

This shows the wiring of my prototype. You can of course add or remove connectors to suit your application.

AP01 wiring schematic.
Fig.10: AP01 wiring.

Most of the wiring for this design is quite uncritical and can be made with 0.1 mm2 to 0.25 mm2 unshielded wire.
If you have the phantom voltage supply mounted, wires to the BAT+, BAT-, V+ and PHA terminals should be 0.5 mm2.
The supply for the phantom supply use 3 sections of the switch in parallel for increased current handling.
This is necessary if you use the cheap C&K switch copies - they will not handle more than around 200 mA per section ( the original C&K will handle several amps ).

The microphone connections should be routed away from other wiring or be wired using shielded cable.
The switch is connected so the internal speaker is shorted when it is not in use in order to dampen it to reduce the signal on the rear side of the microphone.
The 2 "unused" sections on the switch are connected to GND and used as mechanical support for the wiring.

AP01 wiring schematic.
Fig.11: AP01 wiring.

The wiring for the input and output sections should be separated by some mm or wired with shielded wire.


Appendix B: Other Phantom Voltages.

This table shows the component values for the 5 phantom power systems that I know of.
I have only tested P48.

Table B1: Phantom supply component values.
SystemVoltageSupply resistors Maximum currentC8L2R4R5R6R7R57, R58R85, R86
P12L12 V ±1 V3.3 kΩ4 mA10 µF1 mH11 kΩ330 Ω1.2 kΩ240 Ω3.3 kΩ0 ( jumper )
P1212 V ±1 V680 Ω15 mA10 µF1 mH11 kΩ330 Ω1.2 kΩ68 Ω680 Ω0 ( jumper )
P2424 V ±4 V1.2 kΩ10 mA680 nF680 µH75 kΩ1.2 kΩ3.6 kΩ560 Ω/0.5 W1.2 kΩ0 ( jumper )
P4848 V ±4 V6.8 kΩ10 mA470 nF680 µH130 kΩ2.7 kΩ3.3 kΩ360 Ω6.8 kΩ/0.5 W0 ( jumper )
SP4848 V ±4 V2.2 kΩ22 mA470 nF680 µH130 kΩ2.7 kΩ3.3 kΩ160 Ω/0.5 W1.1 kΩ/0.5 W1.1 kΩ/0.5 W

C9 and C10 minimum voltage rating is 16 V for P12, 35 V for P24 and 63 V for P48.
If you are concerned with the output noise, C10 should be the largest value that fits in the PCB.
The 10 µF C8 can probably be an electrolytic. I have not tested it.


Appendix C: Some Hints.

For multi-way systems, measure as close to the low-frequency driver as possible.

For testing car installations, I used to record the test signal ( to cassette tape ) and play it back for measurement.
Some car speakers are 2 or 3 way units with the high frequency driver(s) mounted in front of the low frequency driver.
Moving the microphone a few cm in front of the unit will show correct/wrong polarity.
Recording the signal through a low-pass filter ( first order, around 200 Hz ) gives a more consistent reading.


Copyright and disclaimer.

Copyright Notice.
This web-page, including but not limited to all text, drawings and photos, is the intellectual property of Poul Petersen, and is Copyright ©.
Reproduction or re-publication by any means whatsoever is strictly prohibited under International Copyright laws.
The author grants the reader the right to use this information for personal use only.
Any commercial use is prohibited without express written authorization from Poul Petersen.

The information is provided on an "as-is" basis and is believed to be correct, however any use of the information is your own responsibility.

This web-site may contain links to web-sites outside Poul Petersen domain ( www.poulpetersen.dk ).
Poul Petersen has no control over and assumes no responsibility for the content of any web-site outside Poul Petersen own domain.

Poul Petersen does not use cookies to "enhance your experience" on this website.


Poul Petersen, C/Faya 14, 35120 Arguineguín, Las Palmas, Spain.
E-mail: diy@poulpetersen.dk

Poul Petersen DIY index

Poul Petersen notes index


Copyright © Poul Petersen 2020. Last update: 20200117. Valid HTML!