Skip to main content

Package that let easily interact with the Next devices over Modbus RTU

Project description

Python library to access Studer-Innotec Next devices through Modbus RTU/TCP.

Prerequisites

Please read the complete documentation available on : Studer Innotec SA -> Support -> Download Center -> Software and Updates

Getting Started

1. Package installation

$ pip install nxmodbus

2. Hardware installation

  • Connect your Next installation through a Next gateway (e.g. nx-interface) to your controller (personal computer, Raspberry Pi, etc.)
    • (RTU) using a USB to RS-485 adapter.

    • (TCP) using the Ethernet interface connecting to your local area network.

3. Serial configuration

This package rely on pyserial standard package, in order to use the nxmodbus package make sure to instantiate it like :

import serial

serial_port = serial.Serial(SERIAL_PORT_NAME, SERIAL_PORT_BAUDRATE, parity=serial.PARITY_EVEN, timeout=1)
  • where SERIAL_PORT_NAME is your serial port interface, for example set it to ‘COM4’ (string argument) when using Windows otherwise you may set it to ‘/dev/ttyUSB0/’ on Linux

  • where SERIAL_PORT_BAUDRATE is the baudrate used by your serial port interface (use the Nx-interface to set the serial parameter of the server)

4. Run an example from /examples folder

Go to /examples folder with a terminal and execute this script

$ python ex_rtu_read_param.py
$ python ex_tcp_read_param.py

Check client_rtu file or client_tcp file to understand it.

5. Open documentation

Open documentation from Read The Docs

Warnings

  • Use devices addresses generated into addresses file

  • It is strongly recommended NOT to spam the Next gateway with multiple requests. The correct way to communicate with the Next gateway is to send a request and to wait for the response before sending the next request. If no response comes from the nxmodbus after a delay of 1 second, we can consider that the timeout is over and another request can be send. It is also how Modbus RTU is intended to work.

Authors

Studer Innotec SA - Initial work - Studer Innotec SA

License

This project is licensed under the MIT License - see the LICENSE file for details

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

nxmodbus-0.3.0.tar.gz (49.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

nxmodbus-0.3.0-py3-none-any.whl (52.7 kB view details)

Uploaded Python 3

File details

Details for the file nxmodbus-0.3.0.tar.gz.

File metadata

  • Download URL: nxmodbus-0.3.0.tar.gz
  • Upload date:
  • Size: 49.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.8.10

File hashes

Hashes for nxmodbus-0.3.0.tar.gz
Algorithm Hash digest
SHA256 d4f486bb3846aa75642f145adf5b7429c84e8fc7d4fd07dcab3c5106d726d9f2
MD5 66f5683385f9f716d13aa63fc4c63853
BLAKE2b-256 df2e59585ffb5ef49314b0b01a24374cec1305e7276b64d5a70ef884ab5778a7

See more details on using hashes here.

File details

Details for the file nxmodbus-0.3.0-py3-none-any.whl.

File metadata

  • Download URL: nxmodbus-0.3.0-py3-none-any.whl
  • Upload date:
  • Size: 52.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.8.10

File hashes

Hashes for nxmodbus-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 96abf9ab018a54b3e00a8bc67fcc07b57ef0aa8005a13ee27dd5dc134d6d3796
MD5 ed06598f6ce7ea72decc4392064fe024
BLAKE2b-256 64b6c96d7d62c5bc75a6c470d989af2859310096367219c0d5505514341db80d

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page