Difference between revisions of "Digital Inputs / Outputs"
Line 30: | Line 30: | ||
**Set DOut 25 to true to switch on the lamp | **Set DOut 25 to true to switch on the lamp | ||
<br clear=all> | <br clear=all> | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
==Nomenclature== | ==Nomenclature== |
Revision as of 15:47, 18 June 2018
The CPR robolink control electronics come with a digital input / output module. This page shows how to connect actuators, valves or sensors to the module.
The Digital IO module provides 7 digital inputs and 7 digital outputs. The inputs are electrically decoupled from the control electronics by an optocoupler and accept 24V input signals. The outputs are reed relays which can drive up to 500 mA per channel. The DigitalIO module does not provide its own supply voltage for the DIOs. However, the main supply of the Modular Control Electronics can be connected to the SUP pin (see section below) to supply power to the components connected to the digital outputs or the signal pins (1-7) of the digital inputs.
Indicators: When the state of a sensor input or and output changes the orange LED on the top is blinking once.
Electrical connections
Digital Inputs:
- Disconnect the robot/electronics from power.
- Connect the ground pin (Output connector 1, to GND
- Supply 24V to one of the input pins
- Example on the left: 24V via switch to input pin 4
- Result in CPRog: digital input Din24 is triggered
Digital Outputs
- Disconnect the robot/electronics from power.
- Connect the supply pin to 24V power supply
- The supply is forwarded to one of the outputs pins via reed relays
- Connect a valve or another component to the output pin
- Connect the component to GND to close the electrical circuit
- See the example with the lamp on output 5 on the left.
- Connect electronics/robot to power, ensure the emergency stop button is disengaged.
- Start CPRog:
- Reset and Enable the robot
- Set DOut 25 to true to switch on the lamp
Nomenclature
To control the IOs in Software, all CPR robots provide digital inputs and outputs are named channel 1 through 4.
This should get clearer as you read the "How to use the inputs" and "How to use the outputs" paragraphs.
In contrast, the igus robolink arms and gantry robots use the following nomenclature:
- For the first DIO-Modul: Channels 21 through 27, i.e. DOut21, DOut22,... or DIn21, DIn22,...
- For the second DIO-Modul: Channels 31 through 37
- For the third DIO-Modul: Channels 41 through 47
The maximum amount of DIO modules installed in the control electronics is currently 3.
Attention: The DIO are also used by the PLC Interface (if active), refer to this.
How to use the outputs
The output signals can be switched on or off with the 'Digital Out' command in CPRog (see screenshot on the right).
Please be aware that the outputs can only be switched on when the robot is enabled!
The outputs must not drive more then 500 mA, also not at startup! Avoid higher currents, e.g. caused by the inrush current of capacitors! Use a secondary relay in this case to prevent damage to the DIO module.
Here an example on How to operate a gripper using CPRog and the Modular Control Electronics
How to use the inputs
The digital inputs can be used e.g. in if-then-else statements.
The example program on the right shows a simple test. The first input of the first DIO module (DIn21) is checked. If it is true than the first output of the first DIO module (DOut21) is switched on; otherwise it is switched off.