Skip to content

Commit b34fa5e

Browse files
committed
Merge branch 'dev'
2 parents dcbcfd7 + a165c7a commit b34fa5e

File tree

88 files changed

+997
-3095
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

88 files changed

+997
-3095
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,12 @@ on:
55
- dev
66
- master
77
- wait_next_API
8-
- dev_*
98
tags:
109
- v*
1110
pull_request:
1211
branches:
1312
- dev
13+
- wait_next_api
1414
types: [opened, synchronize, reopened, ready_for_review]
1515
schedule:
1616
# Sunday at 02:10 UTC.

.github/workflows/clean_workflow_runs.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ jobs:
2222
runs-on: ubuntu-latest
2323
steps:
2424
- name: Clear cache
25-
uses: actions/github-script@v6
25+
uses: actions/github-script@v7
2626
with:
2727
script: |
2828
console.log("About to clear")

AUTHORS.rst

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ Thanks to
1616
- Alexander Lanin
1717
- Alexandre CUER
1818
- Alois Hockenschlohe
19+
- Andy Walker
1920
- Arjan
2021
- André Srinivasan
2122
- andrew-harness
@@ -27,6 +28,7 @@ Thanks to
2728
- Chandler Riehm
2829
- Chris Hung
2930
- Christian Krause
31+
- Daniel Rauber
3032
- dhoomakethu
3133
- doelki
3234
- DominicDataP
@@ -64,6 +66,8 @@ Thanks to
6466
- Logan Gunthorpe
6567
- Marko Luther
6668
- Matthias Straka
69+
- Matthias Urlichs
70+
- Michel F
6771
- Mickaël Schoentgen
6872
- Pavel Kostromitinov
6973
- peufeu2
@@ -77,6 +81,7 @@ Thanks to
7781
- Totally a booplicate
7882
- WouterTuinstra
7983
- wriswith
84+
- Yash Jani
8085
- Yohrog
8186
- yyokusa
8287

CHANGELOG.rst

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,44 @@ helps make pymodbus a better product.
77

88
:ref:`Authors`: contains a complete list of volunteers have contributed to each major version.
99

