Journal

The big idea: read, decide, write, repeat

Watch: the scan cycle behind every ship PLC

Picture the bridge during a port approach. The pilot asks for the bow thruster. The officer presses START on the thruster panel. Nothing happens for a few seconds. Down in the engine room a third diesel generator cranks, runs up to speed, and a few seconds later its breaker closes with a solid clunk. Only then does the thruster start.

Nobody in the engine control room touched anything. The power management system (PMS) did it all. And underneath the PMS, the alarm system and most other automation on board is the same machine: a programmable logic controller, or PLC.

One sum decides everything

Say DG1 and DG2 are on line, 1000 kW each, carrying 900 kW of ship’s load. The thruster needs 1000 kW, and the PMS has been set to keep at least 200 kW spare after any heavy consumer starts. The PMS works out the power still available:

\[P_{\text{avail}} = 2 \times 1000 – 900 = 1100\ \text{kW}\]

It needs 1000 + 200 = 1200 kW. Since 1100 kW is less than 1200 kW, it blocks the thruster start and starts DG3. With three sets on line there is 2100 kW available, so the request is granted once DG3 is synchronised and on the board. That is the whole idea of heavy-consumer control: do the arithmetic before the load arrives, not after the blackout.

The loop every PLC runs

A PLC does not “think” the way a person does. It repeats four steps, over and over, many times a second. This is the scan cycle:

  1. Read all inputs into memory: switches, contacts, 4–20 mA signals, network data from the generator controllers.
  2. Solve the program from top to bottom using that frozen snapshot: “if load plus thruster is more than available, block and start next set”.
  3. Write the results to the outputs: start relay for DG3, “thruster blocked” lamp, alarm horn.
  4. Housekeep: talk to the network, run self-diagnostics, check the watchdog. Then go back to step 1.

The time one lap takes is the scan time. Every timer, every alarm delay and every response you will meet in this course is counted in scans.

Three systems, one pattern

  • The PLC reads sensors and drives pumps, valves and starters.
  • The alarm and monitoring system reads thousands of points, compares each with a limit and tells a human when something is wrong.
  • The PMS reads generator kW, frequency and voltage, and starts, synchronises, loads and stops the diesel generators.

All three run the same read–decide–write loop. In this course you open each one up, learn the numbers and rules behind it, and finish with a Python model of three generators where you watch the PMS block a thruster, synchronise DG3 and share the load.

Keep the loop in mind. When something on board misbehaves, the first question is always: what did the controller read, what did it decide, and what did it write?

Log in or create a free account to save your progress.

Enjoyed the preview? Unlock the full course.

₹5,000 ₹9,800 49% off
Create free account to enrollLog in

Lifetime access to every lesson, the equations and the downloadable Python simulation. Your progress is saved to your account.

Pay securely with UPI, cards, netbanking or wallets through Razorpay. The course unlocks instantly.

By enrolling you agree to our Terms, Refund policy and Privacy policy.

All lessons
  1. The big idea: read, decide, write, repeat▶ VideoFree preview
  2. How it was invented and its first uses▶ VideoLocked
  3. Where it is used today: a tour of the ship's automation▶ VideoLocked
  4. The equations: scan time, 4–20 mA, synchronising and load sharing▶ VideoLocked
  5. Worked demo and setup: thruster request to shared load▶ VideoLocked
  6. Build your own, step by step▶ VideoLocked
  7. Python simulation labLocked
  8. Practice problems and quizLocked

We’ll drive a rover into your seminar hall. The demo is free.

A 45-minute session with a live rover drive and a drone flight in a netted cage, for any engineering college in Kerala or Tamil Nadu.