Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Table of Contents

High-Side

Here is a practical example of implementing a High-Side circuit with a RevPi DIO | DO module.

Useful information for this article:
https://revolutionpi.com/tutorials/overview-revpi-i-o-modules/konfiguration-dio-di-do/

Features

all

A high-side switch refers only to the position of the switch. A high-side switch switches the positive supply voltage. See the illustration below.

All 14 output ports can supply 500mA simultaneously, in highside high-side mode.
Only all All outputs can be operated in individually set to push-pull, which is the default setting, or to high-side mode.

If the module gets too warm, all ports are switched off. This prevents the device from being damaged.
See under the tuple “Status” under the following link https://revolutionpi.com/forum/viewtopic.php?t=3389/tutorials/overview-revpi-i-o-modules/konfiguration-dio-di-do/

Wiring

Connect The RevolutionPi Revolution Pi DIO as in the Following picture

Image Removed

Image Removed

  • connect 12 V - 24 V on X4, on the Bottom of the device

  • connect 12 V - 24 V on X2 for Input, on the Top of the device

  • connect 12 V - 24 V on X2 for Output, on the Top of the device

  • connect all Grounds

  • connect

    Note

    Be aware that the ground of the X2 connector and the X4 connector are galvanically isolated.

    Drawio
    mVer2
    zoom1
    simple0
    inComment0
    custContentId3052503484
    pageId2680520754
    lbox1
    diagramDisplayNameUntitled Diagram-1691063845588.drawio
    contentVer1
    revision1
    baseUrlhttps://kunbus-gmbh.atlassian.net/wiki
    diagramNameUntitled Diagram-1691063845588.drawio
    pCenter0
    width664
    links
    tbstyle
    height751

    DIO

    Drawio
    mVer2
    zoom1
    simple0
    inComment0
    custContentId3051783178
    pageId2680520754
    lbox1
    diagramDisplayNameUntitled Diagram-1691063884728.drawio
    contentVer1
    revision1
    baseUrlhttps://kunbus-gmbh.atlassian.net/wiki
    diagramNameUntitled Diagram-1691063884728.drawio
    pCenter0
    width664
    links
    tbstyle
    height763

    DO

    Drawio
    mVer2
    zoom1
    simple0
    inComment0
    custContentId3052536274
    pageId2680520754
    lbox1
    diagramDisplayNameUntitled Diagram-1691063930206.drawio
    contentVer1
    revision1
    baseUrlhttps://kunbus-gmbh.atlassian.net/wiki
    diagramNameUntitled Diagram-1691063930206.drawio
    pCenter0
    width641
    links
    tbstyle
    height530

    1. Connect 12V -24V to the X4 plug located on the bottom of the device.

    2. Connect 12V -24V to the X2 plug on the top of the unit to supply power to the output ports.

    3. Connect 12V -24V to the X2 plug on the top of the unit to supply power to the Input ports.

    4. Connect all the grounds marked on the plugs X4 and X2 together.

    5. Connect one port from Output 1 to 14 to the electrical consumer [M], [M] can be a 24V LED

    connect
    1. Connect the ground from the electrical consumer [M] to the same ground as the

    RevolutionPi
    1. Revolution Pi (X4 plug)

    Connect the extension module with a base module

    Connect the RevolutionPi Revolution Pi DIO to the RevolutionPi Connect Revolution Pi, with a PiBridge.

    Image Removed

    Image Added

    Image Added

    RevolutionPi IO-Modules FAQ |

    PiCtory Configuration

    The following describes how to set up the PiCtory configuration to run the DIO in Highhigh-Side side mode.

    For this example, you can use a RevolutionPi Revolution Pi Core or Connect. The only difference for this example is which base module is inserted into PiCtory.

    Image RemovedImage Added

    Set output to high-Side

    Image Removed

    mode

    Image Added

    for high-side mode, 2 bytes are available to switch each output from push-pull to high-side.
    Set the corresponding bit to 1 for high-side mode and 0 for push-pull mode. The default value is 0x0000.

    For example, you want to run Output O_14, O_10 and O_2 in high-side mode.
    The Binary value is 00101000000000102 = 10.24210

    10.242 is the decimal value you need to enter into the corresponding field.

    Save the config like in the picture below, with “Save as Start-Config“

    Image Removed

    Config”. This Configuration will be loaded at each boot.

    Image Added

    Now you have to reset the driver.

    Tools → “Reset Driver”

    Image Added

    or

    Code Block
    piTest -x #driver reset

    Switching output with piTest from

    piControl

    PiControl

    Check if Device is recognized that the Revolution Pi DIO is detected correctly.

    Code Block
    piTest -d
    Code Block
    Found 2 devices:
    
    Address: 0 module type: 105 (0x69) RevPi Connect V1.0
    Module is present
         input offset: 113 length: 6
        output offset: 119 length: 5
    
    Address: 31 module type: 96 (0x60) RevPi DIO V1.4
    Module is present
         input offset: 0 length: 70
        output offset: 70 length: 18

    Control of the DIO continuallyOutput ports

    Switch Output 1 (0_1)

    Code Block
    piTest -1 -r O_1
    Bit value: 0
    
    piTest -w O_1,1
    Set bit 0 on byte at offset 70. Value 1
    
    piTest -1 -r O_1
    Bit value: 1

    If output 1 = 1, the circuit is closed.

    If output 1 = 0, then the circuit is not closed.

    Push-Pull

    Here is a practical example of implementing a push-pull circuit with a RevPi DIO | DO module.

    Useful information for this article:
    https://revolutionpi.com/tutorials/overview-revpi-i-o-modules/konfiguration-dio-di-do/

    Wiring

    Here, there are two possibilities for a circuit:

    Note

    Be aware that the ground of the X2 connector and the X4 connector are galvanically isolated.

    Push Mode

    Drawio
    mVer2
    zoom1
    simple0
    inComment0
    custContentId3052863606
    pageId2680520754
    lbox1
    diagramDisplayNameUntitled Diagram-1691063845588.drawio
    contentVer2
    revision2
    baseUrlhttps://kunbus-gmbh.atlassian.net/wiki
    diagramNamepull mode
    pCenter0
    width657
    links
    tbstyle
    height751

    Pull Mode

    Drawio
    mVer2
    zoom1

    Read Value from Input 1 (I_1)

    Code BlockpiTest -1 -
    simple0
    inComment0
    custContentId3052699692
    pageId2680520754
    lbox1
    diagramDisplayNameUntitled Diagram-1691063845588.drawio
    contentVer2
    revision2
    baseUrlhttps://kunbus-gmbh.atlassian.net/wiki
    diagramNamePush mode
    pCenter0
    width664
    links
    tbstyle
    height751

    PiCtory Configuration

    Image Added

    The register “OutputPushPull” contains a bit field in which is defined which function is active:

    • 0 := Push-Pull

    • 1 := High-Side

    For example, the following configuration should be created:

    11 1111 1111 1110 dual = 16382 decimal

    • Write the decimal value into the variable “OutputPushPull”

    • Save the PiCtory configuration

    • Restart cyclic data communication

    Switch

    Code Block
    languagebash
    piTest -w O_1,1 # Output 1 := 24V
    piTest -w O_1,0 # Output 1 :=  0

    Read input values

    How to read values from the inputs of the RevPi DIO | DI

    Code Block
    languagebash
    piTest -r I_1 #
    read one time
     Input 1 := 12V
    1
    
    piTest -r I_1 # Input 1 :=  
    # read continuously Bit value: 1Image Removed
    0V
    0
    Drawio
    mVer2
    zoom1
    simple0
    inComment0
    custContentId3053125655
    pageId2680520754
    lbox1
    diagramDisplayNameUntitled Diagram-1691063845588.drawio
    contentVer1
    revision1
    baseUrlhttps://kunbus-gmbh.atlassian.net/wiki
    diagramNameINPUT-1691063845588.drawio
    pCenter0
    width594
    links
    tbstyle
    height751

    Input Mode

    If you would like to know more about the input modes, please watch our video.

    https://revolutionpi.com/tutorials/video-tutorials#VT14 | Tutorial 14 – Counter and Encoder

    Encoder

    if you want to use an encoder an any input port of the RevPi DIO | DI. then set the variable

    InputMode_x_yz to Encoder

    Image Added

    Counter

    All inputs, of the DIO, DI that have been activated, can count individually on rising or falling edge.

    Image Added

    To read the value of on counting register:

    Code Block
    piTest -r Counter_1_xyz

    If there are incorrect inputs, you should switch on the debouncing. By default, this is switched off.
    Set it to 25us, 750us or 3ms.

    Image Added

    PWM

    To activate the PWM signal, you have to set the following variable to 1.

    Code Block
    OutputPWMActive_i04 = 1

    In the PiCtory you can configure the period of the PWM Signal

    This function is available on the RevPi DIO | DO

    Image Added

    each individual output can send out a PWM signal.

    Image Added
    Info

    You can select only one frequency for all outputs.

    Note: If you would like to know more about the input modes, please watch our video.

    https://revolutionpi.com/tutorials/video-tutorials#VT14 | Tutorial 15 – PWM on RevPi DIO

    Troubleshooting

    PiCtory Checklist

    Revolution Pi Checklist

    https://revolutionpi.com/tutorials/images/firmware-update

    Further Information

    https://kunbus-gmbh.atlassian.net/wiki/spaces/KS/pages/2629566465/RevolutionPi+IO-Modules+FAQ?parentProduct=JSM-Portal&parentProductContentContainerId=10001&initialAllowedFeatures=disable-login-flow.disable-share&locale=en-US#How-to-wire-the-RevolutionPi-AIO%2C-MIO%2C-DIO%2C-DI%2C-DO-modules%3F

    https://kunbus-gmbh.atlassian.net/wiki/spaces/KS/pages/2629566465/RevolutionPi+IO-Modules+FAQ?parentProduct=JSM-Portal&parentProductContentContainerId=10001&initialAllowedFeatures=disable-login-flow.disable-share&locale=en-US#How-much-RevPi-IO-Modules-can-I-connect-to-a-RevPi

    https://revolutionpi.com/io-modules?noredirect=en-US