Table of Contents

Checking Operation and Troubleshooting

HMI Connection · Building the HMI Screen

The product program and the HMI screen must be transferred separately. After both transfers, first check that the two devices' communication settings and the screen addresses match. Then go through the read and write results for internal memory in order. The actual request addresses for D0/D1/D2/M0 on the screen follow the address table for your development tool and protocol. Because the HMI model is up to you, check the manufacturer's manual for menus and where errors are shown.

1. Check the product and HMI settings

What to check What must match
Connection The same electrical interface, and the Serial port you actually wired
Communication Protocol, station number, baud rate, data bits, parity, and stop bits
Memory M and D addresses for your development tool and protocol
Screen Numbers are 16-bit integers; M is a bit
Transfer Product program upload and HMI screen download are both complete. In STUDIO2, the upload log in the bottom panel ended normally.

On the product side, go by the upload-complete indication in Arduino IDE or by the normal end of the upload log in STUDIO2's bottom panel. A successful build in STUDIO2 alone does not mean the upload finished. For the HMI side, check download success and external device status as described by your HMI manufacturer and editor. First confirm that both transfers succeeded.

2. Read a value from the product

From here on, these are simple operation checks using the addresses and communication settings described earlier. Check in this order: read → write a number → write a bit.

Check that the communication check number D0 on the HMI increases every second. After 99 it returns to 0. Depending on the HMI refresh interval, some numbers may appear to be skipped.

3. Send a value and get it back

The HMI writes a value to D1, the product copies it to D2, and the HMI reads D2

  1. Enter 1234 in input value D1 and confirm it.
  2. Check that the value returned by the product, D2, also changes to 1234.
  3. Try 7, 9999, and 0 as well.

4. Check reading and writing a bit

Each time you press the test switch, check that the separate M0 lamp changes ON/OFF. If you added the M1 lamp in STUDIO2, the ladder result changes the same way. This exercise uses internal M and D memory, not real relay outputs.

The examples initialize memory when the product starts. After a power cycle, test the numbers and the switch again.

5. Where to look for each symptom

Symptom Where to look first, and what to check
No response / timeout The actual port and wiring in channels and RS-232/485 wiring → protocol, station number, baud rate, and 8N1 under Choose a protocol on the same page → external device status in the HMI editor
D0 stays at 0 Whether the HMI number element reads the product as an external device → upload complete → the D0 address for your protocol
Values are off by one The 0-based and 1-based rule in the Modbus address format. This does not apply to Cnet or MC.
A different value appears The SDK or STUDIO2 address table on your protocol page → the Coil and Holding Register areas, or the Cnet or MC device area, in the HMI driver
Only the input field changes and D2 stays the same Writing external D1 and reading D2 in the screen element settings → D[2] = D[1] in the product program or STUDIO2 main
A written value is erased right away Whether loop() in the uploaded sketch, or ladderLoop or main in STUDIO2, keeps resetting or overwriting D1/M0
The number is abnormally large 16-bit, 1 word, scale 1, and 0 decimal places on the HMI number element, and the driver's byte swap setting
Only the switch's appearance changes Whether writing external M0 and a separate read of M0 are both assigned in the switch and lamp settings
Works briefly, then disconnects Long delay calls in the product code, and whether other code or monitoring also uses Serial1, the HMI channel
Modbus address error The start address, request count, and allocated memory count on your Modbus page, and the request area in the HMI driver. The SDK sends no reply for an address outside the allocated memory, so the HMI may show a timeout.
Product upload fails Arduino IDE installation, board, and COM port or STUDIO2 installation and product selection, and the download cable and driver

Start by reading D0, then test writing a number D1 → D2, and finally the M0 bit. If communication does not work at all, compare the port, wiring, protocol, station number, and communication format before changing any addresses.

6. What to prepare when contacting us

Please prepare the product model, development tool, and SDK version; the HMI manufacturer, exact model, and editor version; the serial port you used and a photo of the terminal wiring; a screenshot of the protocol, station number, baud rate, 8N1, and external device addresses; and any error message, along with how far the tests got among D0, D1→D2, and M0.