Welcome to the Revolution Pi with Python

Program your Revolution Pi of Kunbus GmbH with Python!

Python module

This module provides you with various functions to access the hardware of the Revolution Pi with your Python program. It does not matter whether you come from the PLC sector and program cyclically or event-based as an application developer of e.g. Raspberry Pi.

PLC System for software, network and MQTT

With our RevPiPyPLC system you can make fast IO-Checks over the network, upload your control program, start it at system start and transfer all IO data via MQTT. Or simply write data from any Python system to the process image.

And there are no license fees!

Source example RevPiModIO version 2 – current

import revpimodio2

def eventfunction(ioname, iovalue):
    """Event function, which is executed when the value changes."""
    print("Input {} has value {}".format(ioname, iovalue))

# Instantiate RevPiModIO
rpi = revpimodio2.RevPiModIO(autorefresh=True)

# Catch Ctrl+C signal and exit program clean
rpi.handlesignalend()

# Register input events
rpi.io.I_1.reg_event(eventfunction)
rpi.io.I_2.reg_event(eventfunction)

# Start event processing (program will block here)
print("start mainloop")
rpi.mainloop()

More examples

Blog

Version 2.5.8

Important update Fixes errors when using shared_procimg when querying the output status, especially in .cycleloop(…). The status of set outputs was one cycle behind. So the values of the outputs in the next cycle were still at the old status. Offset check of the entire process image and omission of overlapping IOs. When using several …

Version 2.5.7

Important update Corrects errors in the length specifications of the memory areas from the process image if the piCtory configurations have gaps. This has been discovered so far with the “Modbus Master 150” module. The error means that the IOs of modules behind the incomplete module are not correctly synchronized. Flat: Switch button and relay …

Version 2.5.6

Important update! Fixes cycle problem with shared_procimg=True As soon as a new value was assigned to an output, RevPiModIO immediately wrote it into the process image. Outputs may only be written to the process image after the cycle function has been completely processed (when using .cycleloop) or after calling .writeprocimg. The error is not relevant …