AutomateDirectUSAMotion LibraryIndustrial monitors & PCs

Explainer

Turning a Single-Turn Absolute Encoder Into Multi-Turn Position

Sensors, encoders and machine vision on the machine Published 9 min read By AutomateDirectUSA engineering team

Short answer

A single-turn absolute encoder can serve as multi-turn position feedback only while something else tracks shaft revolutions. Count rollovers in software while speed times the worst update gap stays below half a revolution, keep the whole counting chain powered or hold the axis with a brake, decode a travel-zone switch on limited travel, or gear a second single-turn encoder to the shaft with its reduction below the encoder's resolution. If unpowered shaft movement is possible and a reference move is not, use a true multi-turn encoder.

On this page
  1. What a single-turn reading reports, and what it withholds
  2. Counting rollovers in software, and the half-revolution limit
  3. Keep the chain powered, or hold the shaft still
  4. A travel-zone switch on a limited-travel axis
  5. A geared second single-turn encoder for the coarse turns
  6. The decision, case by case
  7. Questions asked

A single-turn absolute encoder can do multi-turn work, but only while something else keeps track of shaft revolutions. The encoder reports position within the turn; the turn count has to come from software rollover counting, from an uninterrupted powered chain, from a travel-zone switch on a limited-travel axis, or from a second single-turn encoder geared to run slower than the shaft. The software route carries one hard limit: the shaft must move less than half a revolution between two readings the controller actually receives. Below are that limit, the arithmetic to check against your own axis, and the decision rule for each route, including the point where the honest answer is a true multi-turn encoder.

What a single-turn reading reports, and what it withholds #

Let N be the number of distinct positions the encoder reports per revolution; take N from the datasheet of the exact part, for example 4096 counts for a 12-bit single-turn encoder. The reading is position modulo one revolution: the same value returns at every complete turn. A controller builds a multi-turn coordinate by carrying a signed turn count t alongside it: position = reading + N × t.

The turn count is state, not a measurement. Retaining it through a power interruption preserves the last value it held; it does not observe any turn the shaft makes while the counting chain is dark. That distinction decides everything below: any route expected to survive an interruption must either guarantee the shaft cannot move unobserved, or take its revolution information from something physical.

Counting rollovers in software, and the half-revolution limit #

The cheapest route is software. Each time the controller accepts a position reading, it subtracts the previously accepted one, and if the raw difference falls outside ±N/2 counts it adds or subtracts N to bring it back. A large negative raw difference that becomes small and positive is a forward crossing of the wrap point; the mirror case is a backward crossing. Each corrected difference is added to the accumulated turn total. This shortest-path unwrap stays valid only while the true motion between accepted readings remains inside the wrap's ambiguity range: at the boundary the direction is ambiguous, and beyond it a shorter move in the opposite direction produces the same pair of readings.

That ambiguity range is half a revolution, so the limit becomes a timing rule:

n_max × gap_max < 0.5 rev

where n_max is the fastest shaft speed in revolutions per second and gap_max is the longest gap between accepted readings, in seconds. Use the worst gap the machine can actually produce, a missed scan, a network retry or a paused task, never the nominal period: a shaft can complete a full revolution inside one gap and hand back an identical reading, leaving no trace that the turn happened. Log the timestamps of accepted updates across a full duty cycle and take the longest interval as gap_max.

Worked example, calculated for these inputs: a 12-bit encoder with N = 4096 counts/rev on an axis whose fastest motion is 1800 rpm, that is 1800 ÷ 60 = 30 rev/s. The controller reads the position word every 2 ms and one missed cycle stretches the worst gap to 4 ms. Movement per worst gap: 30 rev/s × 0.004 s = 0.12 rev, which is 0.12 × 4096 ≈ 492 counts, comfortably below the 2048-count ambiguity boundary. The gap ceiling at this speed is 0.5 rev ÷ 30 rev/s = 16.7 ms, so the 4 ms gap passes with margin. If the same axis goes unread for 50 ms during a network fault, the shaft can cover 30 rev/s × 0.05 s = 1.5 rev unseen, the readings shift by exactly the ambiguity boundary and the decoder cannot say which way the shaft turned. This is a calculated example for these inputs, not a measured result.

The decision: software counting is correct for exactly as long as every gap meets the rule, and it costs nothing but code. Arm a fault whenever a gap exceeds the ceiling and treat that fault as loss of position, never continue on the old count; the alarm-and-recovery pattern for a turn counter that has lost its way is the subject of troubleshooting an absolute encoder multi-turn counter alarm. The update, wrap and validation logic is worked end to end in converting a single-turn absolute encoder to multi-turn via software. If you want the same pattern as runnable code, a single-turn to multi-turn programming walkthrough for one PLC family is the worked example.

