Skip to content
| Marketplace
Sign in
Visual Studio Code>Other>Modbus ReaderNew to Visual Studio Code? Get it now.
Modbus Reader

Modbus Reader

Lanley

|
157 installs
| (0) | Free
Read and monitor Modbus TCP/RTU devices directly from VS Code with automation, logging, and real-time monitoring
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

Modbus Reader

Read, monitor, and automate Modbus TCP/RTU register polling directly inside Visual Studio Code.

  • Multi-device sessions (TCP + RTU)
  • Auto-read monitoring with interval polling
  • Automations (conditions → actions)
  • History + export (CSV)

Contents

  • Key Features
  • Quick Start
  • Automation Examples
  • Views
  • Requirements
  • Configuration Notes
  • Known Limitations
  • Troubleshooting
  • Release Notes
  • License

Key Features

Sessions (TCP / RTU)

  • Create and manage multiple Modbus sessions (TCP and RTU)
  • Connection status indicators (connected / disconnected / error)
  • Session persistence across VS Code restarts
  • Supports standard read function codes:
    • FC01 Coils
    • FC02 Discrete Inputs
    • FC03 Holding Registers
    • FC04 Input Registers

Monitoring

  • Auto-read intervals: 1s, 5s, 15s, 30s, 1m, 5m
  • View values in decimal, hex, and binary
  • Per-session history (last 1,000 readings)
  • Export readings/logs to CSV (with timestamps)

Automations

  • Interval-based execution (scheduler)
  • Conditions with operators: =, ≠, >, <, ≥, ≤
  • Actions:
    • Show VS Code notifications
    • Append events to a log file
  • Visual runtime feedback:
    • “Running” spinner while evaluations execute
    • Status bar countdown to next run

Environment Variables

  • Centralize reusable values (IPs, ports, Unit IDs, etc.)
  • Reference anywhere with: ${VARIABLE_NAME}

Pro Features

  • Up to 50 concurrent sessions
  • 1,000 entry history per session
  • Pagination for large datasets (50 entries/page)
  • Sticky table headers
  • CSV export with timestamps

Quick Start

1) Create a session

  1. Open Modbus Reader in the Activity Bar
  2. Click + New Session
  3. Choose TCP or RTU
  4. Enter connection details:

TCP

  • Host: 192.168.1.100
  • Port: 502 (default)

RTU

  • Serial Port: COM3 / /dev/ttyUSB0
  • Baud Rate: e.g., 9600
  1. Set Unit ID (default 1) and Timeout (default 3000ms)
  2. Click Add

2) Connect + read registers

  1. Select the session
  2. Click Connect
  3. Choose register type: Holding / Input / Coil / Discrete
  4. Enter:
    • Start address (e.g., 0)
    • Count (e.g., 10)
  5. Click Read

3) Enable auto-read monitoring

  1. Select an interval (1s → 5m)
  2. Click Start Auto-Read
  3. Watch values update in real time
  4. Click Stop to pause

4) Create an automation

  1. Open the Automate view
  2. Click + New Automation
  3. Name the automation
  4. Select one or more sessions
  5. Add conditions (example: holding[100] > 50)
  6. Add actions (notification and/or logging)
  7. Save and toggle Enabled

5) Use environment variables

  1. Open the Env view
  2. Click + New Variable
  3. Add:
    • Name: DEVICE_IP
    • Value: 192.168.1.100
  4. Reference anywhere: ${DEVICE_IP}

Automation Examples

Temperature threshold alert

Condition: holding[100] > 75
Action: Notify "High temperature detected!"
  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2026 Microsoft