Commit Graph
100 Commits
Author SHA1 Message Date
akira 4a2ea2d527 Update changelog for 2.8.0-1 release 2024-11-13 14:16:00 +01:00
akira 5518d8ce1c Merge tag '2.8.0' into pkg/debian
Release version 2.8.0
2024-11-13 14:13:40 +01:00
akira 21d8c523ae chore: Release 2.8.0 2024-11-13 14:11:55 +01:00
akira f50a7744cd chore: Increase to RC2 of upcoming Release 2.8.0 2024-11-12 10:53:47 +01:00
akira a9ec71e970 test: Update runtime warning for exceeded cycle time in mainloop 2024-11-12 10:53:47 +01:00
akira 19bbdb03e8 test: Fix test for default location of config.rsc
The tests for the default path of the config.rsc are now performed
optionally. If write permission exists for the standard paths, the
tests are performed with the config.rsc.
2024-11-12 10:18:52 +01:00
akira 41720ee042 chore: Increase to RC1 of upcoming Release 2.8.0 2024-11-12 09:48:44 +01:00
akira e5510f5726 Merge branch 'main' into rc 2024-11-12 09:47:49 +01:00
akira 24744a5a9c test: Add tests for RevPi Connect 5 2024-11-08 09:40:09 +01:00
akira 94ac5c9b92 feat: Add support for RevPi Connect 5 2024-11-08 09:40:09 +01:00
akira f3f81f3633 refactor: Show deprecation warning on root context manager
This context manager can delete the entire instance of ModIO when using
`with rpi:` after creating an instance of ModIO by
`rpi = revpimodio.RevPiModIO(...)`.
2024-11-08 09:37:40 +01:00
akira 579617d223 feat: Add more colors in constants for a RGB status LED
On the Connect 4, the status LEDs are RGB. By switching several LEDs,
further colors can be generated as red, green, blue.
2024-11-08 09:21:05 +01:00
akira 276ea8dd72 test: Cleanup tests and use relative imports 2024-11-08 08:31:39 +01:00
akira dc5906288c test: Cycle loop functions 2024-10-29 14:15:16 +01:00
akira 1de230c1e2 test: Events and signals 2024-10-29 14:15:16 +01:00
akira 32d113540c test: Test mainloop functions 2024-10-29 14:15:16 +01:00
akira d7a185451a test: IO values and counter 2024-10-29 14:13:06 +01:00
akira 601d018eba test: Old core rap file without error limits 2024-10-29 14:13:06 +01:00
akira 43d2b12413 test: Connect devices 2024-10-29 14:13:06 +01:00
akira e876c97c30 test: Core devices 2024-10-29 14:13:06 +01:00
akira f95b2d6c49 test: Basic IO functions 2024-10-29 14:13:06 +01:00
akira 4c64387649 test: Replace io function 2024-10-29 14:13:06 +01:00
akira c10f0a2d05 test: Common device functions 2024-10-29 14:13:06 +01:00
akira 960f21539e test: ModIO class basics 2024-10-29 14:13:05 +01:00
akira 125f8bb4fe test: Init ModIO classes 2024-10-29 14:13:05 +01:00
akira 442071c212 test: Configuration errors in config.rsc 2024-10-29 14:13:05 +01:00
akira 1e331feb2f fix: Resolve constants of internal module 2024-10-28 13:33:44 +01:00
akira 629a517ab8 test: Connect 4 integrated input and output 2024-10-28 12:48:50 +01:00
akira 30dfb48fe5 Update changelog for 2.7.2-1 release 2024-09-23 12:24:36 +02:00
akira 4b7f55701b Merge tag '2.7.2' into pkg/debian
Release version 2.7.2
2024-09-23 12:21:33 +02:00
akira 8702c3c8c1 chore: Release 2.7.2 2024-09-23 12:20:26 +02:00
akira 9bb1cee4a1 test: Update wd_toggle test for connect 4
This function will now raise a NotImplementedError.
2024-09-20 16:37:50 +02:00
akira 0ba8772d1b fix: Raise error on connect 4 when using wd_toggle function
On the Connect 4, the hardware watchdog was removed from the process
image by KUNBUS. To use the hardware watchdog, other functions must now
be used that are not implemented by RevPiModIO.
2024-09-18 10:57:17 +02:00
akira 5d9f513f71 chore: Increase to RC1 of upcoming Release 2.7.2 2024-09-18 10:00:04 +02:00
akira 88d5fc4e98 build: Add test target as dependency of all target in Makefile 2024-09-18 10:00:04 +02:00
akira e8d7860dd2 fix: Colors of constants GREEN and RED match LEDs of RevPi Connect 4
The LED colors for the A1-A5 objects of the .core class of the connect 4
did not match the values of the constants for GREEN and RED, as on all
other RevPi Devices. In addition, the color BLUE was added.
2024-09-18 09:20:21 +02:00
akira c6ae318a15 test: Add RevPi Compact tests 2024-09-18 09:09:25 +02:00
akira 6adfe95201 test: Add RevPi Flat tests 2024-09-18 09:09:25 +02:00
akira 379899f54c test: Add connect 4 tests 2024-09-18 09:09:25 +02:00
akira d2d37f4972 test: Test replace_io file 2024-09-18 09:09:25 +02:00
akira 24b50c2973 test: Insert default test class for ModIO
The standard tests provide a prepared process image and a defined
config.rsc.
2024-09-18 09:09:25 +02:00
akira 782ea5840d chore: PyCharm IDE settings update 2024-09-18 09:05:14 +02:00
akira 9a5039df9a Update changelog for 2.7.1-1 release 2023-12-04 16:18:10 +01:00
akira 9318649732 Merge tag '2.7.1' into pkg/debian
Release 2.7.1
2023-12-04 16:03:51 +01:00
akira 9741d13514 chore: Release 2.7.1
Signed-off-by: Sven Sager <akira@narux.de>
2023-12-04 16:01:51 +01:00
akira 41a09c4f17 fix: Context manager crashes in monitoring mode
The context managers tried to write to the process image in
monitoring=True mode. This is not allowed and the application crashed
 with an error.

