Hardware Support: Methods to Connect Multiple Computers to a LocoNet® Layout
JMRI currently supports two different ways to connect multiple computers to your LocoNet®-equipped layout using a single LocoBuffer. In both methods, the computers communicate using standard TCP/IP protocols, but there are differences in the details.
One method allows multiple JMRI nodes to connect as
Clients to a single LocoNetOverTCP
LbServer, which is external to JMRI.
The other method uses the inbuilt LocoNet Client/Server capability of
JMRI.
The difference between these two methods is that JMRI LocoNet Client/Server uses the native Java Remote Method Invocation (RMI) protocol, whereas the LocoNetOverTCP uses a separate non-Java server process, LbServer, that communicates using plain ASCII String messages over TCP/IP sockets, allowing non-Java nodes to also share the one LocoBuffer.
For most people who simply want to have several computers share a single LocoBuffer connection, the JMRI LocoNet Client/Server option can be easier to configure. For others wanting to provide remote access the layout over Internet, the LocoNetOverTCP LbServer option may be more suitable as configuring the firewall rules to allow external access will be simpler. Setting up networking equipment can be complicated, so if one of them doesn't work for you initially, you might want to just try the other one to see if it works on your home network.
Notes:
- If the computers are all close to the LocoNet, e.g. acting as local control panels, you don't really need any networking to do this. You can instead connect each of the computers to the LocoNet via their own LocoBuffer or LocoBuffer-II (or MS-100, though this is not recommended) and have them individually take part in the LocoNet communications. This doesn't cause any additional communications load. It does cost a little more for the extra adapters, and doesn't permit you to put a computer remote from the layout.
LocoNet® is a registered trademark of Digitrax, Inc.