Question

Function 0x05 "Write Single Coil" writes a single binary output on a Modbus slave. The ON value is encoded as 0xFF00 and OFF as 0x0000; any other value is invalid.

ModbusMock examFunction codesMedium
Answer

True

The 0x05 encoding convention is: 0xFF00 means ON (coil = true), 0x0000 means OFF (coil = false), and any other value triggers exception 0x03 "Illegal Data Value". The choice of 0xFF00 rather than 0x0001 is a historical Modbus convention that helps distinguish this command from others. The slave reply is an echo of the request, which serves as confirmation. The dual function code is 0x0F "Write Multiple Coils", which writes several coils in a single frame.

Preparation tip

If your driver receives "Illegal Data Value" on a Write Single Coil, the bug is almost always that someone wrote 0x0001 instead of 0xFF00 in the value field.

Waitlist

Modbus bank in preparation

The full Modbus bank isn't available yet. Drop your email to get notified at launch and grab an early-bird discount.

Join the waitlist
Want more?

See the 9 other Modbus practice questions

Related questions

Question from our independent practice bank. Modbus is a registered trademark of Modbus Organization, not affiliated with CertifBus.

Last updated: 19 May 2026

Join the waitlist
Modbus waitlist