Homepage

Welcome to the “python3-revpimodio” module!

With this module the RevolutionPi of the Kunbus GmbH can be programmed very easily with Python3 – And there are no license fees!

It offers a large scale of functions for cyclic or event-based programming.

Source example RevPiModIO version 2 – current

import revpimodio2

# Instantiate RevPiModIO. This will read the piCtory configuration
# automatically.
myrevpi = revpimodio2.RevPiModIO()

# Read data from process image
myrevpi.readprocimg()

# Switch LED A1 green and A2 red
myrevpi.core.A1 = revpimodio2.GREEN
myrevpi.core.A2 = revpimodio2.RED

# Get inputs and set outputs
inputpin = myrevpi.io.I_1.value
myrevpi.io.O_1.value = inputpin
# The names have to be equal to your piCtory configuration

# Write data to process image
myrevpi.writeprocimg()

More examples

Source example RevPiModIO version 1 - deprecated
import revpimodio

# Instantiate RevPiModIO. This will read the piCtory configuration
# automatically.
myrevpi = revpimodio.RevPiModIO()

# Read data from process image
myrevpi.devices.readprocimg()

# Switch LED A1 green and A2 red
myrevpi.devices.core.A1 = revpimodio.GREEN
myrevpi.devices.core.A2 = revpimodio.RED

# Get inputs and set outputs
inputpin = myrevpi.devices["RevPi DIO"]["I_1"].value
myrevpi.devices["RevPi DIO"]["O_1"].value = inputpin
# The names have to be equal to your piCtory configuration

# Write data to process image
myrevpi.devices.writeprocimg()

More examples

Blog

Version 2.2.3

Improves module performance Set internal cycle time depending on the core version at instantiation. This improves the event system and responds much faster to IO changes – especially with Core3 Runtime monitoring integrated for event functions. Warnings are issued if functions have too long runtimes The “Export” flag from piCtory can now be retrieved via …