Keep the chain powered, or hold the shaft still #

With power continuously applied to the encoder and to whatever receives its position words and accumulates the turns, a single-turn device behaves as a multi-turn one; the whole exposure sits at power loss. Two things break there. The retained count goes stale: it describes the shaft as it was when power dropped, and turns made afterwards are invisible. And backup power has to cover the complete chain, encoder, receiver electronics and the counting logic, because a live encoder feeding a dead controller still loses turns. What a battery does and does not preserve on a servo motor encoder is taken apart in whether servo motor absolute encoders are really battery-backed.

The mechanical alternative is to make unobserved motion impossible: engage a holding brake whenever the controls are off, and the turn count stays honest because the shaft cannot turn. Size the brake for the worst load the axis sees, including gravity and any overhauling load, and plan the stopping travel at shutdown and the release sequence at restart. One boundary: a brake chosen for position retention is a holding device, not a safety function. Where the machine's risk assessment requires a guaranteed safe stop or hold, that comes from the drive's documented safety functions, such as Safe Torque Off as defined in IEC 61800-5-2, which removes power capable of causing rotation, applied according to that assessment.

Validate every restart. A retained coordinate is a hypothesis until the machine shows that nothing moved: the brake held, nobody moved the axis by hand, and no gap ceiling was violated while power remained. When any of those checks fails, rebuild position with a reference move as described in homing an absolute encoder axis to a reference sensor instead of trusting the count.

Decision: this route rides through interruptions only when you can demonstrate that the chain never went dark or the shaft never turned, and you monitor both conditions continuously. When unpowered movement is possible and a reference move is not acceptable, make the comparison against a purpose-built part: when to specify a mechanical multi-turn encoder instead of a battery-backed one frames that choice.

A travel-zone switch on a limited-travel axis #

On a linear axis whose travel spans about one revolution of the measuring shaft, the single-turn reading repeats exactly once, so one binary switch can separate the two physical regions that share each reading. Run the switch off along the first half of travel and on along the second, and the pair of switch state and encoder reading identifies position without counting revolutions at all.

Worked arrangement, quoted as one geometry to take the decode logic from, not a universal decoder: with a nominal 4096-count wrap, the switch comes on above a reading of 4000. Inside the crossover band the controller subtracts the wrap from high readings whenever the switch is on: a reading of 4050 with the switch on means 4050 - 4096 = -46 counts relative to the chosen center, the point where switch-on and a reading of zero marks the middle of travel. The 96 counts between 4000 and the wrap are spent on disambiguation, and the arrangement uses only about half of the second pass through the readings.

Two checks make it trustworthy. The switch's full transition, hysteresis, actuator overtravel and contact bounce included, must sit inside the band the decoder handles, so prove it by slow travel across the transition in both directions and confirm that every permitted combination of switch state and reading occurs at exactly one physical location. The decode also covers the encoded travel only: move the carriage beyond it and the pair maps to nothing, or to a wrong location, without announcing the fact.

Decision: use a zone switch on limited-travel axes where a startup reference move is unwanted but travel always stays inside the encoded range. It buys absolute position over that range and no further.

A geared second single-turn encoder for the coarse turns #

Fix a second single-turn absolute encoder to the shaft through a gear so it turns slower. Its reading is the coarse revolution count, and because the relationship is mechanical, gear teeth rather than memory, the pair survives power loss intact: one read of both encoders at power-up rebuilds position without a reference move.

The sizing rule: if the coarse shaft makes one revolution per k revolutions of the main shaft, k must stay below the coarse encoder's counts per revolution N_c. One main-shaft turn advances the coarse reading by N_c ÷ k counts, and the turn number is readable only while that is at least one count. Worked example, for these inputs: a 10:1 reduction, so k = 10, with a 1024-count coarse encoder, advances the coarse reading 1024 ÷ 10 = 102.4 counts per main-shaft turn. Every fine reading then sits inside a unique coarse step, the pair distinguishes 10 × 1024 = 10,240 main-shaft positions, and the coordinate wraps again after 10 turns unless another stage is added.

Backlash and tooth error shift the coarse-to-fine correlation. Keep the total angular error well inside one fine revolution and prove it on the machine: rotate the main shaft through one coarse count step and back, and check that both readings return to their starting values.