Signed-off-by: Sven Sager <akira@narux.de>
2023-12-01 15:58:28 +01:00
akira ad4a1fcd38 fix: Error of loop management in the context manager
When leaving the IO context manager, the loop flag was not reset
properly. The context manager could therefore only be traversed once.

Signed-off-by: Sven Sager <akira@narux.de>
2023-12-01 15:48:57 +01:00
akira 8135bc83fd Update changelog for 2.7.0-1 release 2023-11-24 09:49:43 +01:00
akira 1dcb4fbbd6 Merge tag '2.7.0' into pkg/debian
Release 2.7.0
2023-11-24 09:48:15 +01:00
akira 8df43106e4 chore: Release 2.7.0
Signed-off-by: Sven Sager <akira@narux.de>
2023-11-24 09:45:23 +01:00
akira d5320603f5 feat: Add context manager for modio instance
Signed-off-by: Sven Sager <akira@narux.de>
2023-11-20 12:08:44 +01:00
akira 5a6ed54e5c feat: Add context manager for modio instance
Signed-off-by: Sven Sager <akira@narux.de>
2023-11-20 12:08:42 +01:00
akira 12a34e7d11 docs: Add IO context manager description
Signed-off-by: Sven Sager <akira@narux.de>
2023-11-20 09:12:40 +01:00
akira 01e7109ec9 chore: Increase to RC3 of upcoming Release 2.7.0
Signed-off-by: Sven Sager <akira@narux.de>
2023-11-20 08:42:09 +01:00
akira cc689a58eb feat: Add support for RO device
This adds the RO device as its own class. The RO device has a special
ioctl function, via which the switching cycles of the relays can be
called up. Relay outputs from the RO device get the additional
attribute 'cycles', which returns the number of switching cycles.

The implementation via RevPiNetIO classes cannot currently be
implemented because the server does not support a return value.

Signed-off-by: Sven Sager <akira@narux.de>
2023-11-02 16:57:21 +01:00
akira c87f1cceb6 fix: Check if the length of the previous IO overlaps with the new IO
When applying the PiCtory configuration, all IOs are now checked to
see if they overlap with the previous ones. If an overlap is
detected, the IO is ignored and a warning is given to the user.

Signed-off-by: Sven Sager <akira@narux.de>
2023-11-01 12:15:27 +01:00
akira 42151e246c fix: Check offset values of the devices for integers
In the event of a misconfiguration in PiCtory, it may happen that the
offset values are given as floating point numbers. These devices and
their IOs must ignore ModiO that it cannot be ensured which offset
is correct.

Signed-off-by: Sven Sager <akira@narux.de>
2023-11-01 12:15:27 +01:00
akira f352cb63b6 feat: Remove deprecated parameter 'direct_output' from ModIO classes
The RevPiModIO parameter 'direct_output' was replaced by
'shared_procimg' in the commit c11b435 from 2020-08-08. Users have
received a DepricatedWarning since then. With the upcoming version,
this parameter will be completely deleted.

