# nisystemsengineering/labview-modbus-api architecture

> Architecture diagram of the GitHub repository nisystemsengineering/labview-modbus-api, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-02). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/nisystemsengineering/labview-modbus-api
- Repository: https://github.com/nisystemsengineering/labview-modbus-api

## Overview

This is a LabVIEW Modbus library providing master and slave communication over serial and Ethernet. Users create a master or slave instance, issue Modbus operations, and communicate with industrial devices or gateways. The tree identifies API, network, transmission-unit, and data-model layers, but no source excerpts were provided; internal connections below are therefore dashed and unverified. Major protocol and device-model capabilities are represented without asserting specific call paths.

Main entry points: [`API/Master`](https://github.com/nisystemsengineering/labview-modbus-api/tree/master/API/Master) (Master Operations), [`API/Slave`](https://github.com/nisystemsengineering/labview-modbus-api/tree/master/API/Slave) (Slave Operations), [`Network Protocol/Network Master`](https://github.com/nisystemsengineering/labview-modbus-api/tree/master/Network%20Protocol/Network%20Master) (Master Network), [`Network Protocol/Network Slave`](https://github.com/nisystemsengineering/labview-modbus-api/tree/master/Network%20Protocol/Network%20Slave) (Slave Network)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_api["Public API"]
  node_wrapper["Instance Creation"]
  node_masterapi["Master Operations"]
  node_slaveapi["Slave Operations"]
end

subgraph group_protocol["Protocol Handling"]
  node_tdu["Transmission Units"]
  node_pdu["Protocol Data Unit<br/>[Construct PDU.vi]"]
  node_masterfn["Master Functions"]
end

subgraph group_network["Network Communication"]
  node_netmaster["Master Network"]
  node_netslave["Slave Network"]
  node_serial["Serial Transport"]
  node_tcp["TCP Transport"]
end

subgraph group_model["Device Model"]
  node_datamodel["Device Data Model"]
  node_standardmodel["Standard Model"]
end

node_user(("LabVIEW User"))

node_user -.->|"creates instance"| node_wrapper
node_user -.->|"issues operations"| node_masterapi
node_user -.->|"uses slave API"| node_slaveapi
node_masterapi -.->|"communicates through"| node_netmaster
node_slaveapi -.->|"communicates through"| node_netslave
node_netmaster -.->|"uses serial"| node_serial
node_netmaster -.->|"uses Ethernet"| node_tcp
node_netslave -.->|"uses serial"| node_serial
node_netslave -.->|"uses Ethernet"| node_tcp
node_masterapi -.->|"transfers protocol data"| node_tdu
node_slaveapi -.->|"transfers protocol data"| node_tdu
node_tdu -.->|"carries protocol data"| node_pdu
node_masterapi -.->|"supports functions"| node_masterfn
node_slaveapi -.->|"accesses device model"| node_datamodel
node_datamodel -.->|"provides standard model"| node_standardmodel

click node_wrapper "https://github.com/nisystemsengineering/labview-modbus-api/blob/master/API/Wrapper/Create%20Modbus%20Instance.vi"
click node_masterapi "https://github.com/nisystemsengineering/labview-modbus-api/tree/master/API/Master"
click node_slaveapi "https://github.com/nisystemsengineering/labview-modbus-api/tree/master/API/Slave"
click node_tdu "https://github.com/nisystemsengineering/labview-modbus-api/tree/master/Transmission%20Data%20Unit"
click node_pdu "https://github.com/nisystemsengineering/labview-modbus-api/blob/master/Modbus%20Data%20Unit/Construct%20PDU.vi"
click node_masterfn "https://github.com/nisystemsengineering/labview-modbus-api/tree/master/Master%20Function%20Definition"
click node_netmaster "https://github.com/nisystemsengineering/labview-modbus-api/tree/master/Network%20Protocol/Network%20Master"
click node_netslave "https://github.com/nisystemsengineering/labview-modbus-api/tree/master/Network%20Protocol/Network%20Slave"
click node_serial "https://github.com/nisystemsengineering/labview-modbus-api/tree/master/Network%20Protocol/Serial%20Shared%20Components"
click node_tcp "https://github.com/nisystemsengineering/labview-modbus-api/tree/master/Network%20Protocol/TCP%20Shared%20Components"
click node_datamodel "https://github.com/nisystemsengineering/labview-modbus-api/blob/master/Data%20Model/Device%20Data%20Model.lvclass"
click node_standardmodel "https://github.com/nisystemsengineering/labview-modbus-api/blob/master/Data%20Model/Standard%20Data%20Model/Standard%20Data%20Model.lvclass"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_wrapper,node_masterapi,node_slaveapi,node_user toneBlue
class node_tdu,node_pdu,node_masterfn toneAmber
class node_netmaster,node_netslave,node_serial,node_tcp toneMint
class node_datamodel,node_standardmodel toneRose
```

## Components

### Public API

- [Instance Creation](https://github.com/nisystemsengineering/labview-modbus-api/blob/master/API/Wrapper/Create%20Modbus%20Instance.vi): `API/Wrapper/Create Modbus Instance.vi`
- [Master Operations](https://github.com/nisystemsengineering/labview-modbus-api/tree/master/API/Master): `API/Master`
- [Slave Operations](https://github.com/nisystemsengineering/labview-modbus-api/tree/master/API/Slave): `API/Slave`

### Protocol Handling

- [Transmission Units](https://github.com/nisystemsengineering/labview-modbus-api/tree/master/Transmission%20Data%20Unit): `Transmission Data Unit`
- [Protocol Data Unit](https://github.com/nisystemsengineering/labview-modbus-api/blob/master/Modbus%20Data%20Unit/Construct%20PDU.vi): `Modbus Data Unit/Construct PDU.vi`
- [Master Functions](https://github.com/nisystemsengineering/labview-modbus-api/tree/master/Master%20Function%20Definition): `Master Function Definition`

### Network Communication

- [Master Network](https://github.com/nisystemsengineering/labview-modbus-api/tree/master/Network%20Protocol/Network%20Master): `Network Protocol/Network Master`
- [Slave Network](https://github.com/nisystemsengineering/labview-modbus-api/tree/master/Network%20Protocol/Network%20Slave): `Network Protocol/Network Slave`
- [Serial Transport](https://github.com/nisystemsengineering/labview-modbus-api/tree/master/Network%20Protocol/Serial%20Shared%20Components): `Network Protocol/Serial Shared Components`
- [TCP Transport](https://github.com/nisystemsengineering/labview-modbus-api/tree/master/Network%20Protocol/TCP%20Shared%20Components): `Network Protocol/TCP Shared Components`

### Device Model

- [Device Data Model](https://github.com/nisystemsengineering/labview-modbus-api/blob/master/Data%20Model/Device%20Data%20Model.lvclass): `Data Model/Device Data Model.lvclass`
- [Standard Model](https://github.com/nisystemsengineering/labview-modbus-api/blob/master/Data%20Model/Standard%20Data%20Model/Standard%20Data%20Model.lvclass): `Data Model/Standard Data Model/Standard Data Model.lvclass`

### Other components

- **LabVIEW User**

## Connections

- LabVIEW User → Instance Creation: creates instance
- LabVIEW User → Master Operations: issues operations
- LabVIEW User → Slave Operations: uses slave API
- Master Operations → Master Network: communicates through
- Slave Operations → Slave Network: communicates through
- Master Network → Serial Transport: uses serial
- Master Network → TCP Transport: uses Ethernet
- Slave Network → Serial Transport: uses serial
- Slave Network → TCP Transport: uses Ethernet
- Master Operations → Transmission Units: transfers protocol data
- Slave Operations → Transmission Units: transfers protocol data
- Transmission Units → Protocol Data Unit: carries protocol data
- Master Operations → Master Functions: supports functions
- Slave Operations → Device Data Model: accesses device model
- Device Data Model → Standard Model: provides standard model
