Analog Output

Chapter goal

Goal: Output distance or magnitude via the analog output.

Prerequisite

The CMTK here is only for parameterization – for measuring or checking a current/voltage value or switching level you must connect the sensor to suitable evaluation or control equipment (e.g. PLC, measuring device).

How it works

The sensor can output the measured distance or magnitude via the analog output at Pin 2 as a voltage or current signal. The parameter tables below give an overview of the relevant settings.

Parameter table
Parameter table

Parameter
Section
Parameter name

Index
Subindex

Default

Lower limit measurement range
Sensor Measurement Config
Measurement Range.Lower

514
1

300 mm

Upper limit measurement range
Sensor Measurement Config
Measurement Range.Upper

514
2

15000 mm

Pin 2 mode
Pin Configuration and Assignment
Pin 2 Function.Pin Mode

147
2

Inactive

Analog output signal source
Pin Configuration and Assignment
Pin 2 Analog Configuration.Signal Source

149
1

Target Distance

Analog output type
Pin Configuration and Assignment
Pin 2 Analog Configuration.Type

149
3

4-20 mA

Pin assignment
IO-Link port (M12, A-coded, socket)

IO-Link port (M12, A-coded, socket)

Pin assignment

PIN

Function

1

24 V

2

Digital output / Analog output

3

0 V

4

IO-Link / Digital output

Configuration

1. Activate analog output

Set Pin‑2 mode to Analog Output. You can find the pin configuration under Pin Configuration and Assignment. By default, the pin outputs distance as a current value (4–20 mA).

Analog output

2. Configure signal source

You can choose either distance (Target Distance) or magnitude (Target Strength) as signal source.

Info

Distance: Scaled based on the configured measurement range (see step 4). Factory setting: 300 mm to 15000 mm → for 4-20 mA this means 4 mA = 300 mm and 20 mA = 15000 mm.

Magnitude: Fixed range 0 dB to 64 dB → for 4-20 mA this means 4 mA = 0 dB and 20 mA = 64 dB.

Signal source

3. Configure type

The analog output supports the following current and voltage signals:

  • 4-20 mA

  • 0-20 mA

  • 1-5 V

  • 0-10 V

  • 2-10 V

Analog output type

Note

Current and voltage ranges are nominal. Error and status conditions can exceed upper or lower limits.

Value Meaning

Value

Meaning

11 V / 22 mA

Sensor in error state

10.5 V / 20.5 mA

Measured value above measurement range

−0.5 V / −0.5 mA

Measured value below measurement range

4. Configure measurement range

The measurement range defines scaling (lower / upper limit) for distance. Configuration under Sensor Measurement Config.

Measurement range

Warning

The measurement range also defines the safe measurement range. Values outside the safe range are indicated by a yellow blinking LED.

Convert analog values

Conversion

Current

Calculation of output current or back‑calculation to distance:

\[ \begin{align}\begin{aligned}I_{\text{out}} = I_{\text{min}} + \frac{x - x_{\text{min}}}{x_{\text{max}} - x_{\text{min}}} \cdot (I_{\text{max}} - I_{\text{min}})\\x = x_{\text{min}} + (x_{\text{max}} - x_{\text{min}}) \cdot \frac{I_{\text{out}} - I_{\text{min}}}{I_{\text{max}} - I_{\text{min}}} \end{aligned}\end{align} \]
  • \(I_{\text{out}}\): output current

  • \(I_{\text{min}}\): lower current limit (e.g. 4 mA)

  • \(I_{\text{max}}\): upper current limit (e.g. 20 mA)

  • \(x\): measurement value (distance mm or magnitude dB)

  • \(x_{\text{min}}\): lower measurement range limit

  • \(x_{\text{max}}\): upper measurement range limit

Tip

For distance the measurement range is configurable. Factory settings: 300 mm to 15000 mm. For magnitude the range is fixed at 0 dB to 64 dB.

Example: For a measurement of 800 mm in the range 300–1300 mm:

\[I_{\text{out}} = 4\,\text{mA} + \frac{800\,\text{mm} - 300\,\text{mm}}{1300\,\text{mm} - 300\,\text{mm}} \cdot (20\,\text{mA} - 4\,\text{mA}) = 4\,\text{mA} + 0.5 \cdot 16\,\text{mA} = 12\,\text{mA}\]
\[x = 300\,\text{mm} + (1300\,\text{mm} - 300\,\text{mm}) \cdot \frac{12\,\text{mA} - 4\,\text{mA}}{20\,\text{mA} - 4\,\text{mA}} = 300\,\text{mm} + 1000\,\text{mm} \cdot 0.5 = 800\,\text{mm}\]

Voltage

Analog voltage:

\[U_{\text{out}} = U_{\text{min}} + \frac{x - x_{\text{min}}}{x_{\text{max}} - x_{\text{min}}} \cdot (U_{\text{max}} - U_{\text{min}})\]
\[x = x_{\text{min}} + (x_{\text{max}} - x_{\text{min}}) \cdot \frac{U_{\text{out}} - U_{\text{min}}}{U_{\text{max}} - U_{\text{min}}}\]
  • \(U_{\text{out}}\): output voltage

  • \(U_{\text{min}}\): lower voltage limit (depends on type)

  • \(U_{\text{max}}\): upper voltage limit

  • \(x\): measurement value (distance mm or magnitude dB)

  • \(x_{\text{min}}\): lower measurement range limit

  • \(x_{\text{max}}\): upper measurement range limit


Next section

Step 4 – Object detection

Object Detection