Overview: TB30 Analog Output Signal Path
The Terminal Board 30 (TB30) is a plug-in I/O expansion module for the SINAMICS S120 Control Unit (CU320, CU310, CU305) that adds isolated digital and analog channels to a drive controller. It provides two analog inputs (AI0/AI1), two analog outputs (AO0/AO1), four bidirectional digital inputs, and four bidirectional digital outputs through a D-sub connector (X481) and screw terminals (X482, X483). Because the TB30 is wired through its own PROFIdrive/PZD slot, its outputs are not mapped to the Control Unit's own telegram by default; you must configure a dedicated telegram for the TB30 and bind the analog output word to a process-data address that your application program can write to.
The end-to-end signal path looks like this:
Application Variable (Task) → IO Symbol (Word, OUT) → Symbolic/PQW Address (e.g. PQW262) → Telegram PZD Slot → TB30 r2050 mapping → TB30 DAC → X482 terminal
This article walks through configuring that path with SIMOTION SCOUT V4.1, creating an IO Symbol, attaching it to the TB30 PZD slot, and writing a global variable into it from a MotionTask or background task.
Prerequisites
- SINAMICS S120 drive line-up with a Control Unit that supports the TB30 (CU320, CU320-2, CU310, CU310-2, CU305). Verify compatibility in the TB30 Terminal Board documentation.
- SIMOTION SCOUT V4.1 (or compatible) installed with the matching SINAMICS Support Package (SSP) and STARTER/SCOUT device version.
- A configured drive object (DO) tree with the Control Unit, one or more Motor Modules, and the TB30 inserted under the Control Unit in the project navigator.
- Standard Telegram 391 (or equivalent free-PZD telegram) configured on the Control Unit to expose a contiguous PZD image for the TB30.
- Global variable defined in the SCOUT program (e.g. a
VAR_GLOBAL RETAINin ST or a unit variable in MCC/LAD/FBD).
TB30 Hardware Reference
| Channel | Terminal | Range | Resolution | Update |
|---|---|---|---|---|
| Analog output 0 (AO0) | X482 pin 1/2 (DAC0+/DAC0-) | -10 V to +10 V (or 0-20 mA, switch S1.1) | 12-bit signed | 4 ms (typical) |
| Analog output 1 (AO1) | X482 pin 3/4 (DAC1+/DAC1-) | -10 V to +10 V (or 0-20 mA, switch S1.2) | 12-bit signed | 4 ms (typical) |
| Digital I/O 0-3 | X483 | 24 V bi-directional | — | 2 ms |
| Power supply | X482 +24 V/0 V | 24 VDC, 1.0 A max | — | — |
The DAC output voltage is proportional to the 16-bit signed integer the drive writes into the PZD word. With 12-bit resolution, the lowest bits are truncated; the drive still expects a full 16-bit value, normalized so that 0x7FFF = +10 V (or 0x7FFF = +20 mA) and 0x8000 = -10 V (or 0x0000 = 0 mA).
Reference voltage and current ranges are selectable per output with DIP switch S1 on the TB30 PCB. S1.1 controls AO0, S1.2 controls AO1. Set the switch BEFORE applying power, and verify with parameters p4771[0..1] (output type) and p4770[0..1] (smoothing time constant).
Step 1: Configure the TB30 PZD Telegram
The TB30 receives its process data through its own PROFIdrive slot inside the Control Unit. The Control Unit must publish that slot to a telegram that contains the right number of PZD words for your analog outputs.
- In SCOUT, double-click the Control Unit in the project tree.
- Open Configuration → Telegram configuration.
- Select the TB30 row and click Adapt telegram configuration. The default is without PZD; change it to a free-PZD telegram such as 999 (free assignment) or a Siemens standard telegram that includes the TB30. If you are using standard Telegram 391 on the Control Unit, ensure the TB30 row has at least 2 PZD words allocated (one for AO0, one for AO1).
- Click Apply and confirm the slot number for the TB30. The slot is reported in the configuration view (typically slot 7 or 8 for a CU320, slot 0 for a CU310).
- Press Download to the drive. The drive may transition to a configuration error (F0135/F0851) briefly while the new telegram is activated; clear faults after the new config is online.
Step 2: Map the TB30 Analog Outputs to PZD Words with p2050
The drive parameter that binds a PZD word to a real signal is r2050[k] on the Control Unit (where k is the PZD index of the TB30). To route the TB30's first analog output to the first word of the TB30 slot:
p2050[0] = "TB30" r2050.0 // analog output 0 signal source
For two analog outputs, the typical assignments are:
p2050[0] = TB30.AO0
p2050[1] = TB30.AO1
The exact r2050 mnemonics vary by firmware version. The classic forms are:
| TB30 PZD Index | Drive Parameter | Default Signal | Description |
|---|---|---|---|
| 0 | r2050[0] | TB30.AO0 (analog output 0) | 12-bit DAC value, normalized |
| 1 | r2050[1] | TB30.AO1 (analog output 1) | 12-bit DAC value, normalized |
| 2..n-1 | r2050[2..n-1] | BI/DI from X483 | Digital input/output state |
You can also enter these mappings through the SCOUT I/O mask: in the TB30 expert list, expand Outputs, then Signal source for analog output 0/1, and select the index that corresponds to the PZD position you want.
Step 3: Determine the Output Address (PQW)
The Control Unit publishes the TB30 PZD slot at a fixed process-data word address. The address is a function of:
- Number of PZDs allocated to the Control Unit's own telegram (e.g. Telegram 391 consumes 4 PZDs).
- Number of PZDs allocated to preceding drive slots (Line Module, Motor Module 1, Motor Module 2, ...).
- TB30's slot position in the configuration list.
To find the TB30's start address, open Control Unit → Communication → Telegram configuration in SCOUT. The address column shows the absolute PQW input/output offset for each slot. The TB30 typically lands at offsets like PQW262, PQW264, PQW266, PQW268 (each PZD word occupies 2 bytes; AO0 sits at the start, AO1 at +2 bytes, then DI/DO words follow).
You can confirm by online monitor:
- Right-click the Control Unit → Connect to target system.
- Open Online → Expert list and filter on
p2050orCU.r2050. - Note the
PZD start addressfield. That is your PQW base.
Step 4: Create an IO Symbol of Type Word
SCOUT needs an IO Symbol to bind a process-data word to your application. The symbol holds the runtime address of the PQW and exposes it to the program editor.
- Open the SIMOTION program source in the project navigator (e.g. ST or MCC unit).
- Switch to the Symbols tab.
- Click Add to create a new IO Symbol. Set:
| Field | Value |
|---|---|
| Name |
ao0_output (or your naming convention) |
| Data type | WORD |
| IO direction | OUT |
| Address | Logical address = TB30 PZD base offset, e.g. 262
|
| Process image | Leave on the default (cyclical I/O update) |
| Assignment | Browse to the TB30 output symbol in the drive tree (newer SCOUT versions) or enter the slot manually |
If you are on SCOUT V4.1 (which does not have the symbolic address assignment feature), the Assignment field is greyed out. You must enter the absolute logical address (the PQW number) directly. The IO Symbol will be bound at compile time to the matching address on the Control Unit, provided the slot map matches what the drive reports online.
Step 5: Copy the Global Variable into the IO Symbol
The IO Symbol is a normal program variable once declared. From any task (MCC, LAD, FBD, or ST), copy your global variable into the IO symbol on every cycle:
// Structured Text example (background task or MotionTask)
PROGRAM _MAIN
VAR
g_setpoint : REAL; // global or unit variable, e.g. -10.0 .. +10.0 V
END_VAR
g_setpoint := g_setpoint; // already global; no copy needed for reads
// Scale -10..+10 V into 16-bit signed word
ao0_output := REAL_TO_INT(g_setpoint / 10.0 * 32767.0);
The mapping is:
-
0x7FFF(32767) → +10 V (or +20 mA depending on switch S1) -
0x0000(0) → 0 V (or 0 mA) -
0x8000(-32768) → -10 V
For MCC users, drop a Box → Output assignment, enter the IO symbol name on the output side, and the global variable or a scaled integer on the input side.
Step 6: Compile, Download, and Run
- Right-click the SIMOTION program → Compile. Resolve any address-conflict warnings.
- Right-click the SIMOTION device → Download to target (project + program + I/O mapping).
- Right-click the SINAMICS drive → Download to target (drive configuration only).
- Set the SIMOTION run mode to RUN (F5 or Run/stop → Start). Without RUN, the IO image is not refreshed and PQW stays at zero — this is the most common cause of "I forced a value, but nothing happens at the terminal."
- Set the SINAMICS drive to Run (enable pulses if needed; outputs to the TB30 are available in Ready state, but the slot only updates when the Control Unit is alive and the telegram is cyclic).
Verification
Use a multimeter on X482 pins 1/2 (AO0) and 3/4 (AO1) to measure the analog level.
| Global Value | Scaled Word (decimal) | Expected Voltage (S1 = V) | Expected Current (S1 = I) |
|---|---|---|---|
| +10.0 | +32767 (0x7FFF) | +10.00 V | +20.00 mA |
| 0.0 | 0 | 0.00 V | 0.00 mA |
| -10.0 | -32768 (0x8000) | -10.00 V | 0.00 mA (live zero) |
| 5.0 | +16384 (0x4000) | +5.00 V | +10.00 mA |
For a closed-loop check, force g_setpoint via the SCOUT variable monitor while the SIMOTION task is running. The measured voltage should track the global value within ±20 mV (12-bit DAC quantisation = ~5 mV typical).
You can also confirm data flow with the SCOUT Trace recorder: add ao0_output and g_setpoint as trace points with a 4 ms sampling rate; the curves should be coincident after scaling.
Troubleshooting Matrix
| Symptom | Likely Cause | Fix |
|---|---|---|
| Output stuck at 0 V, no fault | SIMOTION not in RUN, or IO Symbol address not bound to TB30 slot | Start SIMOTION run mode; verify address in expert list r2050
|
| Output stuck at ~+10 V or near full scale | IO Symbol is IN not OUT; or wrong slot |
Set IO direction = OUT, recompile |
| F0135 "Telegram failure" | TB30 telegram count mismatched vs. project | Match telegram setting in SCOUT and drive online config, re-download |
| F0851 Analog output wire break | Current output selected on S1, but load is open-circuit | Switch to voltage output (S1 off), or wire 0-500 Ω load |
| A/D oscillation on output | Too much update noise or wrong smoothing constant | Increase p4770 (smooth time) to 50-100 ms |
| Forcing PQW in monitor does nothing | IO Symbol is being written by task each cycle, overwriting the force | Force the global variable instead, or stop the task |
| Output correct in SCOUT trace, but wrong on terminal | S1 DIP switch set opposite of p4771 mode |
Verify S1 position matches output type, cycle power |
| Drive goes into offline/comm loss after download | TB30 inserted in wrong slot position (after a non-PZD-capable module) | Move TB30 to the next free addressable slot |
Newer SCOUT Versions: Symbolic Address Assignment
SCOUT V4.2 and later, plus TIA-based SCOUT packages, add a Symbolic address assignment column on the IO Symbol editor. You can browse the drive tree directly to the TB30 PZD slot, select TB30.AO0 or TB30.AO1, and SCOUT resolves the PQW automatically. This eliminates manual address arithmetic when the telegram layout changes.
Workflow:
- Open the IO Symbol editor and add a new symbol of type
WORD, directionOUT. - In the Assignment dropdown, navigate to Drive → CU → TB30 → AO0 and confirm.
- SCOUT inserts the correct logical address and binds the symbol at compile time. No expert-list work needed.
If your firmware does not expose the symbolic nodes, fall back to the manual p2050/PQW method described in Steps 2 and 3.
Edge Cases and Field Notes
Live-zero current outputs (4-20 mA): The TB30 hardware has no native 4-20 mA mode. The current output is 0-20 mA live zero, so a missing 0 V or 0 mA signal cannot be distinguished from a wire break. If your downstream device needs 4-20 mA, add an external resistor (250 Ω in parallel with the load) and offset/scale in software, or use a TB30 alternative like a Phoenix Contact MINI MCR or Wago 857 series signal conditioner on the 0-10 V output.
Output update rate vs. task cycle: The TB30 DAC updates once per 4 ms internally. If your background task runs at 1 ms and writes the same IO symbol, the drive still only updates the analog level every fourth cycle. Use the smoothing time constant p4770 if you need to suppress jitter on the output voltage.
Forcing PQW during commissioning: The SCOUT variable monitor can write PQW directly, but if your task is also writing the IO Symbol the force will be overwritten within one task cycle. To verify the wiring independently of the application, force the global variable the task reads from, or temporarily set the task to STOP.
Watchdog and bus failure: If PROFIBUS/PROFINET between the SIMOTION and the SINAMICS CU drops, the TB30 PZD words will be held at their last value (default) or driven to a safe value (configurable via p2051 fail-safe). If the application requires a defined safe state, set the fail-safe value in p2051[k] on the CU and enable p2050 sign-of-life monitoring.
Multiple TB30 boards: A single CU320 can host more than one TB30 (slot expansion). Each gets its own telegram PZD range; the start address is cumulative. Re-check the address map after inserting a second TB30 — PQW numbers shift by the size of the first board's PZD region.
TB30 vs. TM31/TM15: If you need more analog outputs (TM31 has 2 AO, TM15 has no AO), TM31 is the drop-in upgrade. The IO Symbol and telegram approach is identical, but the TM31 supports bipolar ranges with independent scaling per channel.
Safety and Compliance Checklist
- The TB30 is not safety-rated. For SIL/PL outputs, route via a SINAMICS safety-integrated module or an external safety relay.
- Verify that the output current (max 20 mA into 500 Ω = 10 V) is within the input range of the connected actuator. Excess current will saturate and may damage either the TB30 or the load.
- Confirm ground isolation: the TB30 provides isolation up to 60 V to PE on X482 outputs. Do not exceed this if you have non-isolated downstream electronics referenced to a different ground potential.
- When changing S1 DIP switch positions, cycle 24 V power to the CU/TB30. The firmware reads the switch state only at boot.
FAQ
What Telegram do I select for the TB30 in SCOUT V4.1?
Use a free-PZD telegram such as 999 (free assignment) or a Siemens standard telegram that includes the TB30. If you use standard Telegram 391 on the Control Unit, allocate at least 2 PZD words to the TB30 slot (one for AO0, one for AO1). After configuration, download to the drive and clear any F0135/F0851 faults.
How do I find the PQW start address for the TB30?
Open Control Unit → Communication → Telegram configuration in SCOUT; the address column shows the absolute PQW offset for each slot. Typical values are PQW262-PQW268 depending on the size of preceding slots. You can also confirm by online monitoring CU.r2050 and noting the PZD start address.
Why is my TB30 analog output stuck at 0 V even though I forced PQW262?
Most often the SIMOTION controller is not in RUN, so the IO image is not refreshed and the force is overwritten. Start SIMOTION in RUN mode, then force the global variable the task reads from, or stop the task before forcing PQW directly. Verify the IO Symbol is set to direction OUT and the logical address matches the TB30 PZD slot.
How do I scale a -10..+10 V global variable to the TB30 16-bit word?
Use the formula word = REAL_TO_INT(volts / 10.0 * 32767.0). The mapping is 0x7FFF (32767) = +10 V, 0x0000 (0) = 0 V, 0x8000 (-32768) = -10 V. The TB30 DAC is 12-bit, so the lower 4 bits are truncated; expect ±5 mV quantisation on the output.
Can I use the TB30 analog output in 4-20 mA mode?
No — the TB30 hardware supports 0-20 mA only, with no live-zero (4-20 mA) mode. To get 4-20 mA, scale the global variable into a 4-20 mA equivalent in software and use a 250 Ω resistor to convert 0-20 mA to 0-5 V, or use an external signal conditioner such as a Phoenix Contact MINI MCR module on the voltage output.