Best practices
Habits that keep a program easy to read and test.
- One coil per outputWrite each output from one rung. Two coils on one tag means the lower rung wins.
- Latch only what must be rememberedDrive outputs with OTE or a seal-in; keep OTL for alarms and memory.
- Name tags for what they meanName each tag for what it is, and a BOOL for its true state.
- Keep tags in the narrowest scopeProgram Tags for one program, Global Tags only for what is shared.
- Organise with routinesKeep MainRoutine a short list of CALLs.
- Comment every rungA one-line comment says why the rung is there.
- Test one scan at a timeSingle Scan, toggled bits and forces, before running the whole machine.