Refs: c11b435
Signed-off-by: Sven Sager <akira@narux.de>
2023-11-01 12:15:27 +01:00
akira 1b92241d18 chore: Increase to RC2 of upcoming Release 2.7.0
Signed-off-by: Sven Sager <akira@narux.de>
2023-10-31 12:45:04 +01:00
akira 4167593309 packaging(deb): Create stable debian releases
Creating the stable branch after the RC will allow us to merge changes
to the Debian files from the debian_rc to the stable without
overwriting the values of the gbp.conf.
2023-10-27 16:50:21 +02:00
akira 4ce33f925b packaging(deb): Create debian release candidate packages 2023-10-27 16:49:09 +02:00
akira 653f90ab90 test: Add tests directory to migrate unit tests to project 2023-10-27 15:42:18 +02:00
akira ab2703a4d3 feat: Add context manager for ios
Signed-off-by: Sven Sager <akira@narux.de>
2023-10-27 15:42:18 +02:00
akira 9a90efeaf2 chore: Increase to RC1 of upcoming Release 2.7.0 2023-10-27 15:42:18 +02:00
akira ecf91f56db style: Format everything with black (100 characters per line)
Signed-off-by: Sven Sager <akira@narux.de>
2023-10-27 15:42:18 +02:00
akira ba708fc145 style: New line length 100 characters and using black as formatter
Signed-off-by: Sven Sager <akira@narux.de>
2023-10-27 15:42:18 +02:00
akira 801efe7fb4 build: Fix Makefile targets to match GNU coding standards
Signed-off-by: Sven Sager <akira@narux.de>
2023-10-27 15:42:17 +02:00
akira 37ccac7f79 chore: Update git ignore file
Signed-off-by: Sven Sager <akira@narux.de>
2023-10-27 15:35:45 +02:00
akira 8a8873e54a feat: Import DeviceType on module level
DeviceType can be used for advanced search filters in combination with
RevPiModIOSelected.

Signed-off-by: Sven Sager <akira@narux.de>
2023-09-15 16:35:00 +02:00
akira 9ad8ae0055 feat: Add new and missing ProductTypes to pictory.py module
Signed-off-by: Sven Sager <akira@narux.de>
2023-09-15 16:35:00 +02:00
akira 0bc398e627 fix: Insert correct LICENSE.txt file to project (LGPLv2)
On February 3, the project was placed under the LGPLv2 license, with
the consent of all contributors. Unfortunately, an incorrect version
of the license was inserted into the LICENSE.txt. This is now fixed
with the text of the LGPLv2, which has been valid for RevPiModIO2
since version 2.6.0.

Refs: 7d482d49
Signed-off-by: Sven Sager <akira@narux.de>
2023-09-15 16:31:01 +02:00
akira b1bf07f004 Merge tag '2.6.1' into pkg/debian
Release 2.6.1
2023-09-09 12:04:58 +02:00
akira acc59ccaa5 chore: Release 2.6.1
Signed-off-by: Sven Sager <akira@narux.de>
2023-09-09 11:55:49 +02:00
akira b279209b2b build: Add environment variable to set alternative venv path
Signed-off-by: Sven Sager <akira@narux.de>
2023-09-09 11:17:56 +02:00
akira b02c4011d7 fix: Changed misleading text of a ProcimgWriter warning
If the IOs cannot be written quickly enough by the ProcimgWriter,
this indicates high system utilization. The cycle function itself
would trigger a different message through the lck_refresh lock.

Signed-off-by: Sven Sager <akira@narux.de>
2023-09-09 11:11:57 +02:00
akira 502bff3028 Update changelog for 2.6.0-1 release
Signed-off-by: Sven Sager <s.sager@kunbus.com>
2023-08-18 11:17:32 +02:00
akira 8f1ba0094b packaging(deb): Start packaging branch
Signed-off-by: Sven Sager <akira@narux.de>
Signed-off-by: Sven Sager <s.sager@kunbus.com>
2023-08-18 11:17:30 +02:00
akira 521a0eb589 fix: Wrong values in buffer with autorefresh and shared_procimg active
When using `autofresh` in combination with `shared_procimg`, the
outputs were written to the process image, but kept with old values
in the local buffer. A query to a set output could therefore display
an incorrect value under certain circumstances.