10+
Version 3.7.3
11+
-------------
12+
* 100% test coverage of framers (#2359)
13+
* Framer, final touches. (#2360)
14+
* Readme file renamed (#2357)
15+
* Remove old framers (#2358)
16+
* frameProcessIncomingPacket removed (#2355)
17+
* Cleanup framers (reduce old_framers) (#2342)
18+
* Run CI on PR targeted at wait_next_api.
19+
* Sync client, allow unknown recv msg size. (#2353)
20+
* integrate old rtu framer in new framer (#2344)
21+
* Update README.rst (#2351)
22+
* Client.close should not allow reconnect= (#2347)
23+
* Remove async client.idle_time(). (#2349)
24+
* Client doc, add common methods (base). (#2348)
25+
* Reset receive buffer with send(). (#2343)
26+
* Remove unused protocol_id from pdu (#2340)
27+
* CI run on demand on non-protected branches. (#2339)
28+
* Server listener and client connections have is_server set. (#2338)
29+
* Reopen listener in server if disconnected. (#2337)
30+
* Regroup test. (#2335)
31+
* Improve docs around sync clients and reconnection (#2321)
32+
* transport 100% test coverage (again) (#2333)
33+
* Update actions to new node.js. (#2332)
34+
* Bump 3rd party (#2331)
35+
* Documentation on_connect_callback (#2324)
36+
* Fixes the unexpected implementation of the ModbusSerialClient.connected property (#2327)
37+
* Forward error responses instead of timing out. (#2329)
38+
* Add `stacklevel=2` to logging functions (#2330)
39+
* Fix encoding & decoding of ReadFileRecordResponse (#2319)
40+
* Improvements for example/contib/solar (#2318)
41+
* Update solar.py (#2316)
42+
* Remove double conversion in int (#2315)
43+
* Complete pull request #2310 (#2312)
44+
* fixed type hints for write_register and write_registers (#2309)
45+
* Remove _header from framers. (#2305)
46+
47+
1048
Version 3.7.2
1149
-------------
1250
* Correct README

MAKE_RELEASE.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,8 @@ Prepare/make release on dev.
1414
* Control / Update API_changes.rst
1515
* Update CHANGELOG.rst
1616
* Add commits from last release, but selectively !
17-
git log --oneline v3.7.0..HEAD > commit.log
18-
git log --pretty="%an" v3.7.0..HEAD | sort -uf > authors.log
17+
git log --oneline v3.7.3..HEAD > commit.log
18+
git log --pretty="%an" v3.7.3..HEAD | sort -uf > authors.log
1919
update AUTHORS.rst and CHANGELOG.rst
2020
cd doc; ./build_html
2121
* rm -rf build/* dist/*
@@ -58,4 +58,4 @@ Architecture documentation.
5858
------------------------------------------------------------
5959
* install graphviz
6060
* pyreverse -k -o jpg pymodbus
61-
l
61+
l

README.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ Upgrade examples:
2323
- 3.6.1 -> 3.7.0: Smaller changes to the pymodbus calls might be needed
2424
- 2.5.4 -> 3.0.0: Major changes in the application might be needed
2525

26-
Current release is `3.7.2 <https://github.com/pymodbus-dev/pymodbus/releases/tag/v3.7.2>`_.
26+
Current release is `3.7.3 <https://github.com/pymodbus-dev/pymodbus/releases/tag/v3.7.3>`_.
2727

2828
Bleeding edge (not released) is `dev <https://github.com/pymodbus-dev/pymodbus/tree/dev>`_.
2929

@@ -84,7 +84,7 @@ Server Features
8484
* callback to intercept requests/responses
8585
* work on RS485 in parallel with other devices
8686

87-
`Server documentation <https://pymodbus.readthedocs.io/en/latest/source/library/server.html>`_
87+
`Server documentation <https://pymodbus.readthedocs.io/en/latest/source/server.html>`_
8888

8989

9090
REPL Features
File renamed without changes.

doc/source/_static/examples.tgz

3.53 KB
Binary file not shown.

doc/source/_static/examples.zip

-66 Bytes
Binary file not shown.

doc/source/client.rst

Lines changed: 36 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -55,9 +55,9 @@ Pymodbus offers clients with transport different protocols and different framers
5555
- ASCII
5656
- RTU
5757
- RTU_OVER_TCP
58-
- Socket
58+
- SOCKET
5959
- TLS
60-
* - Serial (RS-485)
60+
* - SERIAL (RS-485)
6161
- Yes
6262
- Yes
6363
- No
@@ -118,19 +118,32 @@ that a device have received the packet.
118118
Client usage
119119
------------
120120
Using pymodbus client to set/get information from a device (server)
121-
is done in a few simple steps, like the following synchronous example::
121+
is done in a few simple steps.
122+
123+
Synchronous example
124+
^^^^^^^^^^^^^^^^^^^
125+
126+
::
122127

123128
from pymodbus.client import ModbusTcpClient
124129

125130
client = ModbusTcpClient('MyDevice.lan') # Create client object
126-
client.connect() # connect to device, reconnect automatically
131+
client.connect() # connect to device
127132
client.write_coil(1, True, slave=1) # set information in device
128133
result = client.read_coils(2, 3, slave=1) # get information from device
129134
print(result.bits[0]) # use information
130135
client.close() # Disconnect device
131136

137+
The line :mod:`client.connect()` connects to the device (or comm port). If this cannot connect successfully within
138+
the timeout it throws an exception. After this initial connection, further
139+
calls to the same client (here, :mod:`client.write_coil(...)` and
140+
:mod:`client.read_coils(...)` ) will check whether the client is still
141+
connected, and automatically reconnect if not.
132142

133-
and a asynchronous example::
143+
Asynchronous example
144+
^^^^^^^^^^^^^^^^^^^^
145+
146+
::
134147

135148
from pymodbus.client import AsyncModbusTcpClient
136149

@@ -141,7 +154,7 @@ and a asynchronous example::
141154
print(result.bits[0]) # use information
142155
client.close() # Disconnect device
143156

144-
The line :mod:`client = AsyncModbusTcpClient('MyDevice.lan')` only creates the object it does not activate
157+
The line :mod:`client = AsyncModbusTcpClient('MyDevice.lan')` only creates the object; it does not activate
145158
anything.
146159

147160
The line :mod:`await client.connect()` connects to the device (or comm port), if this cannot connect successfully within
@@ -153,6 +166,9 @@ The line :mod:`result = await client.read_coils(2, 3, slave=1)` is an example of
153166

154167
The last line :mod:`client.close()` closes the connection and render the object inactive.
155168

169+
Development notes
170+
^^^^^^^^^^^^^^^^^
171+
156172
Large parts of the implementation are shared between the different classes,
157173
to ensure high stability and efficient maintenance.
158174

@@ -232,6 +248,20 @@ There are a client class for each type of communication and for asynchronous/syn
232248
- :mod:`AsyncModbusUdpClient`
233249
- :mod:`ModbusUdpClient`
234250

251+
Client common
252+
^^^^^^^^^^^^^
253+
Some methods are common to all client:
254+
255+
.. autoclass:: pymodbus.client.base.ModbusBaseClient
256+
:members:
257+
:member-order: bysource
258+
:show-inheritance:
259+
260+
.. autoclass:: pymodbus.client.base.ModbusBaseSyncClient
261+
:members:
262+
:member-order: bysource
263+
:show-inheritance:
264+
235265
Client serial
236266
^^^^^^^^^^^^^
237267
.. autoclass:: pymodbus.client.AsyncModbusSerialClient

0 commit comments

Comments
 (0)