In short. AMF and ATS logic turns source measurements and breaker positions into start and transfer decisions. Good logic is a clear state machine with qualified inputs, timeouts, interlocks and alarms in every state. In practice the most common failure is not bad logic but a system left in the wrong mode, such as MANUAL or OFF after maintenance. The design must make that impossible to miss.
Who this page is for: For control engineers, panel builders and facility teams designing, programming or troubleshooting mains-failure and transfer logic.
Key facts
- Inputs: utility and generator voltage, frequency and sequence; breaker positions; mode selector; protection and lockout signals.
- Each state has an entry condition, an exit condition and a timeout.
- Qualify inputs with delays so short dips do not start the set.
- Interlock mains and generator breakers in hardware and in logic.
- A failed sequence goes to a fault state needing a manual reset, with an alarm.
- Alarm loudly whenever the system is not in AUTO.
States
| State | Entered when | Left when |
|---|---|---|
| Normal on utility | Utility healthy | Utility out of limits for the set time |
| Starting | Start command | Set running, or start fails |
| Warm-up and stabilise | Set running | Voltage and frequency acceptable |
| Transfer | Generator acceptable and interlocks clear | Breaker feedback confirms transfer, or transfer times out |
| On generator | Transfer complete | Utility healthy for the return time |
| Retransfer | Return confirmed | Transfer complete |
| Cool-down | Set off load | Timer ends |
| Fault or lockout | Protection or failed sequence | Manual reset |
See state machines and sequences.
Worked example: the outage that found the mode switch (illustrative)
| Time | What happened | Why |
|---|---|---|
| Saturday | Generator serviced; selector turned to MANUAL for testing | Normal practice |
| Saturday | Technician left; selector not returned to AUTO | No “not in AUTO” alarm |
| Tuesday night | Utility failed; set did not start | Logic correctly ignored the failure in MANUAL |
| After | “Not in AUTO” alarm to SCADA and a flashing beacon; handover checklist step added | Mode is now visible |
The logic worked exactly as written. The design failed because a wrong mode was silent. A second change made the controller fall back to AUTO after a set maintenance timeout unless held in MANUAL by a key. Work on the set itself still needs the starting circuit isolated and locked off, because a set in AUTO can start without warning.
Do not allow a generator system to sit in MANUAL, TEST or OFF without an alarm someone will see. A silent wrong mode turns the next outage into a blackout.
Qualifying inputs
- Utility failure confirmed after a delay; return confirmed after a longer one.
- Generator acceptable only when voltage and frequency stay in limits for a set time.
- Breaker position from auxiliary contacts, checked against the command; a mismatch is a fault.
Interlocks
Mains and generator breakers must never close together unless a closed-transition scheme with synchronising is designed. Use mechanical and electrical interlocks as well as logic. See interlocking and permissives and breaker interlocking. The neutral switching choice follows the earthing study.
Logic review sheet
| State | Timeout | Fault action | Alarm |
|---|---|---|---|
| Starting | |||
| Warm-up | |||
| Transfer | |||
| Retransfer |
Worked example: how long the load is without supply (illustrative)
Every timer in the sequence adds to the break the load sees. For a standby set with an open-transition changeover:
| Stage | Typical setting or duration | Running total |
|---|---|---|
| Confirm the mains failure | 3 s | 3 s |
| Crank and run up to speed | about 5 s | 8 s |
| Voltage and frequency stable | about 3 s | 11 s |
| Open-transition pause before closing onto the generator | about 1 s | about 12 s |
Codes for life-safety supplies often require restoration within about 10 seconds, which this sequence misses. Shortening it means a shorter mains-confirm time, faster-starting and pre-heated engines and a shorter stabilising time, each with its own risk of starting on brief dips or loading an unsettled set. Where a load cannot tolerate the break at all, a UPS bridges it; the AMF sequence is then sized for the UPS autonomy, not for the load.
Qualifying the supply: thresholds and hysteresis
| Condition (illustrative) | Declare failed when | Declare healthy when |
|---|---|---|
| Undervoltage, any phase | Below about 80% for 3 s | Above about 90 to 95%, all phases |
| Overvoltage | Above about 110% for 3 s | Below about 105% |
| Frequency | Outside about 47.5 to 52 Hz | Back within about 49 to 51 Hz |
| Phase loss or reversal | Immediately, after a short filter | Correct sequence, all phases present |
| Return to mains | Not applicable | Healthy continuously for about 5 minutes |
The gap between the fail and healthy levels stops the logic chattering on a supply that hovers near one threshold, and the long return timer stops it transferring back onto a grid that is still recovering. Check the generator side the same way: phase sequence in particular must be proved after any work on the set or its cables, or the first transfer reverses every motor on the board.
What the logic does when something goes wrong
| Failure | Response |
|---|---|
| Set fails to start after the permitted attempts | Fault state, alarm, call a standby set if fitted |
| Mains breaker fails to open | Block the generator close, alarm; never close into a possible parallel |
| Generator breaker fails to close | Fault state, alarm; load stays off until reset or manual action |
| Set trips while on load | Open the generator breaker, alarm; transfer back if mains is healthy |
| Mains returns during the start | Complete the start, keep the load on mains, run the set unloaded for cool-down |
| Mains fails again during cool-down | Transfer straight back to the running set |
Each row is a test case. A panel whose logic has only been tested for a clean mains failure and a clean return has not been tested for the events that cause most callouts.
The pause between sources for motor loads
When a board carries large motors, switching straight from one source to the other can close onto motors still generating a voltage that has drifted out of phase. A short pause in the open position, typically 1 to 3 seconds, or a residual-voltage check, lets that voltage decay first. The same applies on retransfer. Set the pause from the motors actually connected, and see main-tie-main transfer control for the decay calculation.
Test modes that cannot be left on
- Off-load test: starts and runs the set without transferring, returning to standby after a fixed time.
- On-load test: transfers the load to the set for a fixed time, with automatic return if anything goes wrong.
- Simulated mains failure: opens the mains sensing so the whole sequence runs as in a real outage.
- Timed exit: every test mode ends on its own and returns to AUTO, with an alarm while any test mode is active.
What the controller should record
Each mains failure and return with time and duration, every start attempt and its result, every breaker command and the feedback that followed, every mode change and who made it, and every alarm. With these, a failed transfer can be reconstructed in minutes, and a trend such as a slower start each month or an increase in brief mains dips can be seen before it causes an outage. Download and keep the log after each event and at every service visit.
Commissioning the AMF panel
| Check | Pass when |
|---|---|
| Mains sensing on each phase, by removing one phase at a time | Failure declared after the set delay for every phase |
| Phase sequence of mains and generator | Identical, proved with a rotation meter or the controller display |
| Mechanical and electrical interlock | Both breakers cannot be closed together by any route |
| Full mains failure on load | Transfer time recorded and within the requirement |
| Return to mains | Return timer, retransfer and cool-down as set |
| Each failure case in the table above | Response as designed, alarm raised |
| Not-in-AUTO alarm | Reaches the operator or SCADA in every non-AUTO mode |
Neutral switching follows the earthing
Whether the changeover switches the neutral, with four-pole breakers or switches, is decided by the earthing arrangement of the mains transformer and the generator, not by the controller. Where each source is earthed at its own star point, the neutral is switched so neutral current cannot return through both earth links and confuse earth-fault protection. Where one common neutral-earth link serves both sources, three-pole switching is normally correct. The AMF logic then simply drives whichever arrangement the earthing design specifies.
Exercising the set without wet stacking
A weekly off-load run proves the set starts, but long running at very light load lets unburnt fuel and carbon collect in the exhaust and cylinders. Keep off-load runs short, and plan on-load runs or a load-bank test at a meaningful load, commonly 30% or more of rating, often enough to burn the deposits off. The AMF test schedule is where this belongs.
Alarms that leave the plant room
At minimum, send three signals to someone who will act on them: not in AUTO, generator fault or failed start, and running on generator. A text message or SCADA alarm for each turns a silent problem into a call the same day.
The handover checklist that prevents the silent wrong mode
Every service visit should end with the same short checklist, signed by the technician and the site: selector in AUTO, no alarms active, breakers racked in and charged, fuel above the minimum, starting battery and charger healthy, test modes ended, and a note of the time the panel was returned to service. Photograph the panel display as part of the record. It takes five minutes and closes the gap that the worked example above fell through.
When an old AMF panel should be replaced
Replace the controller, not just repair it, when it cannot record events, cannot send remote alarms, cannot show which state it is in, or cannot read breaker feedback separately from its own commands. Those four gaps account for most transfer failures that take days to explain. A modern controller with an event log, remote alarms and clear state display usually pays for itself the first time it shortens the investigation of a failed transfer, and it makes every later test faster.
Common mistakes
- No alarm when not in AUTO.
- States with no timeout, so the sequence hangs.
- Breaker position assumed from the command.
- Interlock in software only.
What to send us
Send the control description, the single-line diagram and any event logs from a failed transfer. WhatsApp 98852 01608 or use the application engineering enquiry. See ATS service.
Evidence note. The sequence is illustrative; each site’s design governs.
Questions engineers ask
How long does an AMF panel take to restore supply?
Typically around 10 to 15 seconds with an open transition: about 3 s to confirm the mains failure, about 5 s to crank and run up, about 3 s for voltage and frequency to settle and about 1 s pause before closing, about 12 s in all. Life-safety loads often need 10 s or less, which needs shorter timers or a UPS.
What happens if mains returns while the generator is starting?
The set should complete its start and then run unloaded through its cool-down while the load stays on the mains, because stopping it mid-start and restarting stresses the engine. If the mains fails again during the cool-down, the logic should transfer straight back to the running set rather than starting the sequence from the beginning.
What is the difference between AMF and ATS?
AMF, automatic mains failure, is the logic that detects a mains failure and starts the generator; ATS, automatic transfer switch, is the switching device that moves the load from one source to the other. Many panels combine both, with the AMF controller commanding the transfer breakers or switch, but the functions can also be separate devices from different makers.
Why feedback from the breaker?
Because a command does not prove the breaker moved. A breaker can fail to open or close because of a mechanism fault, a tripped charging motor or a burnt coil. The logic must read the auxiliary contacts and compare them with the command within a set time; a mismatch is a fault, and closing the second source must be blocked until the first is proved open.
How often to test?
Commonly monthly, with an on-load test where the site can accept it, and with a simulated mains failure at least a few times a year so the whole sequence including sensing and breakers is exercised. Record start time, transfer time and any alarms, and follow the maker and site policy for longer engine and switchgear maintenance.
Can logic be customised?
Yes, within what the controller supports, but every change must be documented, reviewed and tested against the full list of failure cases, not only the clean mains failure. Keep the configuration file under version control, and record the version in the panel, so the logic actually running is always known after a service visit or replacement.
This guide gives general principles. Follow the manufacturer’s instructions.
Technical content reviewed by D. Srinivas Reddy, Managing Partner and Service Engineer, Reddy Generators. Last updated 8 November 2026.