C.26. Local GPIO

Driver Name:

Local GPIO

Supported RML Commands:

GPI Enable ['GE']
GPI Set ['GI']
GPO Set ['GO']

This driver supports a variety of GPIO devices, including:

15 Pin Joystick Port
USB HID Devices
MeasurementComputing GPIO Cards

C.26.1. 15 Pin Joystick Port

Joystick support utilizes the Linux Input Device subsystem. Inputs are active-low, and should be wired as follows:

Table C.2. 15 Pin Joystick Port Wiring

PinSignal
2Input 1
4Ground
  
7Input 2
5Ground
  
10Input 3
12Ground
  
14Input 4
12Ground

In addition, you will need to connect 47 kohm resistors between the following pins: 1-3, 6-8, 9-11 and 13-15. While not strictly needed for the GPI portion of the interface to work, the kernel's analog joystick driver will refuse to initialize the port if these resistors (or a real joystick) are not present.

The device name of the joystick will be one of the /dev/input/eventn devices.

NOTE: There have been reports that some port models do not internally connect pin 12 to ground. The symptom of this situation will be that Inputs 1 and 2 work, but not Inputs 3 and 4. If this is the case, connecting the ground for Inputs 3 and 4 to pins 04 or 05 should remedy the problem.

C.26.2. MeasurementComputing GPIO Cards

The following MeasurementComputing cards are supported:

PCI-PDIS08
PCI-PDIS16
PCI-DIO24

The device name for the card should be /dev/gpion.

C.26.2.1. PCI-PDIS08 and PCI-PDIS16

The Measurement Computing PCI-PDIS08 and PCI-PDIS16 boards feature floating, opto-isolated inputs. The inputs are not polarity sensitive and may be driven by either AC or DC. The outputs are electro-mechanical relays with dry contacts.

Table C.3. PCI-PDIS08 and PCI-PDIS16 Connector Pinout (DB37F)

PinSignal
1Input 8/16
20Input 8/16
  
2Input 7/15
21Input 7/15
  
3Input 6/14
22Input 6/14
  
4Input 5/13
23Input 5/13
  
5Input 4/12
24Input 4/12
  
6Input 3/11
25Input 3/11
  
7Input 2/10
26Input 2/10
  
8Input 1/9
27Input 1/9
  
9Output 8/16 C
28Output 8/16 N/O
  
10Output 7/15 C
29Output 7/15 N/O
  
11Output 6/14 C
30Output 6/14 N/O
  
12Output 5/13 N/C
13Output 5/13 N/O
31Output 5/13 C
  
14Output 4/12 N/C
32Output 4/12 N/O
33Output 4/12 C
  
15Output 3/11 N/C
16Output 3/11 N/O
34Output 3/11 C
  
17Output 2/10 N/C
35Output 2/10 N/O
36Output 2/10 C
  
18Output 1/9 N/C
19Output 1/9 N/O
37Output 1/9 C

C.26.2.2. PCI-DIO24

The Measurement Computing PCI-DIO24 board features 24 bi-directional, TTL level signal lines, referenced to a common ground. The driver can be configured to use all of the lines as inputs or outputs (mixing inputs and outputs on the same board is not supported). When used as inputs, termination resistor packs should be installed.

Table C.4. PCI-DIO24 Connector Pinout (DB37F)

PinSignal
37Input 1
36Input 2
35Input 3
34Input 4
33Input 5
32Input 6
31Input 7
30Input 8
10Input 9
9Input 10
8Input 11
7Input 12
6Input 13
5Input 14
4Input 15
3Input 16
29Input 17
28Input 18
27Input 19
26Input 20
25Input 21
24Input 22
23Input 23
22Input 24
11Ground
13Ground
15Ground
17Ground
19Ground
21Ground
18+5 vdc
20+5 vdc
16+12 vdc
14+-12 vdc