Closes: #25
Signed-off-by: Sven Sager <akira@narux.de>
2023-08-18 08:33:34 +02:00
akira 1afe16053d fix: Set shared_procimg value is stored in the device
Classes have accessed a global shared_procimg value during
instantiation. However, this value is managed directly for each
device individually. There can be no global value.

Signed-off-by: Sven Sager <akira@narux.de>
2023-08-17 12:28:45 +02:00
akira 596658d656 fix: autorefresch with shared_procimg writes all outputs automatic
Fixes the bug that with automatic process image update and
shared_procimg, outputs of devices are also written without automatic
update enabled.

Signed-off-by: Sven Sager <akira@narux.de>
2023-08-17 12:28:45 +02:00
akira 70a0721680 style: With shared_procimg, save changed outputs in set instead of list
In sets, elements can only occur once. Therefore, no `if` statement
has to check whether the element is already included in the list.

Signed-off-by: Sven Sager <akira@narux.de>
2023-08-17 12:28:42 +02:00
akira 4cb0194f23 chore: Release 2.6.0
Signed-off-by: Sven Sager <akira@narux.de>
2023-06-28 16:03:04 +02:00
akira 82311c9b00 fix: Colors of LEDs are now controlled correctly
The wrong colors of the LEDs on the RevPi Connect 4 were controlled when
using the A* properties.

Signed-off-by: Sven Sager <akira@narux.de>
2023-06-28 15:34:54 +02:00
akira 9c66e0c1b6 ide: Add code inspection values to project
Signed-off-by: Sven Sager <akira@narux.de>
2023-06-20 10:47:46 +02:00
akira d29e733274 build: Add sphinx to build documentation
Signed-off-by: Sven Sager <akira@narux.de>
2023-06-20 10:39:29 +02:00
akira 6f4777317e fix: Changed DevSelect from namedtuple to a class
The class can be used for filtering devices and provides the user with
more extensive documentation.

Signed-off-by: Sven Sager <akira@narux.de>
2023-06-09 08:11:12 +02:00
akira 1de435b17f fix: Adjustment of the inheritance of devconfigure
When switching to the modular approach, the addresses of a core were
accidentally adopted as a global configuration.

Signed-off-by: Sven Sager <akira@narux.de>
2023-06-08 19:01:48 +02:00
akira 40ada14b07 chore: RC version 2.6.0rc6
Signed-off-by: Sven Sager <akira@narux.de>
2023-06-08 14:31:03 +02:00
akira c8b42b5202 fix: Add modular design for RevPiStatus byte
Signed-off-by: Nicolai Buchwitz <nb@tipi-net.de>
2023-06-08 14:23:08 +02:00
akira 207a8e92e8 Add __about__.py to handle version number of project in one place 2023-05-13 11:57:04 +02:00
akira 3771a7847e Replaces Master-Slave with Client-Server
Expunging all occurrences of inappropriate language of the query and
response paradigm of PLC communications. We are familiar with the Modbus
terminology and fully support this change.
https://www.modbus.org/docs/Client-ServerPR-07-2020-final.docx.pdf
2023-02-07 09:38:11 +01:00
akira 7d482d498c Change license from LGPLv3 to LGPLv2 after approval of all contributors
https://github.com/mindstorm38 approved license change
https://github.com/nbuchwitz approved license change
2023-02-03 12:10:43 +01:00
akira 8ddb323f24 Update documentation 2023-01-31 20:05:04 +01:00
akira 05e4ff96ca Code and project cleanup 2023-01-20 17:08:35 +01:00
akira 1b7397e608 Improved device search function and create run_net_plc shortcut 2023-01-20 12:31:59 +01:00
akira c7b2e59063 Merge branch 'feature/deviceselect' into srclayout
# Conflicts:
#	src/revpimodio2/modio.py
#	src/revpimodio2/netio.py
2023-01-20 11:18:08 +01:00
akira 1057e6daa4 Reorder package to src-layout.
Move package to src directory and update project base files for build
process.
2023-01-19 13:20:26 +01:00
akira 36c30ae6d6 replace_io accepts keyword wordorder
Now you can set the wordorder for a replaced IO on virtual devices. This
will help you to get the right values on modbus devices.
2023-01-12 23:26:09 +01:00
akira 0dd9c2637d Read export flag from piCtory for watchdog output
The watchdog output on a revpi connect will be set as exported, if you
set the export flag in pictory.
2022-12-22 16:40:33 +01:00
akira 41e13999ad Next release 2022-04-21 15:55:31 +02:00