en-us_products:mpino_studio2:monitoring

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
en-us_products:mpino_studio2:monitoring [2026/10/25 08:42] – external edit 127.0.0.1en-us_products:mpino_studio2:monitoring [2026/11/15 08:28] (current) – external edit 127.0.0.1
Line 113: Line 113:
  
 > **Port conflict:** Monitoring data conflicts with project communication or Arduino Code that uses the same board channel. If a conflict notice appears, select a dedicated monitoring channel or change the communication settings and code using that channel. > **Port conflict:** Monitoring data conflicts with project communication or Arduino Code that uses the same board channel. If a conflict notice appears, select a dedicated monitoring channel or change the communication settings and code using that channel.
 +
 +The channel selector to the left of the **Monitoring** button in the Serial Monitor header changes the same **Monitoring port** setting. A change made in one place also appears in the other, and in both places the new channel takes effect on the board only after an upload. The selector cannot be changed while ladder monitoring is on or while an upload is running.
  
 ===== 5. Start and Stop Ladder Monitoring ===== ===== 5. Start and Stop Ladder Monitoring =====
Line 205: Line 207:
 During ladder monitoring, ''Serial.print()'' output on the same channel at 115200 baud can still appear in the Serial Monitor receive view. Because user data can mix with monitoring frames, use separate channels for Arduino Code communication and ladder monitoring whenever possible. During ladder monitoring, ''Serial.print()'' output on the same channel at 115200 baud can still appear in the Serial Monitor receive view. Because user data can mix with monitoring frames, use separate channels for Arduino Code communication and ladder monitoring whenever possible.
  
