
This is a PROFIBUS software stack implementing the layers 1 (PHY), 2 (FDL) and 7 (DP) of the PROFIBUS protocol.

We are currently able to talk to a Siemens ET-200S slave, read its inputs and write to the outputs. So the basic hardware (OSI layer 1) is implemented and works as expected. Software (OSI layer 2 and 7) is work in progress. Most of the implemented features work correctly. A the Raspberry Pi can act as a DP-Master (class 1) with the current stack.
Performance:
A typical Data_Exchange (that is sending and receiving user
data) cycle takes about 0.3 milliseconds with CPython on a Raspberry Pi 2.
The awlsim Soft-PLC software can be
used to control hardware connected to PROFIBUS-DP
See the awlsim
and PiLC
pages for details.
pyprofibus can be used to connect LinuxCNC to PROFIBUS-DP slaves.
A LinuxCNC example configuration is included in pyprofibus. See the linuxcnc-demo subdirectory.
pyprofibus includes an example_dummy.py
executable file that can be used to run
the stack without any actual PROFIBUS hardware.
The dummy PHY will emulate a simple slave device in such a way that
example_dummy.py can run a DPM1 on that virtual PHY device.
Feel free to use this dummy to experiment with the stack.
-
pyprofibus release 1.6
.tar.xz archive
16 August 2019 / PGP signature - Older pyprofibus releases can be found here.
Latest bleeding edge pyprofibus can be downloaded using the Git version control system as follows:
via https: | git clone https://git.bues.ch/git/pyprofibus.git |
or via http: | git clone http://git.bues.ch/git/pyprofibus.git |
or via git: | git clone git://git.bues.ch/pyprofibus.git |
or by downloading the
pyprofibus snapshot archive.
To browse the Git repository online, go to the
git web interface.
A mirror of the repository is available on
GitHub,
GitLab,
Bitbucket and on
NotABug.org.
If you want to contribute to pyprofibus, please read
the contribution guidelines first.
If you find any bugs in pyprofibus or if you have any suggestion for new
features, we would like to hear from you.
Your help is greatly appreciated and will help to create better
software and improve the overall experience for everybody.
So don't hesitate to report anything that that limits your pyprofibus usage.
If you have got any code improvements or other improvements that should be merged into the project, please send such enhancements to the pyprofibus maintainer.
Please read the contribution guidelines first.
Copyright (C)
Michael Büsch
Licensed under the terms of the
GNU General Public License version 2
.
See the sourcecode for details.