Fareed Mohmed · Engineering
Machine Wiring Guide
Cable · Connect · Ground · Protect · Check
Pick the device you are wiring (servo, stepper, AC induction motor, VFD, DC motor, brake, solenoid valve, sensor, analog signal, light curtain, or a start/stop control circuit with a PLC), enter a few numbers, and get a colour-coded wiring diagram with numbered steps showing how to connect it, the cable size and type, brands that make it, what goes on each terminal, the protection, and the grounding rules that keep a machine running without noise trips. Print the sheet or copy it into an email.
This is a guide for first decisions. Terminal names, pin numbers and wire colours differ between makers, so the motor and drive manuals decide the final wiring. Cable sizes follow stated rules (current, derating, voltage drop) and cable products are typical examples: check the datasheet. A qualified person must review the wiring before it is energised.
Choose the device
Cable sizes and derating
The table the tool uses: PVC insulated copper, three loaded conductors, conduit on a wall (IEC 60364-5-52 method B2), 30 °C. It is the same table as the Electrical Circuit Builder. The tool divides the design current by the factors on the right.
| mm² | A at 30 °C | A at 40 °C | A, 3 bundled | A, 40 °C and 3 bundled | Min. PE (mm²) |
|---|
| Ambient | Factor |
|---|
| Cables bundled | Factor |
|---|
Conductors inside multicore control and sensor cable carry less: the tool uses 1 A (0.14 mm²), 2 A (0.25), 3 A (0.34), 4 A (0.5), 6 A (0.75), 8 A (1.0) and 11 A (1.5). A drag chain takes a further 0.85. Voltage drop uses 0.0222 Ω mm²/m. The PE conductor is the phase size up to 16 mm², 16 mm² for 25 and 35 mm², and half above that (IEC 60364-5-54). Flexible PUR, high-temperature and cables in other installation methods have their own ratings: use the datasheet of the cable you buy.
Cable types and brands
What each type is for, what to ask for, and typical products. The names are examples, not an approval: confirm the datasheet and local stock.
| Type | Used for | What to ask for | Lapp (incl. Lapp India) | Helukabel | Igus | Belden | Indian makers and stock |
|---|
Colours, pinouts and ferrules
Control panel wire colours (IEC 60204-1)
| Colour | Use |
|---|---|
| Black | AC and DC power circuits (main circuits) |
| Red | AC control circuits |
| Dark blue | DC control circuits |
| Orange | Interlock circuits supplied from an external source (stay live with the main switch off) |
| Light blue | Neutral |
| Green / yellow | Protective earth (PE) only |
Sensor colours and connector pins (IEC 60947-5-2)
| Colour | Function | M8 3-pin | M12 4-pin | M12 5-pin |
|---|---|---|---|---|
| Brown | +24 V | 1 | 1 | 1 |
| White | Second output (NC) or auxiliary | - | 2 | 2 |
| Blue | 0 V | 3 | 3 | 3 |
| Black | Output (NO, or IO-Link C/Q) | 4 | 4 | 4 |
| Grey | Device-specific (class B: L− aux) | - | - | 5 |
Solenoid valve plugs, servo connectors and light curtain connectors are not standardised in this way: use the maker's pinout.
Cable end ferrule colours (DIN 46228-4)
| mm² | 0.25 | 0.34 | 0.5 | 0.75 | 1 | 1.5 | 2.5 | 4 | 6 | 10 | 16 |
|---|---|---|---|---|---|---|---|---|---|---|---|
| Colour | Yellow | Turquoise | White | Grey | Red | Black | Blue | Grey | Yellow | Red | Blue |
Some makers use other colours (for example an orange 0.5 mm² ferrule): check the box. Use a ratchet crimp tool matched to the ferrule, and never put two wires into a single-wire ferrule.
Good wiring practice
Separate noisy and quiet cables
Motor, drive output, brake and contactor cables are noisy. Sensor, analog, encoder, fieldbus and safety cables are quiet. Keep them in different ducts or trays, or at least 200 mm apart, with a metal divider if they must share a tray. Where they must cross, cross at 90°. Servo motor cables and encoder cables never share a duct.
Screens: where to connect them
Motor and drive output cables are screened to keep high-frequency noise in: bond the screen 360° to bare metal at both ends, with an EMC gland or clamp, not a pigtail. Analog and low-frequency sensor signals are screened to keep noise out: bond the screen at the cabinet end only, so no current flows through the screen from ground differences along the machine. If the maker's manual says otherwise, follow the manual.
Earthing and the mounting plate
Mount drives and filters on an unpainted (bright or galvanised) panel and connect the panel to the PE bar with a short, wide link. Every motor needs its PE conductor inside the cable and a bond from its frame to the machine frame. Use star-point earthing to the PE bar rather than a daisy chain of PE wires.
Drag chains and moving cables
Use cable made for flexing (class 6 conductors, PUR sheath). Bend radius is set by the datasheet: typically 4 to 6 × the cable diameter for fixed flexible, about 7.5 × for occasional movement, and 10 to 15 × for a drag chain. Separate cables in the chain with dividers, do not bundle them tight, keep them free to move, and strain-relieve both ends so the bending never reaches the terminal.
Terminals, ferrules and labels
Fit a ferrule on every stranded wire, strip to the length the terminal needs, and tighten to the torque on the terminal. Number every wire at both ends and match the numbers to the drawing. Use a cable gland of the right size so the cable is held and the enclosure keeps its IP rating.
Test before power
Check continuity of each wire and each screen, insulation resistance of motor cables (500 V DC, with the cable disconnected from the drive), and polarity of 24 V circuits. Bring the machine up in stages: control power, then safety, then low-speed motion with the E-stop within reach.
How it works
Sizing rules
For each cable the tool finds the smallest area that passes the current check (1.25 × rated current, divided by the derating factors, looked up in the table) and the voltage drop check, and then applies the minimum size for the job. It reports all three and which one governed, so you can see why the answer changed when you changed the length or the temperature.
Estimating motor current
When you do not know the nameplate current of an AC motor, the tool uses typical efficiency and power factor for the size (the same values as the Electrical Circuit Builder). Always replace it with the nameplate value when you have it.
Protection numbers
Breaker sizes are about 2.5 × motor current for a direct-on-line start so that the starting current is let through. Contactors are chosen from the AC-3 ratings, and the overload relay is set to the motor current and must not exceed what the cable carries. Use the Electrical Circuit Builder motor selector for a full starter. Drive input protection comes from the drive manual.
Related tools
See how to wire each field device to the PLC, with photos, in Field Device to PLC Wiring. Size the motor with the Servo Motor Sizing or AC Induction Motor Selector tools, pick the sensor with the Sensor Selector, draw the circuit in the Electrical Circuit Builder, and find the safe distance for a light curtain in the Safety Fence System tool.
What is not covered
Short-circuit rating and fault protection of cables, discrimination, earth-fault loop impedance, harmonics, power factor correction, hazardous areas, fieldbus and Ethernet cabling, and the exact pinout of any maker's motor, drive or light curtain connector. Motor-maker pinouts for Mitsubishi, Yaskawa, Siemens and Panasonic servo systems are not yet in the tool. Safety circuits must be designed and validated to ISO 13849 and IEC 60204-1.
User manual
Tap a chapter to open it. The buttons marked Load this example fill the form above with the example.
1. What this tool does and does not do
You pick a device (servo motor, stepper, AC induction motor, DC motor, brake, solenoid valve, sensor, analog sensor, light curtain), enter a few numbers, and get a wiring guide: a colour-coded wiring diagram with numbered steps (how to connect it), cable size, cable type, typical cable products by maker, terminal-by-terminal connections, protection and supply, grounding and EMC rules, and a power-up checklist. A print or PDF sheet comes with it.
It is a guide, not a replacement for the maker's manual. Terminal names, pin numbers and wire colours differ by maker; where they differ the tool tells you to use the manual. The cable sizes come from simple, stated rules (current with derating, voltage drop, minimum size). Cable product names are typical examples. Always check the current datasheet.
Who it is for: freshers learning how a machine is wired, and the Merlin design team making a quick, consistent wiring decision before the panel drawing.
2. Quick start: wire a servo axis (2 minutes)
- Press the button below. It selects Servo motor and fills in a 6 A servo, 15 m from the drive, in a drag chain, with a brake and STO.
- Read the verdict at the top: the power cable, 4G1 mm² (3 power cores + PE of 1.0 mm²), screened, drag-chain rated.
- Open How the size was chosen. The tool shows the design current, the derating, and the voltage drop check.
- Read the Connections table and the Wiring and grounding rules.
- Change the length to 80 m or the ambient to 55 °C and watch the size and the warnings change.
- Press Print / save as PDF to get a one-page sheet, or Copy as text for an email.
Check by hand: design current 1.25 × 6 A = 7.5 A. Derating: ambient 40 °C × 0.87 and drag chain × 0.85 gives 7.5 ÷ (0.87 × 0.85) = 10.1 A. The smallest area that carries 10.1 A in the table is 1.0 mm² (11 A). The 15 m voltage drop is √3 × 15 × 6 × 0.0222 ÷ 1.0 = 3.5 V, well under 3 % of 400 V (12 V). So 1.0 mm².
3. The page
01 Choose the device. Ten buttons: the nine devices and the start/stop control circuit. The form under them changes with the device. Everything updates as you type. 02 Cable sizes and derating is the table the tool uses. 03 Cable types and brands, 04 Colours, pinouts and ferrules and 05 Good wiring practice are reference sections you can read on their own. 06 How it works lists the rules and the limits.
Result layout. Verdict (what to buy), warnings in red, how to wire it (wiring diagram and steps), cable overview, cables table, how the size was chosen, connections table, optional terminal-box figure, protection and supply, wiring and grounding rules, typical cable products, and the power-up checklist.
Print / save as PDF. Prints only the result sheet in black on white. In the print window choose “Save as PDF”. Copy as text copies a plain-text version.
4. How the cable size is chosen
Three checks, and the largest answer wins. The tool tells you which one governed.
- Current. Design current = 1.25 × rated current. It is divided by the derating factors: ambient temperature (30 °C = 1.00, 40 °C = 0.87, 50 °C = 0.71), cables bundled together (2 = 0.80, 3 = 0.70, 6 = 0.57, 9 = 0.50) and, in a drag chain, 0.85 (the tool's own allowance). The result is looked up in the current table (PVC copper, three loaded conductors, conduit on a wall, 30 °C; the same table as the Electrical Circuit Builder). Thin conductors in multicore cable use more conservative values.
- Voltage drop. Drop = √3 × L × I × 0.0222 ÷ area for three phase, 2 × L × I × 0.0222 ÷ area for DC and single phase (0.0222 Ω mm²/m is copper at about 70 °C). Limits: 3 % for motors, 4 to 5 % for brakes, valves and light curtains, 10 % for sensors.
- Minimum size for the job (for example 0.75 mm² for a servo power cable, 0.5 mm² for a brake).
Check by hand: long cable. A 7.5 kW motor at 415 V draws about 13.8 A. At 30 m it needs 2.5 mm² (1.25 × 13.8 = 17.2 A, and 2.5 mm² carries 21 A). At 80 m the drop in 2.5 mm² is √3 × 80 × 13.8 × 0.0222 ÷ 2.5 = 17 V, above 3 % of 415 V (12.5 V), so the size becomes 4 mm². The tool reports “governed by voltage drop”.
Limits. The tool uses one table for all cable constructions. Flexible PUR cables, high temperature cables and cables in other installation methods have different ratings: confirm with the datasheet of the cable you buy. The drop calculation ignores reactance. Short-circuit withstand, grouping with different currents and harmonics are not checked.
5. Servo and stepper motors
Servo. Enter the rated current, voltage class, length, installation, brake, feedback type, and whether STO is used. You get a power cable (screened, 600/1000 V), a brake pair, a feedback cable and an STO cable, each with its own rule. The feedback cable and the power cable must not share a duct. Never swap U, V and W on a servo to reverse it.
The encoder 5 V supply is checked for voltage drop: 0.2 A over 15 m with a 0.2 V limit needs about 0.67 mm² of total supply conductor, which is why the maker's cable parallels cores or adds sense lines. Pin numbers and colours are not given because they differ by maker (Mitsubishi, Yaskawa, Siemens, Panasonic and others); the tool says so and sends you to the manual.
Stepper. Enter the current you set on the drive, the supply voltage and the lengths. The motor cable is two twisted pairs, screened. The tool also tells you how to find the windings, how a 4-, 6- and 8-lead motor is connected, and never to connect or disconnect the motor with the drive powered.
Example check (stepper): 4 A needs 1.25 × 4 = 5 A, which is 0.75 mm² (6 A in the thin-conductor table).
6. AC induction motors and VFDs
Enter power, supply voltage, the motor nameplate voltage, the starting method and the length. If you leave the nameplate current at 0 the tool estimates it from power, voltage and a typical efficiency and power factor (7.5 kW at 415 V gives 13.8 A, the same as the Electrical Circuit Builder).
- DOL: one cable, plus the breaker, contactor and overload sizes. The terminal box links (star or delta) are drawn for your supply voltage and nameplate.
- Star-delta: six leads from the starter to the motor, each sized for 58 % of the line current. The tool refuses a combination that cannot work (a 230/400 V motor cannot be started star-delta on 400 V).
- VFD: symmetrical screened cable, screen bonded 360° at both ends, with warnings for cable length (over 50 m and over 100 m), supply of 500 V or more (inverter-duty insulation) and 55 kW or more (bearing currents).
Check by hand: star-delta 15 kW, 400 V. Current 27.7 A. Supply cable: 1.25 × 27.7 = 34.6 A, so 6 mm² (36 A). Each motor lead carries 0.58 × 27.7 = 16.1 A, and 1.25 × 16.1 = 20.1 A gives 2.5 mm² (21 A). Breaker 2.5 × 27.7 = 69 A gives an 80 A MCCB; contactors 32 A (K1), 18 A (K3), 12 A (K2).
Check by hand: VFD 22 kW, 400 V, 60 m. Current 39.7 A, 1.25 × 39.7 = 49.6 A gives 10 mm² (50 A). Drop √3 × 60 × 39.7 × 0.0222 ÷ 10 = 9.2 V (2.3 %), inside the 3 % limit.
7. DC motors and holding brakes
DC motor. Choose brushed or BLDC, voltage, power and efficiency (or the rated current). Low-voltage DC is limited by drop, not current. The tool also sizes the fuse (at least 1.25 × rated current, and never above what the cable can carry), warns about stall current and regeneration, and lists the Hall sensor cable for a BLDC motor.
Check by hand: 24 V, 200 W, 75 %. I = 200 ÷ (24 × 0.75) = 11.1 A. Current alone: 1.25 × 11.1 = 13.9 A gives 2.5 mm². A 5 m run at 2.5 mm² drops 2 × 5 × 11.1 × 0.0222 ÷ 2.5 = 0.99 V, above 3 % of 24 V (0.72 V), so the cable becomes 4 mm².
Holding brake. Brake power ÷ voltage gives current; the limit is 4 % drop because a brake that does not release fully overheats or drags. The tool reminds you to measure the voltage at the brake.
8. Solenoid valves
Choose the coil voltage and power, the number of valves on at once, the length, the controller output type and the connector. You get a valve cable (each), a common feeder, the fuse, the output rating check and the suppression advice.
Check by hand: eight 24 V, 2.5 W valves, 20 m. One valve draws 2.5 ÷ 24 = 0.104 A, all eight 0.83 A. A 5 % drop of 24 V is 1.2 V: the feeder needs 2 × 20 × 0.83 × 0.0222 ÷ 1.2 = 0.62, so 0.75 mm². Each valve cable is 0.34 mm² (the minimum). Fuse 1.25 × 0.83 = 1.04 A gives 1.6 A.
The tool warns when a valve takes more than 80 % of an output, when an AC coil is on a DC transistor output, and when a relay switches a DC coil.
9. Sensors, analog signals and light curtains
Digital sensors. Choose the output type (3-wire PNP or NPN, 2-wire, 4-wire, IO-Link), the connector and length. You get the colour and pin for each wire, the input compatibility check (PNP to a common 0 V input, NPN to a common 24 V input), the 2-wire leakage warning and the routing rules.
Analog. For 4-20 mA the tool works out the loop budget: (supply − transmitter minimum) ÷ 20 mA − input resistance. 24 V, 12 V and 250 Ω give 350 Ω for the cable, which at 0.5 mm² is about 3.9 km. For Pt100 it shows lead resistance and error, for thermocouples the extension cable rule, and for load cells the 6-wire connections. Screen to PE at the cabinet end only.
Safety light curtain. Enter the type, the supply current, the length, what it connects to, the restart and EDM. The tool gives the dedicated PELV supply, the screened cables, the two-channel connections, EDM and reset wiring, and warnings (Type 2 limit, automatic restart, contactors directly on the outputs). The safe distance is not calculated here: use the Safety Fence System tool (ISO 13855).
Check by hand: light curtain 0.5 A, 30 m. 5 % of 24 V is 1.2 V: 2 × 30 × 0.5 × 0.0222 ÷ 1.2 = 0.56, so 0.75 mm².
10. Cable types and brands
The tool describes each cable by what it must do (screened, drag-chain, 600/1000 V, twisted pair) and lists typical products by Lapp (including Lapp India), Helukabel, Igus, Belden and Indian makers (Polycab, Finolex, RR Kabel, KEI, Havells). Sensor cordsets are from Murrelektronik, Phoenix Contact, Turck, Balluff and others. Section 03 of the page has the whole table.
The names are examples of each type, not an approval. Check the datasheet for the number of cores, screen coverage, bend radius, voltage rating, current rating and sheath material, and check what the supplier stocks near you. Where a servo or drive maker sells a ready-made cable, use it.
11. How to wire it: reading the wiring diagrams
Under every verdict the tool draws a wiring diagram and gives numbered steps in the order to do the work. The diagram is drawn for the choices you made: a VFD gives a different drawing from a direct-on-line starter, a PNP sensor from an NPN sensor, and a servo with a brake and STO from one without.
- Boxes are the devices (supply, drive, motor, PLC, sensor, relay). The small circles on their edges are the terminals, with the names you will find on the real device.
- Wires join the terminals. Colours are the usual ones: brown, black and grey for L1, L2 and L3, blue for neutral or 0 V, red for +24 V, green and yellow for PE, orange and white for signals, violet for feedback and thermistors. A dashed line is a screen. The key under the drawing lists the colours used.
- Terminal names differ by maker. The drawing shows which signal goes where. The drive, PLC or sensor manual gives the exact terminal, so read the terminal name in the manual against the signal in the drawing.
- On a narrow screen the drawing scrolls sideways.
The steps start with isolation, then power, then motor, then feedback and signals, then the tests. They include the common traps: PNP and NPN, motor leads, brake polarity, STO links, screens, and star-delta crossings.
Check by hand: star-delta. The delta contactor connects U1 to W2, V1 to U2 and W1 to V2. In the drawing, the delta contactor's load side goes L1 to W2, L2 to U2 and L3 to V2 because U1, V1 and W1 are already on L1, L2 and L3.
12. Start and stop control circuit
This page is for the circuit in the second picture on many wiring sites: a start button, a stop button, a PLC and a contactor driving a motor. Enter the motor power, the supply, the starter (one direction or reversing), the PLC output type (transistor or relay) and the coil voltage.
- Inputs. +24 V goes through the START button (normally open) to input X0, and through the STOP button (normally closed) to input X1. The normally closed STOP means that a broken wire stops the machine.
- Outputs. A relay output can switch a small contactor coil directly. A transistor output is about 0.5 A, so it switches an interposing relay and the relay switches the coil.
- Reversing. Two contactors with an electrical interlock (each coil is fed through the other's normally closed contact) and a mechanical interlock. The second drawing shows the power circuit, where KM2 swaps two phases.
- Also given: motor current, contactor, overload setting and breaker for the motor power you entered, and the control cable.
Check by hand. 5.5 kW at 400 V is about 11 A. The contactor is the smallest AC-3 size above it (12 A). The overload is set to the nameplate current, not the top of its range.
13. Common mistakes
- One cable for power, brake and encoder. Use a hybrid cable only if the maker designed it with separate screened pairs.
- Pigtail screens. A screen connected with a long wire does not screen. Use a 360° clamp on bare metal.
- Screen at both ends on an analog signal. Screen at the cabinet end only, unless the instrument maker says otherwise.
- Thin 24 V cables on long runs. The voltage at the far end drops below the limit; check the drop.
- Swapping servo phases to reverse direction. Use the direction parameter.
- PNP sensor on an NPN input. It looks wired correctly and never works.
- Welding a PE connection to a painted panel. The EMC contact must be bare metal.
- Using the nameplate kW instead of the current. Size cables from current.
14. What is not covered
Short-circuit rating of cables and fault protection, discrimination, earth-fault loop impedance, cables in conduit with many bends, high ambient or buried installation, harmonic loading of neutrals, power factor correction, hazardous areas, fieldbus and Ethernet cabling, and the exact pinout of any maker's connector. Safety circuits must be designed and validated to ISO 13849 and IEC 60204-1. A qualified person must review the wiring before it is energised.
What's new
- v2 · 11 Oct 2026
Added How to wire it: a colour-coded wiring diagram and numbered wiring steps for every device (servo, stepper, direct-on-line, star-delta, soft starter and VFD motors, DC and BLDC motors, brake, valve, digital and analog sensors, light curtain), drawn for the options you choose. Added the Start / stop control circuit page (buttons, PLC input and output, interposing relay, contactor, reversing starter with interlock). The old connection sketch is now called Cable overview. - v1 · 11 Oct 2026
First release: nine devices (servo, stepper, AC induction with DOL, star-delta and VFD, DC motor, brake, solenoid valve, digital sensor, analog sensor, light curtain), cable size by current, derating and voltage drop, cable types with Lapp, Helukabel, Igus, Belden and Indian makers, connections, protection, grounding rules, connection diagram, print or save as PDF, and this manual.