-===== 9. Troubleshooting =====+===== 9. Comm Trace ===== 
 + 
 +The comm trace keeps the frames that the board sent and received in board RAM, for each channel that has a protocol selected in **Communication Settings**. MPINO Studio 2 receives the records over the ladder-monitoring port, and you can view them line by line in the **Serial Monitor**. Each line shows the bytes and the decoded frame, and an error also appears when the CRC is wrong or no response arrives. 
 + 
 +^ Protocol ^ Frames kept in the trace ^ 
 +| Modbus RTU Slave, LS Electric Cnet Slave | Requests received to the end of the frame (before the station number and the check value are verified) and the responses sent. Requests to other stations, other slaves' responses, and requests with a wrong check value (CRC for Modbus, BCC for LS Electric Cnet) are also kept. | 
 +| Modbus RTU Master | Requests sent, responses received, failures (the received bytes and the result code), and no-response events | 
 +| MPLINK Master, MPLINK Slave | Frames addressed to this board with a good CRC, and frames sent | 
 + 
 +Channels set to **None** and data that Arduino Code exchanges with ''Serial1.write()'', ''Serial1.read()'', and similar calls are not recorded. Bytes that the board discarded without receiving them as a frame are not shown either, so the comm trace is not the same as watching the whole line with an RS-485 converter connected to the PC. 
 + 
 +==== Turn On the Comm Trace ==== 
 + 
 +When you select a protocol for a channel in **Run → Communication**, a **Comm trace** row appears under that channel. Select the **Comm trace** check box, then choose a **Mode** and a **Size**. 
 + 
 +{{ :en-us_products:mpino_studio2:comm-trace-settings-marked.svg?1000 |Comm trace mode and size turned on per channel in Communication Settings }} 
 + 
 +^ Marker ^ Item ^ Setting ^ 
 +| **①** | Comm trace | Turns this channel's comm trace on or off | 
 +| **②** | Mode | Loop or Trigger | 
 +| **③** | Size | 64, 128, 256, 512, 1024, or 2048 B | 
 +| **④** | Mode hint and extra RAM | What the selected mode does when the trace space is full, and the board RAM used by this channel's comm trace (trace space + 55 B of state) | 
 + 
 +^ Mode ^ When the trace space is full ^ When recording starts ^ 
 +| Loop | Overwrites the oldest records first and keeps the latest ones. | Records continuously from the moment the board program starts. | 
 +| Trigger | Stops recording and does not keep later frames. | Records from the beginning when the board program starts and when you select **Capture again**. | 
 + 
 +Turning the comm trace on for the first time sets **Loop** and **256 B**. On boards with 4 KB of RAM (MPINO-8A4R(T)-S, MPINO-8A4R-SU, MPINO-8A8R(T)-S, and MPINO-16A16R), only **64 B** and **128 B** can be selected, and turning the comm trace on sets **128 B**. 
 + 
 +Comm trace settings update the current project immediately and are applied to the board from the next build and upload. Each channel is turned on separately, and changing a channel's protocol to **None** also deletes its comm trace settings. A ''.mp2'' file saved with the comm trace turned on does not open in earlier releases without the comm trace. 
 + 
 +The build also checks the comm trace settings. 
 + 
 +^ Situation ^ Build result ^ 
 +| **Monitoring port** is **Off** | The project is built without the comm trace. A notice appears in the **Problems** panel. | 
 +| The monitoring port is the same port as a channel with the comm trace on | A build error appears. | 
 +| The selected size cannot be used on this board | A build error appears. After a board change, the Size box shows an entry such as **1024 B (not available on this board)**. | 
 +| Not enough board RAM | The error message in the build output shows the RAM used by the comm trace separately. Reduce the trace size or turn the comm trace off. | 
 + 
 +Select a comm trace item in the **Problems** panel to open the **Communication Settings** dialog. 
 + 
 +==== Select Monitoring Channel ==== 
 + 
 +The comm trace reaches MPINO Studio 2 over the ladder-monitoring port, so it can be turned on only after the [[#configure_ladder_monitoring|Monitoring port]] is set. If **Monitoring port** is **Off** or is the same port as the channel, the comm trace fields are locked and show the reason and **Open monitoring port settings**. If a comm trace that is already on becomes locked, **Nothing is being recorded now.** appears after the reason, and you can only turn the comm trace off. 
 + 
 +{{ :en-us_products:mpino_studio2:comm-trace-monitoring-channel-marked.svg?1000 |Select monitoring channel dialog opened over Communication Settings, with locked comm trace fields }} 
 + 
 +^ Marker ^ Item ^ Action ^ 
 +| **①** | Lock reason | Shows why the comm trace cannot be turned on. | 
 +| **②** | Open monitoring port settings | Opens the **Select monitoring channel** dialog over Communication Settings. | 
 +| **③** | Select monitoring channel | Selects the monitoring port from **Off** and the ports on the board. | 
 +| **④** | ✕ | Closes only this dialog and returns to Communication Settings. | 
 + 
 +When you select a port in the **Select monitoring channel** dialog, the project's monitoring port changes immediately and the locked fields in Communication Settings are unlocked. Pressing ''Esc'' or clicking outside the dialog also closes only this dialog. This selection is the same setting as **File → Preferences → Ladder Settings → Monitoring port**, and a change takes effect on the board only after an upload. 
 + 
 +When **Monitoring port** is ''Serial'', the comm trace can be turned on for every channel that has a protocol selected. If you select the port of a channel with the comm trace on as the monitoring port, a confirmation such as **Serial2 comm trace will be turned off** appears. Select **Change and turn trace off** to change the port and turn that channel's comm trace off, or **Cancel** to leave everything unchanged. 
 + 
 +==== View the Comm Trace ==== 
 + 
 +In the **Serial Monitor** on the bottom panel, click **Comm trace** to the right of **Monitoring** to show the comm trace in place of the Serial Monitor receive view. Click it again to return to the Serial Monitor receive view. 
 + 
 +{{ :en-us_products:mpino_studio2:comm-trace-view-marked.svg?1000 |Comm trace view that keeps received lines after the monitoring connection is turned off }} 
 + 
 +^ Marker ^ Item ^ Action ^ 
 +| **①** | Comm trace | Switches between the comm trace view and the Serial Monitor receive view. | 
 +| **②** | Notice band | Shows why records cannot be received. | 
 +| **③** | Traced channels | Selects a channel with the comm trace on (CH1, CH2, or CH3). | 
 +| **④** | Trace scope | Shows the protocol of the selected channel and which frames are kept. | 
 +| **⑤** | Byte display | Shows bytes as Hex, ASCII, or Both. | 
 +| **⑥** | Copy, Save, and Clear | Copies or saves the trace lines on the screen, or clears them from the screen. | 
 +| **⑦** | Trace line | Shows one frame per line. | 
 +| **⑧** | Comm trace status | Shows the mode, how full the board's trace space is, and the number of dropped records. | 
 + 
 +If ladder monitoring is off, clicking **Comm trace** also turns ladder monitoring on. The monitoring-port notice and the upload notice are the same as for the **Monitoring** button. Ladder monitoring stays on even when you click **Comm trace** again to return to the Serial Monitor receive view. 
 + 
 +While the comm trace is shown, the encoding selector, the ASCII and HEX switch, **Copy**, and **Clear** for the Serial Monitor receive view cannot be used. While ladder monitoring is on, records are collected even if the comm trace view is not open. Opening another project or creating a new project clears the received records. 
 + 
 +The board keeps its records in board RAM, so even if you turn ladder monitoring on late or reconnect, you receive the records still left on the board at that time. Restarting the board or turning off its power clears the board's records. 
 + 
 +==== Read Trace Lines ==== 
 + 
 +From left to right, a trace line shows the board time, the time since the previous line, the direction, the bytes, and the decoded frame in parentheses. 
 + 
 +<code> 
 +120.530 s  +489 ms  TX  01 06 00 01 00 03 98 0B  (Station 1 (Pump1, per project) · Write register (06) · Address 1 · Value 3) 
 +120.542 s  +12 ms   RX  01 06 00 01 00 03 98 0B  (Station 1 (Pump1, per project) · Write register (06) · Address 1 · Value 3) 
 +</code> 
 + 
 +  * The board time is the time since the board started, at the moment the board processed the frame. It is not the PC time or the RTC time. 
 +  * **TX** is a frame this board sent, and **RX** is a frame this board received. Modbus RTU Master failures and no-response events are also shown as **RX** lines. 
 +  * For a station that has a name in the Modbus RTU Master device table, the decoded text includes the name, as in **Station 1 (Pump1, per project)**. 
 +  * Click a line to expand all of its bytes in rows of 16 bytes. 
 +  * Up to 2000 lines are shown per channel; beyond that, the oldest lines are removed from the screen. 
 + 
 +When a frame is correct, only the decoded text in parentheses is shown. When a frame is wrong, the decoded text turns red, and **Error:** with the details appears to its right. 
 + 
 +^ Error shown ^ Meaning ^ 
 +| Error: CRC error — expected 2A 32, got 2A 33 | The received CRC differs from the value calculated from the bytes. LS Electric Cnet shows **BCC error**. | 
 +| Error: Exception 02 illegal address | A Modbus exception response. An LS Electric Cnet error response shows a **NAK code**. | 
 +| Error: No response | Modbus RTU Master sent a request but received no response. The bytes column shows **no bytes**. | 
 +| Error: Truncated (first 56/256 bytes) | The frame was longer than one record can store, so only its beginning was kept. | 
 +| Error: Not recognized | The frame cannot be decoded in the protocol format. | 
 + 
 +A record that Modbus RTU Master judged as a failure has a **Result code** at the end of the error. The result codes are ''F1'' (CRC error), ''F2'' (malformed response), and ''F3'' (the request could not be sent because the line was not idle); an exception response carries its exception code. On Modbus RTU Slave and LS Electric Cnet Slave channels, a request sent to another station is not an error, and the decoded text shows **Other station (this board = 1)**. 
 + 
 +The following separator lines can appear between trace lines. 
 + 
 +^ Separator line ^ Meaning ^ 
 +| Connected | The point where ladder monitoring connected and records started arriving. | 
 +| Board restarted | The point where the board restarted. | 
 +| N record(s) (M bytes) dropped: board trace space full | The number of records overwritten because the board's trace space filled before they were sent to MPINO Studio 2. | 
 +| N record(s) lost in transfer | The number of records the board sent that MPINO Studio 2 did not receive because the monitoring data was corrupted. | 
 + 
 +If the status line shows **Traffic exceeds the transfer share — only part is shown**, records have recently been dropped on the board. 
 + 
 +==== Copy, Save, and Capture Again ==== 
 + 
 +  * **Copy**: Copies all screen lines of the selected channel to the clipboard. Hex and ASCII are both included regardless of the byte display, and the Board time (s), Since previous (ms), Direction, Hex, ASCII, Decoded, and Error columns are separated by tabs. 
 +  * **Save**: Saves the screen lines of the selected channel to the file you choose in the **Save comm trace** dialog. The default file name is made from the project name, channel, and date and time, as in ''ProjectName_CH2_20261114-090000.txt''. The top of the file records the project, board, channel settings, and save time. 
 +  * **Clear**: Clears only the trace lines on the screen. The board's records are not cleared, and cleared lines do not appear again. 
 +  * **Capture again**: Appears only for Trigger-mode channels. Select **Capture again** in the confirmation to erase that channel's records left on the board and its trace lines on the screen, and record again from the beginning. Select **Save, then capture again** to save the screen lines first and then capture again. 
 + 
 +Copy and save results appear in the status line. If the board does not answer, the status line shows **The board did not answer Capture again** and **Retry**. 
 + 
 +> **Caution:** Board records and screen lines erased by Capture again cannot be recovered. Save any records you need first. 
 + 
 +==== When No Records Appear ==== 
 + 
 +If a notice appears instead of trace lines, check the following. 
 + 
 +^ Notice shown ^ Action ^ 
 +| No channel in this project has comm trace on | Turn on **Comm trace** for a protocol channel in **Communication Settings**, then build and upload. | 
 +| The monitoring port is set to "Not used" | Select a monitoring port, then build and upload. | 
 +| The monitoring port was changed and not uploaded yet | Upload the project. | 
 +| Monitoring is off | Turn ladder monitoring on. Lines already received can still be copied and saved. | 
 +| The board is not responding | Check the port, cable, and board power. | 
 +| The trace settings in the board's program differ from this project | Check whether you uploaded after changing the comm trace settings, then upload the project. | 
 +| No records yet | Check that the other device is communicating on this channel. | 
 + 
 +===== 10. Troubleshooting =====
  
 ^ Symptom ^ What to check ^ Action ^ ^ Symptom ^ What to check ^ Action ^
Line 222: Line 363:
  
   * [[en-us_products:mpino_studio2:activity_bar|Phase 8 · Activity Bar and Side Panels]]   * [[en-us_products:mpino_studio2:activity_bar|Phase 8 · Activity Bar and Side Panels]]
- 
   * [[en-us_products:mpino_studio2:menus_settings|Phase 7 · Menus and Preferences]]   * [[en-us_products:mpino_studio2:menus_settings|Phase 7 · Menus and Preferences]]
- 
   * [[en-us_products:mpino_studio2:first_project|Phase 1 · Create Your First Project]] — build, upload, and port selection   * [[en-us_products:mpino_studio2:first_project|Phase 1 · Create Your First Project]] — build, upload, and port selection
   * [[en-us_products:mpino_studio2:memory|Phase 2 · Understand Memory]] — memory types used by monitored values   * [[en-us_products:mpino_studio2:memory|Phase 2 · Understand Memory]] — memory types used by monitored values
en-us_products/mpino_studio2/monitoring.1792885354.txt.gz · Last modified: by 127.0.0.1

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki