JMRI Integration Guide

Last updated: May 17, 2026

JMRI (Java Model Railroad Interface) is the leading open-source DCC control software. RailScanPro can connect to JMRI via its JSON/WebSocket API to exchange roster data, block occupancy status, and turnout positions — letting you use both tools in their respective strengths.

What the Integration Does

Feature Provided By
Locomotive roster JMRI (source of truth) → synced to RailScanPro
DCC throttle control JMRI (DecoderPro, WiThrottle, or similar)
Block occupancy JMRI detectors → shown on RailScanPro CTC panel
Turnout position JMRI → shown on RailScanPro CTC panel
Car routing / waybills RailScanPro (RailCommand)
Inventory / photos RailScanPro

Prerequisites

  • JMRI 5.0 or later running on a computer on your local network
  • JMRI's JSON/WebSocket server enabled (see below)
  • RailScanPro Pro plan or above (JMRI integration requires hardware-capable plan)

Enabling JMRI's JSON Server

In JMRI:

  1. Open Edit → Preferences → Start Up (or Preferences → Web Server)
  2. Enable Start JMRI Web Server — default port is 12080
  3. Enable JSON Server — this is the API RailScanPro uses
  4. Restart JMRI

Verify the server is running by opening http://localhost:12080 in a browser on the JMRI machine — you should see the JMRI web interface.

Connecting RailScanPro to JMRI

  1. In RailScanPro, go to RailCommand → Settings → Integrations → JMRI
  2. Enter the JMRI machine's IP address and port (e.g., 192.168.1.100:12080)
  3. Click Test Connection — a green checkmark confirms success
  4. Click Save

RailScanPro stores this setting per railroad profile. If JMRI isn't running, RailScanPro works in offline mode without block/turnout data.

Roster Sync

Once connected:

  1. Go to RailCommand → Settings → Integrations → JMRI → Sync Roster
  2. RailScanPro imports your JMRI locomotive roster, matching each entry to existing inventory items by DCC address
  3. Items not yet in RailScanPro are created as draft items — you approve or dismiss each one

Ongoing sync is one-way: JMRI is the master for DCC addresses and decoder settings. RailScanPro is the master for photos, collections, and car routing.

Block Occupancy on the CTC Panel

After connecting:

  1. Go to RailCommand → Dispatcher → CTC Panel
  2. Blocks connected to JMRI detectors show live occupancy (green = clear, red = occupied)
  3. Turnout positions update in real time as operators throw switches

This turns your RailScanPro CTC panel into a live display — useful for a dispatcher running from a separate screen.

Troubleshooting

Connection refused — Confirm JMRI's web server is running. Check that your firewall isn't blocking port 12080.

Wrong block states — Verify that JMRI sensor names match the block names in your RailScanPro schematic. The names must match exactly (case-insensitive).

Roster not syncing — Make sure the JMRI roster has been saved to disk (File → Store All Tables) before syncing.

Next Steps