Decision: this is the principle a factory-built geared multi-turn encoder applies in one housing, assembled here from two single-turn parts. Choose it when position must return by itself after power-off and you accept the gearing, alignment and backlash work that keeps the pair correlated; buy the factory-built part when that maintenance is unattractive.

The decision, case by case #

Route Revolution information comes from Survives Hard limit
Software rollover counting Consecutive readings, wrapped difference Continuous powered operation The half-revolution timing rule between accepted readings
Backup power or holding brake The powered chain, or no motion at all Interruptions that keep the chain live or the shaft still Zero unobserved displacement, verified at every restart
Travel-zone switch Carriage region plus shaft angle Power-off, inside the encoded travel One clean transition band per wrapped region
Geared second encoder The gear mesh between two single-turn encoders Power-off, across the geared range k below N_c, correlation error inside one fine revolution

Pick by what must happen across a power loss:

  • Homing after every interruption is acceptable and the speed-versus-gap arithmetic holds: software rollover counting, with the gap ceiling armed as a fault.
  • The axis must ride through power dips without losing position: backup power across encoder, receiver and counting logic, or a brake that provably holds the shaft, with retention checked at every restart.
  • Limited travel and no reference move wanted: the zone switch, decoded across its full transition band.
  • Position must reappear by itself after unpowered movement: a geared pair you build and maintain, or a factory-built mechanical multi-turn encoder. When turns must be measured rather than assumed, the true multi-turn encoder is the only component here that does it.

Questions asked

If power was off but the shaft did not move, is the encoder position still valid?

Yes, with the emphasis on proof. The reading itself is absolute within the turn and does not fade, so the retained turn count plus the current reading remains correct if the shaft provably stayed still, held by a brake or verified by hand. Position is lost only when the shaft turns while the powered counting chain is dark, or when a controller gap lets the ambiguity boundary be crossed between two accepted readings.

How fast can a software turn counter track the shaft?

Divide the half-revolution boundary by the longest gap between accepted readings. With a 5 ms worst gap the ceiling is 0.5 rev / 0.005 s = 100 rev/s, about 6000 rpm. With a 20 ms gap it is 25 rev/s, about 1500 rpm. Use the longest gap the controller can really produce, including retries and scan overruns, and arm a fault whenever the interval is exceeded.

Is a battery on the encoder enough to keep multi-turn position?

No. The battery keeps the encoder electronics alive, but the device that receives the position words and accumulates rollovers loses the count the moment its own power drops. Every element of the chain, encoder, receiver and counting logic, has to stay powered for the whole interval. That is why battery-backed multi-turn encoders put the retention inside one sealed unit and publish a battery service life that must be scheduled.

What happens if someone moves the axis by hand with the controls off?

Every route built on a retained count or a powered chain loses the turns, because hand movement leaves no electrical trace. A zone-switch decode also fails once the carriage leaves its encoded range. If the machine allows unpowered movement and position must still be correct at power-up, the fix is physical: a mechanical multi-turn encoder, a geared pair of single-turn encoders, or an accepted reference move at every startup.

Keep reading

  • How-to

    How to Identify Geared Resolver and Encoder Feedback on Old Servos

    Treat the resolver plus its geared 1:4 and 1:80 channels as one integrated coarse-and-fine, multi-turn position package: the resolver reads absolute angle within one shaft revolution, and the geared channels count revolutions above it. Identify each channel by resistance checks, ratio counting and waveform capture before choosing a replacement drive, because the resolver model number alone establishes neither commutation nor multi-turn position recovery.

    Sensors, encoders and machine vision on the machine

  • Explainer

    Reading a Gray Code Absolute Encoder Into a PLC

    A five-line NPN absolute encoder needs no interface module: wire its five open-collector outputs to ordinary DC input points, read all five bits as one word each scan, and convert Gray code to binary before using the number. The catch is speed — scan-based sampling tracks a 32-position shaft reliably only below roughly half a revolution per second, so continuous multi-turn conveyor tracking belongs on a quadrature encoder and a high-speed counter with a home reference.

    Sensors, encoders and machine vision on the machine

  • Explainer

    Using a Resolver as Absolute Position Feedback After Power-Off

    Yes, conditionally. A resolver is absolute within one electrical cycle, so it recovers the shaft angle after power-off without a battery, but with R motor revolutions per table revolution the feedback repeats every 360/R degrees of table travel. A turntable whose stroke crosses that period must home at startup or add multiturn feedback.

    Sensors, encoders and machine vision on the machine