XPC Target Io Ref PDF
XPC Target Io Ref PDF
Modeling
Simulation
Implementation
www.mathworks.com Web
comp.soft-sys.matlab Newsgroup
508-647-7000 Phone
508-647-7001 Fax
For contact information about worldwide offices, see the MathWorks Web site.
i
RS-232 Receive Message Structure (Asynchronous) . . . . . . . . 2-34
Supported Data Types for Message Fields . . . . . . . . . . . . . . . . 2-35
ii Contents
CAN driver blocks for the CAN-AC2 (ISA)
with Philips PCA 82C200 CAN-Controller . . . . . . . . . . . . . . . 4-8
Setup Driver Block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4-9
Send Driver Block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4-11
Receive Driver Block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4-13
iii
CAN I/O Support for FIFO
5
Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-2
FIFO Mode drivers for CAN boards from Softing . . . . . . . . . . . 5-3
Examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-40
Example 1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-40
Example 2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-42
Example 3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-43
Example 4 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-44
Example 5 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-45
Example 6 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-46
iv Contents
ADDI-DATA
6
APCI-1710 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-3
APCI-1710 Incremental Encoder . . . . . . . . . . . . . . . . . . . . . . . . 6-3
PA-1700 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-6
PA-1700 Incremental Encoder . . . . . . . . . . . . . . . . . . . . . . . . . . 6-6
Advantech
7
PCL-1800 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-3
PCL-1800 Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-3
PCL-1800 Analog Output (D/A) . . . . . . . . . . . . . . . . . . . . . . . . . . 7-5
PCL-1800 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-6
PCL-1800 Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-7
PCL-711B . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-8
PCL-711B Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-8
PCL-711B Analog Output (D/A) . . . . . . . . . . . . . . . . . . . . . . . . 7-10
PCL-711B Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-12
PCL-711B Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-12
PCL-726 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-14
PCL-726 Analog Output (D/A) . . . . . . . . . . . . . . . . . . . . . . . . . . 7-14
PCL-726 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-16
PCL-726 Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-17
PCL-727 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-18
PCL-727 Analog Output (D/A) . . . . . . . . . . . . . . . . . . . . . . . . . . 7-18
PCL-727 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-20
PCL-727 Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-21
PCL-728 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-22
PCL-728 Analog Output (D/A) . . . . . . . . . . . . . . . . . . . . . . . . . . 7-22
v
PCL-812 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-24
PCL-812 Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-24
PCL-812 Analog Output (D/A) . . . . . . . . . . . . . . . . . . . . . . . . . . 7-26
PCL-812 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-27
PCL-812 Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-28
PCL-812PG . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-29
PCL-812PG Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . . . . . 7-29
PCL-812PG Analog Output (D/A) . . . . . . . . . . . . . . . . . . . . . . . 7-31
PCL-812PG Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-32
PCL-812PG Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-33
PCL-818 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-35
PCL-818 Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-35
PCL-818 Analog Output (D/A) . . . . . . . . . . . . . . . . . . . . . . . . . . 7-37
PCL-818 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-38
PCL-818 Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-39
PCL-818H . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-40
PCL-818H Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . . . . . . 7-40
PCL-818H Analog Output (D/A) . . . . . . . . . . . . . . . . . . . . . . . . 7-42
PCL-818H Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-42
PCL-818H Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-43
PCL-818HD . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-44
PCL-818HD Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . . . . . 7-44
PCL-818HD Analog Output (D/A) . . . . . . . . . . . . . . . . . . . . . . . 7-46
PCL-818HD Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-46
PCL-818HD Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-47
PCL-818HG . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-48
PCL-818HG Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . . . . . 7-48
PCL-818HG Analog Output (D/A) . . . . . . . . . . . . . . . . . . . . . . . 7-50
PCL-818HG Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-51
PCL-818HG Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-52
vi Contents
PCL-818L . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-53
PCL-818L Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . . . . . . . 7-53
PCL-818L Analog Output (D/A) . . . . . . . . . . . . . . . . . . . . . . . . 7-55
PCL-818L Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-56
PCL-818L Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-57
Burr-Brown
8
PCI-20003M . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-3
PCI-20003M Analog Output (D/A) . . . . . . . . . . . . . . . . . . . . . . . 8-3
PCI-20019M . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-5
PCI-20019M Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . . . . . . 8-5
PCI-20023M . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-8
PCI-20023M Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . . . . . . 8-8
PCI-20041C . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-11
PCI-20041C Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-11
PCI-20041C Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-12
PCI-20098 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-14
PCI-20098C Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . . . . . 8-14
PCI-20098C Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-15
PCI-20098C Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-16
vii
ComputerBoards
9
CIO-CTR05 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-5
CIO-CTR05 Counter PWM . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-6
CIO-CTR05 counter PWM & ARM . . . . . . . . . . . . . . . . . . . . . . . 9-7
CIO-CTR05 Counter FM . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-8
CIO-CTR05 Counter FM & ARM . . . . . . . . . . . . . . . . . . . . . . . . 9-9
CIO-CTR05 PWM Capture . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-11
CIO-CTR05 FM Capture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-12
CIO-CTR10 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-13
CIO-CTR10 Counter PWM . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-14
CIO-CTR10 Counter PWM & ARM . . . . . . . . . . . . . . . . . . . . . . 9-15
CIO-CTR10 Counter FM . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-16
CIO-CTR10 Counter FM & ARM . . . . . . . . . . . . . . . . . . . . . . . 9-17
CIO-CTR10 PWM Capture . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-19
CIO-CTR10 FM Capture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-20
CIO-DAC08/16 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-23
CIO-DAC08/16 Analog Output (D/A) . . . . . . . . . . . . . . . . . . . . 9-23
CIO-DAC16/16 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-27
CIO-DAC16/16 Analog Output (D/A) . . . . . . . . . . . . . . . . . . . . 9-27
CIO-DAS16/300 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-29
CIO-DAS16/330 Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . . 9-30
viii Contents
CIO-DAS16JR/16 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-36
CIO-DAS16JR/16 Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . 9-37
CIO-DAS1601/12 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-38
CIO-DAS1601/12 Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . 9-39
CIO-DAS1601/12 Analog Output (D/A) . . . . . . . . . . . . . . . . . . 9-40
CIO-DAS1601/12 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . 9-41
CIO-DAS1601/12 Digital Output . . . . . . . . . . . . . . . . . . . . . . . 9-42
CIO-DAS1602/12 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-44
CIO-DAS1602/12 Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . 9-45
CIO-DAS1602/12 Analog Output (D/A) . . . . . . . . . . . . . . . . . . 9-46
CIO-DAS1602/12 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . 9-47
CIO-DAS1602/12 Digital Output . . . . . . . . . . . . . . . . . . . . . . . 9-48
CIO-DAS1602/16 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-50
CIO-DAS1602/16 Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . 9-51
CIO-DAS1602/16 Analog Output (D/A) . . . . . . . . . . . . . . . . . . 9-52
CIO-DAS 1602/16 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . 9-53
CIO DAS1602/16 Digital Output . . . . . . . . . . . . . . . . . . . . . . . 9-54
CIO-DDA06/16 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-61
CIO-DDA06/16 Analog Output (D/A) . . . . . . . . . . . . . . . . . . . . 9-62
CIO-DDA06/16 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . 9-63
CIO-DDA06/16 Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . 9-64
CIO-DIO24 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-66
CIO-DIO24 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-66
CIO-DIO24 Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-67
CIO-DIO24H . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-69
CIO-DIO24H Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-69
CIO-DIO24H Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-70
ix
CIO-DIO48 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-72
CIO-DIO48 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-72
CIO-DIO48 Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-73
CIO-DIO48H . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-75
CIO-DIO48H Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-75
CIO-DIO48H Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-77
CIO-DIO96 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-78
CIO-DIO96 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-78
CIO-DIO96 Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-79
CIO-DIO192 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-81
CIO-DIO192 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-81
CIO-DIO192 Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-82
CIO-DO24DD . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-84
CIO-DO24DD Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . 9-84
CIO-PDISO16 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-86
CIO-PDISO16 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-86
CIO-PDISO16 Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . 9-88
CIO-QUAD02 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-89
CIO-QUAD02 Incremental Encoder . . . . . . . . . . . . . . . . . . . . . 9-89
CIO-QUAD04 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-92
CIO-QUAD04 Incremental Encoder . . . . . . . . . . . . . . . . . . . . . 9-92
PC104-DAS16JR/12 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-97
PC104-DAS16JR/12 Analog Input (A/D) . . . . . . . . . . . . . . . . . 9-97
PC104-DAS16JR/12 Digital Input . . . . . . . . . . . . . . . . . . . . . . 9-99
PC104-DAS16JR/12 Digital Output . . . . . . . . . . . . . . . . . . . . 9-100
x Contents
PC104-DAS16JR/16 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-101
PC104-DAS16JR/16 Analog Input (A/D) . . . . . . . . . . . . . . . . 9-101
PC104-DAS16JR/16 Digital Input . . . . . . . . . . . . . . . . . . . . . 9-103
PC104-DAS16JR/16 Digital Output . . . . . . . . . . . . . . . . . . . . 9-104
PC104-DIO48 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-105
PC104-DIO48 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . 9-106
PC104-DIO48 Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . 9-107
PCI-CTR05 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-108
PCI-CTR05 Counter PWM . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-109
PCI-CTR05 Counter PWM & ARM . . . . . . . . . . . . . . . . . . . . . 9-110
PCI-CTR05 Counter FM . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-111
PCI-CTR05 Counter FM & ARM . . . . . . . . . . . . . . . . . . . . . . 9-112
PCI-CTR05 PWM Capture . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-114
PCI-CTR05 FM Capture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-115
PCI-DAS1200 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-116
PCI-DAS1200 Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . . . 9-116
PCI-DAS1200 Analog Output (D/A) . . . . . . . . . . . . . . . . . . . . 9-117
PCI-DAS1200 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . 9-118
PCI-DAS1200 Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . 9-119
PCI-DAS1200/JR . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-121
PCI-DAS1200/JR Analog Input (A/D) . . . . . . . . . . . . . . . . . . . 9-121
PCI-DAS1200/JR Digital Input . . . . . . . . . . . . . . . . . . . . . . . . 9-122
PCI-DAS1200/JR Digital Output . . . . . . . . . . . . . . . . . . . . . . 9-123
PCI-DAS1602/12 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-125
PCI-DAS1602/12 Analog Input (A/D) . . . . . . . . . . . . . . . . . . . 9-126
PCI-DAS1602/12 Analog Output (D/A) . . . . . . . . . . . . . . . . . . 9-127
PCI-DAS 1602/12 Digital Input . . . . . . . . . . . . . . . . . . . . . . . 9-128
PCI-DAS1602/12 Digital Output . . . . . . . . . . . . . . . . . . . . . . . 9-129
PCI-DAS1602/16 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-131
PCI-DAS1602/16 Analog Input (A/D) . . . . . . . . . . . . . . . . . . . 9-132
PCI-DAS1602/16 Analog Output (D/A) . . . . . . . . . . . . . . . . . . 9-133
PCI-DAS 1602/16 Digital Input . . . . . . . . . . . . . . . . . . . . . . . 9-134
PCI-DAS1602/16 Digital Output . . . . . . . . . . . . . . . . . . . . . . . 9-135
xi
PCI-DDA02/12 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-137
PCI-DDA02/12 Analog Output (D/A) . . . . . . . . . . . . . . . . . . . 9-137
PCI-DDA02/12 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . 9-139
PCI-DDA02/12 Digital Output . . . . . . . . . . . . . . . . . . . . . . . . 9-140
PCI-DDA04/12 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-142
PCI-DDA04/12 Analog Output (D/A) . . . . . . . . . . . . . . . . . . . 9-142
PCI-DDA04/12 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . 9-144
PCI-DDA04/12 Digital Output . . . . . . . . . . . . . . . . . . . . . . . . 9-145
PCI-DDA08/12 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-147
PCI-DDA08/12 Analog Output (D/A) . . . . . . . . . . . . . . . . . . . 9-147
PCI-DDA08/12 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . 9-149
PCI-DDA08/12 Digital Output . . . . . . . . . . . . . . . . . . . . . . . . 9-150
PCI-DIO24 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-152
PCI-DIO24 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-152
PCI-DIO24 Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-153
.................................................. 9-154
PCI-DIO24H . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-156
PCI-DIO24H Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-156
PCI-DIO24H Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . 9-157
PCI-DIO48 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-159
PCI-DIO48 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-159
PCI-DIO48 Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-161
PCI-DIO96H . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-163
PCI-DIO96H Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-163
PCI-DIO96H Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . 9-165
PCI-QUAD04 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-167
PCI-QUAD04 Incremental Encoder . . . . . . . . . . . . . . . . . . . . 9-167
xii Contents
Diamond
10
Diamond-MM . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-3
Diamond-MM Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . . . . 10-4
Diamond-MM Analog Output (D/A) . . . . . . . . . . . . . . . . . . . . . 10-5
Diamond-MM Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-6
Diamond-MM Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . 10-7
Diamond-MM-32 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-8
Diamond-MM-32 Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . 10-9
Diamond-MM-32 Analog Output (D/A) . . . . . . . . . . . . . . . . . . 10-10
Diamond-MM-32 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . 10-11
Diamond-MM-32 Digital Output . . . . . . . . . . . . . . . . . . . . . . . 10-12
Quartz-MM 5 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-14
Quartz-MM 5 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-14
Quartz-MM 5 Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . 10-15
Quartz-MM5 Counter PWM . . . . . . . . . . . . . . . . . . . . . . . . . . 10-17
Quartz-MM5 counter PWM & ARM . . . . . . . . . . . . . . . . . . . . 10-18
Quartz-MM5 Counter FM . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-19
Quartz-MM5 Counter FM & ARM . . . . . . . . . . . . . . . . . . . . . 10-20
Quartz-MM5 PWM Capture . . . . . . . . . . . . . . . . . . . . . . . . . . 10-22
Quartz-MM5 FM Capture . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-23
Quartz-MM 10 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-24
Quartz-MM 10 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . 10-24
Quartz-MM 10 Digital Output . . . . . . . . . . . . . . . . . . . . . . . . 10-25
Quartz-MM 10 Counter PWM . . . . . . . . . . . . . . . . . . . . . . . . . 10-27
Quartz-MM 10 Counter PWM & ARM . . . . . . . . . . . . . . . . . . 10-28
Quartz-MM 10 Counter FM . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-29
Quartz-MM 10 Counter FM & ARM . . . . . . . . . . . . . . . . . . . . 10-30
Quartz-MM 10 PWM Capture . . . . . . . . . . . . . . . . . . . . . . . . . 10-32
Quartz-MM 10 FM Capture . . . . . . . . . . . . . . . . . . . . . . . . . . 10-33
xiii
Gespac
11
GESADA-1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-3
GESADA-1 Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . . . . . . 11-3
GESADA-1 Analog Output (D/A) . . . . . . . . . . . . . . . . . . . . . . . 11-4
GESPIA-2A . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-6
GESPIA-2A Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-7
GESPIA-2A Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-8
Humusoft
12
AD 512 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-3
AD 512 Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-4
AD 512 Analog Output (D/A) . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-5
AD 512 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-6
AD 512 Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-7
Keithley Metrabyte
13
DAS-1800HR . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13-3
DAS-1800HR Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . . . . 13-4
DAS-1800HR Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13-5
DAS-1800HR Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . 13-6
KCPI-1801HC . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13-7
KPCI-1801HC Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . . . 13-8
KPCI-1801HC Analog Output (D/A) . . . . . . . . . . . . . . . . . . . . 13-10
KPCI-1801HC Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . 13-11
KPCI-1801HC Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . 13-12
xiv Contents
KPCI-1802HC . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13-13
KPCI-1802HC Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . . 13-14
KPCI-1802HC Analog Output (D/A) . . . . . . . . . . . . . . . . . . . . 13-16
KPCI-1802HC Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . 13-17
KPCI-1802HC Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . 13-18
National Instruments
14
AT-AO-6 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-4
AT-AO-6 Analog Output (D/A) . . . . . . . . . . . . . . . . . . . . . . . . . 14-4
AT-AO-6 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-6
0x300 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-6
AT-AO-6 Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-7
AT-AO-10 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-8
AT-AO-10 Analog Output (D/A) . . . . . . . . . . . . . . . . . . . . . . . . 14-8
AT-AO-10 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-10
AT-AO-10 Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-11
GPIB-232CT-A . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-12
GPIB-232CT-A Setup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-12
GPIB-232CT-A Send/Receive . . . . . . . . . . . . . . . . . . . . . . . . . 14-13
PC-DIO-24 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-14
PC-DIO24 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-15
PC-DIO24 Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-16
PC-TIO-10 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-17
PC-TIO-10 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-17
PC-TIO-10 Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-18
PC-TIO-10 Counter PWM . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-20
PC-TIO10 Counter PWM & ARM . . . . . . . . . . . . . . . . . . . . . . 14-21
PC-TIO-10 Counter FM . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-22
PC-TIO10 Counter FM & ARM . . . . . . . . . . . . . . . . . . . . . . . . 14-24
PC-TIO10 PWM Capture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-25
PC-TIO10 FM Capture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-25
xv
PCI-6023E . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-26
PCI-6023E Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . . . . . 14-27
PCI-6023E Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-29
PCI-6023E Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-30
PCI-6024E . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-31
PCI-6024E Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . . . . . 14-32
PCI-6024E Analog Output (D/A) . . . . . . . . . . . . . . . . . . . . . . . 14-34
PCI-6024E Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-35
PCI-6024E Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-36
PCI-6025E . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-37
PCI-6025E Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . . . . . 14-38
PCI-6025E Analog Output (D/A) . . . . . . . . . . . . . . . . . . . . . . . 14-40
PCI-6025E Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-41
PCI-6025E Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-42
PCI-6031E . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-43
PCI-6031E Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . . . . . 14-43
PCI-6031E Analog Output (D/A) . . . . . . . . . . . . . . . . . . . . . . . 14-46
PCI-6031E Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-47
PCI-6031E Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-48
PCI-6052E . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-49
PCI-6052E Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . . . . . 14-49
PCI-6052E Analog Output (D/A) . . . . . . . . . . . . . . . . . . . . . . . 14-52
PCI-6052E Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-53
PCI-6052E Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-54
PCI-6071E . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-55
PCI-6071E Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . . . . . 14-56
PCI-6071E Analog Output (D/A) . . . . . . . . . . . . . . . . . . . . . . . 14-58
PCI-6071E Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-59
PCI-6071E Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-60
PCI-6503 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-61
PCI-6503 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-61
PCI-6503 Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-62
xvi Contents
PCI-6508 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-64
PCI-DIO-96 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-65
PCI-DIO96 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-65
PCI-DIO96 Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-66
PCI-MIO-16E-1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-68
PCI-MIO-16E-1 Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . 14-68
PCI-MIO-16E1 Analog Output (D/A) . . . . . . . . . . . . . . . . . . . 14-71
PCI-MIO-16E1 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . 14-72
PCI-MIO-16E1 Digital Output . . . . . . . . . . . . . . . . . . . . . . . . 14-73
PCI-MIO-16E-4 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-74
PCI-MIO-16E-4 Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . 14-75
PCI-MIO-16E-4 Analog Output (D/A) . . . . . . . . . . . . . . . . . . . 14-77
PCI-MIO-16E-4 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . 14-78
PCI-MIO-E4 Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . 14-79
PCI-MIO-16XE-10 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-80
PCI-MIO-16XE-10 Analog Input (A/D) . . . . . . . . . . . . . . . . . . 14-80
PCI-MIO-16XE-10 Analog Output (D/A) . . . . . . . . . . . . . . . . 14-83
PCI-MIO-16XE-10 Digital Input . . . . . . . . . . . . . . . . . . . . . . . 14-84
PCI-MIO-16XE-10 Digital Output . . . . . . . . . . . . . . . . . . . . . 14-85
PXI-6040E . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-86
PXI-6040E Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . . . . . 14-87
PXI-6040E Analog Output (D/A) . . . . . . . . . . . . . . . . . . . . . . . 14-89
PXI-6040E Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-90
PXI-6040E Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-91
PXI-6070E . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-92
PXI-6070E Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . . . . . 14-92
PXI-6070E Analog Output (D/A) . . . . . . . . . . . . . . . . . . . . . . . 14-95
PXI-6070E Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-96
PXI-6070E Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-97
PXI-6508 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-98
PXI-6508 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-98
PXI-6508 Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-99
xvii
Real Time Devices
15
DM6420 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-3
DM6420 Analog Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-4
DM6430 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-6
DM6430 Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-6
DM6430 Analog Output (D/A) . . . . . . . . . . . . . . . . . . . . . . . . . . 15-8
DM6604 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-9
DM6604 Analog Output (D/A) . . . . . . . . . . . . . . . . . . . . . . . . . . 15-9
DM6604 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-10
DM6604 Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-11
DM6804 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-12
DM6804 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-12
DM6804 Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-13
DM6804 Counter PWM . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-14
DM6804 Counter PWM & ARM . . . . . . . . . . . . . . . . . . . . . . . 15-15
DM6804 Counter FM . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-16
DM6804 Counter FM & ARM . . . . . . . . . . . . . . . . . . . . . . . . . 15-17
DM6804 PWM Capture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-19
DM6804 FM Capture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-20
DM6814 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-21
DM6814 Incremental Encoder . . . . . . . . . . . . . . . . . . . . . . . . 15-21
DM7420 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-23
DM7420 Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . . . . . . . 15-23
DM7420 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-26
DM7420 Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-26
xviii Contents
Softing
16
CAN-AC2-ISA . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16-3
CAN-AC2-ISA with Philips PCA82C200 . . . . . . . . . . . . . . . . . 16-3
CAN-AC2-ISA with Intel 82527 . . . . . . . . . . . . . . . . . . . . . . . . 16-8
CAN-AC2-PCI . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16-13
CAN-AC2-PCI with SJA 1000 . . . . . . . . . . . . . . . . . . . . . . . . . 16-13
Versalogic
17
VSBC-6 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-27
VSBC-6 Analog Input (A/D) . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-27
VSBC-6 Digital Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-28
VSBC-6 Digital Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-29
VSBC-6 Watch Dog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-29
xix
xx Contents
1
I/O Drivers
xPC Target supports over 40 I/O boards and devices. These devices include
communication with CAN, GPIB, and RS232.
This chapter includes the following sections:
• I/O Driver Block Library — The xPC Target I/O library is organized
hierarchically from I/O Function --> Manufacture --> Driver block.
• Memory-Mapped Devices - I/O boards that need a base address.
• PCI Bus I/O Devices — I/O boards that need a PCI slot number.
When you double-click one of these groups, the sublibrary opens displaying a
list grouped by manufacturer as shown below.
1-2
Double-clicking one of the manufacturer groups then displays the set of I/O
device driver blocks for the specified I/O functionality (for example, A/D, D/A,
Digital Inputs, Digital Outputs, and so on).
The following figure shows the A/D drivers for the manufacturer
ComputerBoards, Inc.
When you double-click one of these blocks, a Block Parameters dialog box
opens allowing you to make hardware-specific parameters. Parameters
typically include:
• Sample time
• Number of channels
• Voltage range
• Base address (ISA boards)
1-3
1 I/O Drivers
Memory-Mapped Devices
Some supported boards in the xPC Target I/O library are memory-mapped
devices, for example, Burr-Brown boards. These memory-mapped boards are
accessed in the address space between 640K and 1M in the lower memory area.
xPC Target reserves a 112 kB memory space for memory mapped devices in the
address range:
C0000 - DC000
1-4
In this example, the third line indicates the location of the ComputerBoards
PCI-DIO48 board. This is known since the ComputerBoards Vendor ID is
0x1307 and the Device ID is 0xb. In this case, you now can see that the
ComputerBoards board is plugged into the PCI slot 11 (Device No.), and that
this value must be entered in the dialog box entry in your I/O device driver for
each model that uses this I/O device.
Message structure
First message Second message Third message
Message(1).field Message(1).field Message(1).field
Message(1).field Message(1).field Message(1).field
Message(1).field Message(1).field Message(1).field
The field names are defined by the driver, and need to be entered with the
correct upper and lower case letters. However, you can choose your own
structure name, and enter that name into the driver Parameter dialog box.
1-5
1 I/O Drivers
This approach has two issues different from other xPC Target driver blocks:
• When you move or copy the model file to a new directory, you also need to
move or copy the M-file defining the message structure.
During each sample interval, the driver block locates the structure defined in
the Parameter dialog box, interprets the series of messages, and executes the
command defined by each message.
Specific drivers and structures — For detailed information on the fields in a
message structure see the following chapters:
1-6
Updated Driver Information
Since, we are always updating and adding new drivers to xPC Target, not all
of the information about these drivers is included in the online or printed
documentation.
For updated and additional driver information, see our developer Web site at:
http://www.mathworks.com/support/author/xpc/index.shtml
1-7
1 I/O Drivers
1-8
2
RS232 I/O Support
xPC Target interfaces the target PC to an RS-232 device using either the
COM1 or COM2 port.
This chapter includes the following sections:
2-2
Introduction to RS-232 Drivers
RS 232
connection
Target PC RS-232 Device
2-3
2 RS232 I/O Support
• RS-232 Setup — One setup block is needed for each RS-232 port you use in
your model. The setup block does not have any inputs or outputs, but sends
the initialization and termination messages.
• RS-232 Send/Receive (Synchronous Mode) — Send/Receive blocks have
inputs and outputs from your Simulink model, and sequence both the send
and receive messages.
• RS-232 Send (Asynchronous Mode) — Send blocks have inputs from your
Simulink model, and sequences the send messages.
• RS-232 Receive (Asynchronous Mode) — Receive blocks have output from
your Simulink model, and sequences the receive messages.
2-4
Introduction to RS-232 Drivers
RS232_Send
RS232_Send(1) . . . RS232_Send(n)
.SendData - ‘start,%f,%f,stop:\;’
.InputPorts - [1,2]
.Timeout - 0.01
RS232_Receive
RS232_Receive(1) . . . RS232_Receive(n)
.RecData - ‘start,%f,%f,stop:\;’
.OutputPorts - [1,2]
.Timeout - 0.01
.Eom - 1
2-5
2 RS232 I/O Support
Note COM1 and COM3 share interrupt line 4. Similarly, COM2 and COM4
share interrupt line 3. To provide maximum performance, the COM port
interrupt line on your target PC used for serial communication is disabled
while real-time tasks that include RS-232 blocks are executing. This also
means that when COM1 is disabled, COM3 is also disabled since they both
share the same interrupt line. For this case, you would have to use either
COM2 or COM4 as your RS-232 I/O device.
2-6
RS-232 Synchronous Mode
• Adding RS-232 Driver Blocks (Synchronous) — Add the setup, send, and
receive blocks you need to your Simulink model for RS-232 communicating.
• Creating RS-232 Message Structures (Synchronous) — Create the
initialize, send/receive, and termination message structures you need in the
MATLAB workspace.
For the example in this section, assume an external device (RS-232 device)
includes a D/A conversion module with four independent channels and an
output voltage range of -10 to 10 volts. Also assume that the external device
outputs a new voltage if it receives a serial string with a value to identify the
D/A channel and the voltage value.
Use a constant block as an input to the Send/Receive block to select the D/A
channel, and a Signal Generator block as a source for voltage values. Also, set
up the message structures to receive a confirmation message from the external
module after the target PC sends a message string to the device.
2-7
2 RS232 I/O Support
Note This library contains two setup blocks. The second block is included for
compatibility with xPC Target Version 1.0.
Alternatively, you could access the xPC Target block library from the
Simulink Library Browser. In the Simulink window, and from the View
menu, click Show Library Browser. In the left pane, double-click xPC
Target, and then click RS-232.
2-8
RS-232 Synchronous Mode
Note This library contains two setup/receive blocks. The second block is
included for compatibility with xPC Target version 1.0.
Your model should look similar to the figure shown below. Notice, the inputs
on the RS-232 Send/Receive block are not defined or visible. The inputs are
defined in a MATLAB message structure, and visible only after you load that
structure into the MATLAB workspace and update your Simulink model.
2-9
2 RS232 I/O Support
7 Double-click the RS-232 Setup block. Enter values to configure the COM1
port on the target PC.
2-10
RS-232 Synchronous Mode
For more information on entering the block parameters, see “RS-232 Setup
Block” on page 2-27. For the procedure to create the initialization and
termination structures, see “RS-232 MATLAB Structure Reference” on
page 2-31.
2-11
2 RS232 I/O Support
10 From the Port list, choose either COM1 or COM2. For this example, choose
COM1. In the Message StructName box, enter the name for the MATLAB
structure this block uses to send messages to the COM1 port. In the Sample
Time box, enter the sample time or a multiple of the sample time you
entered in the Receive block.
You Block Parameter dialog box should look similar to the figure shown
below.
2-12
RS-232 Synchronous Mode
Your next task is to create the MATLAB message structures that the RS-232
driver blocks use to sequence commands to the RS-232 device. See “Creating
RS-232 Message Structures (Synchronous)” on page 2-13.
1 In the MATLAB command window, and from the File menu, point to New,
and then click M-file.
For example, you could have an external RS-232 device with an D/A module
that wants a string in the format ’identifier, channel, value;\n’.
Identifier is any string. Channel is an integer value between 1 and 2,
defining which D/A channel to update. Value is a floating-point value
indicating the new voltage for the D/A output.
Additionally, when the external device receives a legal string, it accepts the
string as an input message, and returns the message ’noerror;\n’. This
message is provided as a confirmation. As an example, you could type the
following
2-13
2 RS232 I/O Support
3 From the File menu, click Save As. In the Save as file dialog box, enter the
name of the M-file script. For example, enter
RS232_Messages.m
5 In the MATLAB command window, type the name of the M-file script you
created with the RS-232 structures. For example, type
RS232_Messages
MATLAB loads and runs the M-file script to create the message structures
in the MATLAB workspace needed by the RS-232 driver blocks.
Simulink updates the RS-232 driver blocks with the information from the
structures. For example, Simulink adds inputs and outputs defined in the
structures to the blocks.
7 Connect the input and output ports on the RS-232 driver blocks to other
blocks in your Simulink model.
2-14
RS-232 Synchronous Mode
8 Set the pre-load function for your Simulink model to load the message
structures when you open your model. For example, if you saved the
message structures in the M-file RS232_messages, type
set_param(gcs, ’PreLoadFcn’,’RS232_messages.m’)
Note If you do not manually load the message structures before opening
your Simulink model, or have the message structures automatically loaded
with the model, the port connections to the RS-232 driver break.
Your next task is to build and run the target application. However, the example
above only illustrates how to set up the dialog entries when using the Send &
Receive block. Without an external RS-232 device to receive the messages,
and return a reply "no error\n", this model cannot run successfully on your
target PC. It will block and wait for a reply each time the application sends a
message.
2-15
2 RS232 I/O Support
• Adding RS-232 Driver Blocks (Asynchronous) — Add the setup, send, and
receive blocks you need to your Simulink model for RS-232 communicating
• Creating RS-232 Message Structures (Asynchronous) — Create the
initialize, send/receive, and termination message structures you need in the
MATLAB workspace
For the example in this section, two Asynchronous Mode blocks illustrate
how you can test RS-232 I/O on the target PC in a simple loop-back test. This
simple but effective test lets you check that the RS-232 Send and RS-232
Receive blocks work correctly with your system using minimal hardware.
In this loop-back test, you use the COM1 port for sending signals and the
COM2 port for receiving signals. A null modem serial cable connects COM1 to
COM2 so that any messages sent from the target PC through COM1 are
received by COM2 on the same target PC.
Use a Sine Wave block as an input to an RS-232 Send block that you connect
to the COM1 port. Connect the COM2 port to an RS-232 Receive block. The
signal received from this block is then passed through a Gain block of -1.
2-16
RS-232 Asynchronous Mode
Note This library contains two setup blocks. The second block is included for
compatibility with xPC Target Version 1.0.
Alternatively, you could access the xPC Target block library from the
Simulink Library Browser. In the Simulink window, and from the View
menu, click Show Library Browser. In the left pane, double-click xPC
Target, and then click RS-232.
Note This library contains two send and two receive blocks. The second
block is included for compatibility with xPC Target Version 1.0.
2-17
2 RS232 I/O Support
Alternatively, you could access the xPC Target block library from the
Simulink Library Browser. In the Simulink window, and from the View
menu, click Show Library Browser. In the left pane, double-click xPC
Target, and then click RS-232.
5 Drag-and-drop the RS-232 Send and RS-232 Receive blocks into your
Simulink model.
Your model should look similar to the figure below. Notice, you cannot
connect to the inputs on the RS-232 Send block and the outputs on the
RS-232 Receive block, because they are not defined or visible. The inputs
and outputs are defined in a MATLAB massage structure, and visible only
after you load that structure into the MATLAB workspace and update your
Simulink model.
7 Double-click the first RS-232 Setup block. Enter values to configure the
COM1 port on the target PC.
For example, if the COM1 and COM2 ports of the target are connected with
a RS-232 null modem cable and setting serial communication to 5760 baud,
8 databits, and 1 stopbit. You Block Parameter dialog box should look
similar to the figure shown below.
2-18
RS-232 Asynchronous Mode
For more information on entering the block parameters, see “RS-232 Setup
Block” on page 2-27. For the procedure to create the initialization and
termination structures, see “RS-232 MATLAB Structure Reference” on
page 2-31.
2-19
2 RS232 I/O Support
9 Repeat the previous setup for the second RS-232 Setup block and the COM2
port. Use the same Baudrate, Databits, Stopbits, Parity, and Protocol that
you entered in the first RS-232 Setup block.
10 Double-click the Send block. The Block Parameters dialog box opens.
11 From the Port list, choose either COM1 or COM2. For this example, choose
COM1. In the Message struct name box, enter the name for the MATLAB
structure this block uses to send messages to the COM1 port. In the Sample
Time box, enter the sample time or a multiple of the sample time you
entered in the RS-232 Receive block.
Your Block Parameters dialog box should look similar to the figure shown
below.
For information on entering the block parameters, see “RS-232 Send Block
(Asynchronous)” on page 2-30. For the procedure to create the send
structure, see “RS-232 MATLAB Structure Reference” on page 2-31.
2-20
RS-232 Asynchronous Mode
13 Double-click the RS-232 Send block. The Block Parameters dialog box
opens.
14 From the Port list, choose either COM1 or COM2. For this example, choose
COM2. In the Message Struct Name box, enter the name for the MATLAB
structure this block uses to receive messages from the COM2 port. In the
Sample Time box, enter the sample time or a multiple of the sample time
you entered in the RS-232 Send block.
Your Block Parameters dialog box should look similar to the figure shown
below.
2-21
2 RS232 I/O Support
17 Double-click the Gain block, and enter parameters. For example, in the Gain
box, enter -1. Click OK.
Your next task is to create the MATLAB message structures that the RS-232
driver blocks use to sequence commands to the RS-232 device. See “Creating
RS-232 Message Structures (Synchronous)” on page 2-13.
1 In the MATLAB command window, and from the File menu, point to New,
and then click M-file.
For example, if you want to send and receive two floating-point numbers,
type the following.
2-22
RS-232 Asynchronous Mode
RS232_Receive(1).RecData = ’start,%f,%f,stop;\r’;
RS232_Receive(1).OutputPorts = [2,1];
RS232_Receive(1).Timout = 0.01;
RS232_Receive(1).EOM 1;
Note If you do not manually load the message structures before opening
your Simulink model, or have the message structures automatically loaded
with the model, the port connections to the RS-232 blocks break.
3 From the File menu, click Save As. In the Save As File dialog box, enter the
name of the M-file script. For example, enter
RS232_Messages.m
5 In the MATLAB command window, type the name of the M-file script you
created with the RS-232 structures. For example, type
RS232_Messages
MATLAB loads and runs the M-file script to create the message structures
in the MATLAB workspace needed by the RS-232 driver blocks.
Simulink updates the RS-232 driver blocks with the information from the
structures. For example, Simulink adds the inputs and outputs defined in
the structures to the blocks.
2-23
2 RS232 I/O Support
7 Connect the input and output ports on the RS-232 driver blocks to other
blocks in your Simulink model.
8 Set the pre-load function for your Simulink model to load the message
structures when you open the model. For example, if you saved the message
structures in the M-file RS232async_messages, type
set_pram(gcs, ’PreLoadFcn’,’RS232async_messages’)
Note If you do not manually load the message structures before opening
your Simulink model, or have the message structures automatically loaded
with the model, the port connections to the RS-232 blocks breaks.
Your next task is to build and run the target application.
2-24
RS-232 Asynchronous Mode
Note You cannot use a serial port to communication between the host PC
and target PC with this example. Using a serial port would disable the COM
port and the example would not operate.
1 In the Simulink window, and from the Tools menu, point to Real-Time
Workshop, and then click Build Model.
For each sample period, the RS-232 messages you entered in the RS-232
send and receive message structures are executed.
In this example, the target PC displays the inverted waveform. The RS-232
Send and RS-232 Receive blocks require a minimum of one delay to send
the data and also receive it. When running at faster sample rates, it is
possible for additional sample intervals to happen while one transfer of data
is processed since RS-232 communication is not particularly fast. The
sample delay just described is not visible in this example.
2-25
2 RS232 I/O Support
2-26
RS-232 Simulink Block Reference
• RS-232 Setup Block — Sends the initialize and termination messages. You
need one Setup block for each RS-232 port you use in your model.
• “RS-232 Send/Receive Block (Synchronous)” — Sequences the send and
receive messages for synchronous serial communication.
• RS-232 Send Block (Asynchronous) — Sequences the send messages.
• RS-232 Receive Block (Asynchronous) — Sequences the receive messages.
Parameter Description
Port From the list, choose COM1, COM2, COM3, or COM4. This
is the serial connection the target PC uses to communicate
with the RS-232 device.
Baudrate From the list, choose 115200, 57600, 38400, 19200, 9600,
4800, 2400, 1200, 300, or 110.
2-27
2 RS232 I/O Support
Parameter Description
2-28
RS-232 Simulink Block Reference
Parameter Description
Port From the list, choose COM1, COM2, COM3, or COM4. This
list allows you to define which COM port is used to send and
receive the data. The model must contain one Setup block
for the same COM port used to send and receive data.
Otherwise, an error message is displayed. Note that data is
sent and received on the same COM port.
Message Enter the name of the MATLAB structure this block uses to
Structure send and receive messages and data to an RS-232 device.
Name For information to create this structure, see “Creating
RS-232 Message Structures (Synchronous)” on page 2-13.
Sample This entry allows you to define the sample time of the block.
Time Since this block waits for data to be received from the
RS-232 external device before the block is finished
executing, small sample times are not suitable with
Synchronous Mode. You must allow sufficient time for
both the RS232 send and the RS232 receive operations to be
completed. The smallest sample time depends on the
following.
2-29
2 RS232 I/O Support
Parameter Description
Port This list allows you to define which COM port is used for
sending data. The model must contain one RS232 Setup
block to configure its COM port. Otherwise, an error
message is displayed.
Message Enter the name of the MATLAB structure this block uses to
Structure send messages and data to an RS-232 device. For
Name information to create this structure, see “Creating RS-232
Message Structures (Synchronous)” on page 2-13.
Sample This entry allows you to define the sample time of the block.
Time Because the block does not wait until data is received from
the external RS-232 device, you can set sample times to
small values.
Parameter Description
Port This list allows you to define which COM port the data is
used to send and receive data. The model must contain one
RS232 Setup block for the same COM port. Otherwise, an
error message is displayed.
2-30
RS-232 Simulink Block Reference
Parameter Description
Message Enter the name of the MATLAB structure this block uses to
Structure receive messages and data from an RS-232 device. For
Name information on creating this structure, see “Creating
RS-232 Message Structures (Asynchronous)” on page 2-22.
Sample This entry allows you to define the sample time of the block.
Time Because the block does not wait until data is received from
the external RS-232 device, you can set sample times to
small values.
2-31
2 RS232 I/O Support
Messge Description
Field
InputPorts Number of input ports for the driver block. Data from the
input ports is sent to the RS-232 device with the message
field.SendData. Default value = []. The highest number you
enter determines the number of input ports on the driver
block.
For example, the following message creates two input ports
on the driver block,
RS232_Send_Receive(1).InputPorts= [1 2];
RecData Data and format received from the RS-232 device. Default
value = ’’. The format of this statement is very similar to a
scanf statement. The read data is mapped to the output
ports defined in the message field .OutputPorts. If a
negative output port is given, the data is read in, but not
sent to any output port.
OutputPort Number of output ports from the driver block. Data received
s from a RS-232 device is sent to the output ports with the
message field .ReceiveData. Default value = []. The
highest number you enter determines the number of output
ports on the driver block.
For example, to use output ports 1 and 2 on the driver block,
type
RS232_Send_Receive.OutputPorts = [1 2];
2-32
RS-232 Simulink Block Reference
Messge Description
Field
Messge Description
Field
InputPorts Number of input ports for the driver block. Data from the
input ports is sent to the RS-232 device with the message
field .SendData. Default value = []. The highest number
you enter determines the number of input ports on the
driver block.
For example, the following message creates two input ports
on the driver block,
RS232_Send_Receive(1).InputPorts= [1 2];
2-33
2 RS232 I/O Support
Message Description
Fields
RecData Data and format received from the RS-232 device. Default
value = ’’. The format of this statement is very similar to a
scanf statement. The read data is mapped to the output
ports defined in the message field .OutputPorts. If a
negative output port is given, the data is read in but not sent
to any output port
OutputPort Number of output ports from the driver block. Data received
s from a RS-232 device is sent to the output ports with the
message field .ReceiveData. Default value = []. The
highest number you enter determines the number of output
ports on the driver block.
For example, to use output ports 1 and 2 on the driver block.
RS232_Send_Receive.OutputPorts = [1 2];
2-34
RS-232 Simulink Block Reference
Format Description
2-35
2 RS232 I/O Support
2-36
3
GPIB I/O Support
3-2
Introduction to GPIB Drivers
RS 232
connection GPIB-232CT-A
Target PC RS232 IEEE 488 Controller
GPIB
instrument
bus
GPIB Device
3-3
3 GPIB I/O Support
• GPIB Setup — One setup block is needed for each GPIB controller. The
setup block does not have any inputs or outputs, but sends the initialization
and termination messages.
• GPIB Send/Receive — The send/receive block has inputs and outputs from
your Simulink model, and sequences both the send and receive messages.
3-4
Introduction to GPIB Drivers
GPIB_Send_Receive
.Address - 16 .Address
.Command - ‘wrt’ .Command - ‘rd 16’
.SendData - ‘:read?’ .SendData -
.InputPorts .InputPorts
.RecData .RecData - ‘%f’
.RdLength .RdLength - 20
.OutputPorts .OutputPorts - [1]
.OutputDataTypes .OutputDataTypes - {double}
.Wait .Wait
.Timeout - 0.05 .Timeout - 0.05
Currently, only two limitations exist. xPC Target does not support string data
types as input and output data types. Also, you must know the size and order
of data returned from a read command.
For more information on this example, see “Creating GPIB Message
Structures” on page 3-11
3-5
3 GPIB I/O Support
• Adding GPIB Driver Blocks — Add the setup and send/receive blocks you
need to add to your Simulink model for GPIB communication.
• Creating GPIB Message Structures — Create the initialize, send/receive,
and termination message structures you need in the MATLAB workspace.
For example in this section, assume you have a multimeter attached to a GPIB
bus with an address of 16. This multimeter needs the initialization command
:conf:volt:dc
3-6
Using GPIB Drivers
Alternatively, you could access the xPC Target block library from the
Simulink Library Browser. In the Simulink window, and from the View
menu, click Show Library Browser. In the left pane, double-click xPC
Target, double-click GPIB, and then click National Instruments.
Your model should look similar to the figure below. Notice, the input and
output ports are not defined or visible on the blocks. The inputs and outputs
are defined in a MATLAB message structure, and visible only after you load
that structure into the MATLAB workspace and update your Simulink
model.
3-7
3 GPIB I/O Support
5 Double-click the GPIB Setup block. Enter values that correspond to the DIP
switch settings you set on the GPIB-232CT-A controller. In the
Initialization Struct box, enter the name for the MATLAB structure this
block uses to send initialization messages to the GPIB device.
For example, if the target PC is connected to COM1, and you set the switches
on the controller to 38400 baud, 8 databits, and 1 stopbit, your Block
Parameter dialog box should look similar to the figure shown below.
3-8
Using GPIB Drivers
3-9
3 GPIB I/O Support
8 From the Port list, choose either COM1 or COM2. This is the port on the
target PC connected to the GPIB controller. In the Message Struct Name
box, enter the name for the MATLAB structure this block uses to send and
receive messages to the GPIB device. In the Sample Time box, enter the
same sample time or multiple of the sample time you entered for the step
size in the Simulation Parameters dialog box.
Your Block Parameter dialog box should look similar to the figure shown
below.
3-10
Using GPIB Drivers
Your next task is to create the MATLAB message structures that the GPIB
driver blocks use to sequence commands to the GPIB controller. See “Creating
GPIB Message Structures” on page 3-11.
1 In the MATLAB command window, and from the File menu, point to New,
and then click M-file.
GPIB_Send_Receive(1).Address= 16;
GPIB_Send_Receive(1).Command = ’wrt 16’;
GPIB_Send_Receive(1).SendData = ’:read?’;
GPIB_Send_Receive(1).Timeout = 0.05;
3-11
3 GPIB I/O Support
This example did not need a termination structure. But if it did, the format
of the structure is the same as the initialization structure. For example, a
termination structure could have a message with the .Command and
.SendData fields.
GPIB_Termination(1).Command
GPIB_Termination(1).SendData
3 From the File menu, click Save As. In the Save As File dialog box, enter the
name of the M-file script. For example, enter
GPIB_Messages.m
5 In the MATLAB command window, type the name of the M-file script you
created with the GPIB structures. For example, type
GPIB_Messages
MATLAB loads and runs the M-file script to create the message structures
in the MATLAB workspace needed by the GPIB driver blocks.
The GPIB driver blocks are updated with the information from the
structures. For example, inputs and outputs defined in the structures are
now visible on the driver blocks.
7 Connect the input and output ports on the RS-232 driver blocks to other
blocks in your Simulink model.
3-12
Using GPIB Drivers
8 Set the pre-load function for your Simulink model to load the message
structures when you open the model. For example, if you saved the message
structures in the M-file GPIB_messages, type
set_param(gcs, ’PreLoadFcn’,’GPIB_messages.m’)
Note If you do not manually load the message structures before opening
your Simulink model, or have the message structures automatically loaded
with the model, the port connections to the GPIB driver blocks break.
Your next task is to build the target application and download it to the target
PC.
3-13
3 GPIB I/O Support
Board Characteristics
Parameter Description
Port From the list, choose COM1, COM2, COM3, or COM4. This
is the serial connections the target PC uses to communicate
with the GPIB-232CT-A controller.
3-14
GPIB Simulink Block Reference
Parameter Description
Baudrate From the list, choose 115200, 57600, 38400, 19200, 9600,
4800, 2400, 1200, 600, or 300.
3-15
3 GPIB I/O Support
Parameter Description
Sample Enter the base sample time or a multiple of the base sample
Time time you entered in the Simulations Parameter dialog box.
3-16
GPIB Simulink Block Reference
Below is a description of the possible message fields for the initialization and
termination structures. The order of the message fields does not matter.
However, the field names are case-sensitive.
Message Description
Fields
Address Sets the GPIB address for the device being accessed and
defines the keyword ADDR. Default value = [].
SendData Data sent with the GPIB command. Default value = ’’.
3-17
3 GPIB I/O Support
Message Description
Fields
Address Sets the GPIB address for the device being accessed. After
the GPIB address is set, the remaining messages use this
address value until another message changes the address
value. Default value = 0.
The keyword ADDR is equal to the value in the message
field .Address. You can use this keyword in the message
fields .Command or .SendData to replace the numerical value
of the GPIB address. For example, you can write
GPIB_Send_Receive(1).Command=’wrt 16’;
SendData Data sent with the GPIB command. Default value = ’’.
InputPorts Defines the input ports for the driver block. Data from the
input ports is sent to the GPIB device with the message
fields .Command and .SendData. Default value = []. The
highest number you enter determines the number of input
ports on the driver block.
For example, the following message creates two input ports
on the driver block, and passes data from the input ports to
the read command.
GPIB_Send_Receive(1).Command = ’rd #%d %d’;
GPIB_Send_Receive(1).InputPorts= [1 2];
3-18
GPIB Simulink Block Reference
Message Description
Fields
RecData Format of the data received from the GPIB device. Default
value = ’’. The format of this statement is very similar to a
scanf statement. The read data is mapped to the output
ports defined in the field .OutputPorts. If a negative output
port is given, the data is read in, but not sent to any output
port
For example, to read from a GPIB device with an address of
16, one floating- point number with a maximum number of
bytes of 20, and send the data to the first driver block
output, type the following
GPIB_Send_Receive(1).Command = ’rd #20 16’;
GPIB_Send_Receive(1).RecData = ’%f’;
GPIB_Send_Receive(1).OutputPorts = [1];
RdLength Defines the length of the data, in bytes, received with the
read command and defines the keyword LENGTH. Default
value = 0.
OutputPorts Defines the output ports from the driver block. Data
received from a GPIB device with the read command is sent
to the output ports. Default value = []. The highest
number you enter determines the number of output ports on
the driver block.
For example, to use output ports 1 and 2 on the driver block,
type
GPIB_Send_Receive.OutputPorts = [1 2];
3-19
3 GPIB I/O Support
Message Description
Fields
OutputData Defines the data types for the output ports on the driver
Types block. Default value = []
If this value is not define, and there are output ports, the
default type is double. Also, if there are more output ports
than output data types listed, the default type for the
undefined ports is double.
3-20
GPIB Simulink Block Reference
The following message fields, with the keyword ADDR, use the address value
8 defined in the message field .Address.
If you enter numerical values in the wrt and rd commands, then the command
uses those values instead of the values in the variables ADDR and LENGH.
For example, the following message uses the GPIB address 10 even though the
value for ADDR is defined as 8.
GPIB_Initialize(1).Address = 8;
GPIB_Initialize(1).Command = 'wrt 10';
3-21
3 GPIB I/O Support
GPIB_Message(1).RecData = ’%f%d’;
GPIB_Message(1).OutputPorts = [1 -1];
The code %d reads the length of data and the -1 discards the length. Using the
modified xPC Target rd command, you would write
GPIB_message(1).Command = ’rd #20 16’;
GPIB_message(1).RecData = ’%f’;
GPIB_message(1).OutputPorts = [1];
or you can write the following, and the appropriate escape characters are
added.
GPIB_Message.Command = ’wrt 16’;
GPIB_Message.SendData = ’:conf:volt:dc’;
GPIB_Message.Ack = ’10’;
3-22
GPIB Simulink Block Reference
Format Description
3-23
3 GPIB I/O Support
3-24
4
CAN I/O Support
Introduction 2
CAN-AC2 4
CAN-AC2-PCI 4
CAN-AC2-104 4
Selecting a CAN Library 5
CAN driver blocks for the CAN-AC2 (ISA) with Philips PCA 82C200 CAN-Controller 8
Setup Driver Block 9
Send Driver Block 11
Receive Driver Block 13
CAN driver blocks for the CAN-AC2 (ISA) with Intel 82527 CAN-Controller 15
Setup driver block 16
Send driver block 18
Receive driver block 20
CAN driver blocks for the CAN-AC2-PCI with Philips SJA1000 CAN-Controller 22
Setup driver block 23
Send driver block 26
Receive driver block 28
CAN driver blocks for the CAN-AC2-104 (PC/104) with Philips SJA1000 CAN-Controller 30
Setup driver block 31
Send driver block 34
Receive driver block 36
Introduction
xPC Target offers support to connect an xPC target system to a CAN network
using the CAN driver blocks provided by the xPC Target I/O block library. The
library supports the following CAN-boards from Softing GmbH, Germany.
xpccanisa CAN-AC2
xpccanpci CAN-AC2-PCI
xpccanpc104 CAN-AC2-104
The size of the driver code of the CAN boards supported by the xPC Target
block library is significant and because not all xPC Target applications will use
CAN, the CAN library code is not linked by default when building a target
application. This makes target applications smaller if no CAN-communication
functionality is needed. If the model to be built contains CAN driver blocks, the
corresponding CAN-library support has to be enabled prior to the initiation of
4-2
Introduction
the build process. This has to be done in the xPC Target setup environment
either using the xpcsetup-GUI or the corresponding command line functions.
See chapter 2 below for further information.
For each CAN-board three driver blocks are provided. These are: A Setup block,
which defines the type of physical connection (baud rate and so forth). Exactly
one instance of the setup block has to be defined in a model for each physically
installed CAN-board. A Send block, which transmits (sends) the data entering
the block’s input ports to the connected CAN-network. One or more instances
of the Send-block can be used in a model. A Receive block, which retrieves
(reads) CAN-messages received by the board and outputs the data at the
corresponding output ports. One or more instances of the Receive block can be
used in a model.
The maximum size of the data frame of a CAN-message is 8 bytes. This is the
same size as the C data type ‘double’ uses on PC-compatible systems. At the
same time, the double data type is the default data type used for Simulink
signals. Therefore the CAN data frame within a Simulink model can be easily
represented by a scalar Simulink signal even if the data frame normally has
nothing in common with a double floating point value. The xPC Target CAN
library provides a Utility sublibrary which offers bit-packing and
bit-unpacking blocks. These blocks are used to pack data types other than
doubles into 64 bits (8 bytes or a double) as well as for the opposite operation.
This will be discussed in greater details further below. What is important for
now, is, that CAN data frames are represented by Simulink signals of data type
double.
All drivers for the supported CAN-boards program the boards for the so-called
“dynamic object mode”. This is one of three modes the CAN-board firmware
from Softing can operate in. For a more detailed discussion of the three modes
see the board’s user manual. The dynamic object mode is best suited for
real-time environments where each component of the application has to have
deterministic time behavior. This is the case for xPC Target and that is the
main reason why this mode has been chosen over the other two modes, which
are FIFO and static object mode.
The following paragraph summarizes the differences between the three
supported Softing boards.
4-3
4 CAN I/O Support
CAN-AC2
This is the CAN-board for the ISA-Bus offering two CAN ports (Highspeed). In
it’s standard hardware configuration it uses the Philips PCA 82C200 CAN
controller, which supports Standard Identifiers only. Piggyback modules are
available (one for each port) which replace the Philips CAN controllers by the
Intel 82527 CAN-controllers. The Intel controllers support both Standard and
Extended Identifiers. The board is a memory-mapped device and uses a 16
kilobyte big address range between 640k Byte and 1M Byte. We do not
recommend this board for new projects, use the CAN-AC2-PCI which is
described below instead. We will freeze the driver code for this board with the
release of R12. Softing has confirmed that no new firmware versions are
planned for this board either.
CAN-AC2-PCI
This is the CAN-board for the PCI-bus offering two CAN ports. The
CAN-controllers used on the board are the SJA1000 from Philips. In it’s
standard hardware configuration the board is designed for both Standard and
Extended identifiers for Highspeed CAN. Piggyback modules are available (one
for each port) which add Lowspeed CAN support in order to switch between
Highspeed and Lowspeed CAN controlled by the driver block. The board is a
memory mapped PCI device, which uses 64k Bytes of address space. The
address space is assigned automatically by the PCI BIOS of the target PC and
lies usually in the range between 2G bytes and 4G bytes. Any new projects
where a desktop PC is used as the target system should use this board and not
the ISA board described above.
CAN-AC2-104
This is the CAN-board for the PC/104-bus offering two CAN ports. The
CAN-controllers used on the board are the SJA1000 from Philips. The board
offers both Standard and Extended identifiers for Highspeed CAN. A Lowspeed
CAN hardware extension is not available. The board is both I/O-mapped and
memory-mapped. The I/O-mapped area uses a 3 bytes big address range and
the memory-mapped area uses a 16k bytes big address range between 640k
bytes and 1M bytes.
4-4
Introduction
The xPC Target Setup up window opens. The popup control of interest is
labeled “CANLibrary”, the same name as used for the property name. The
default property value is “None” which means that no CAN-library will be
linked to the target application.
4-5
4 CAN I/O Support
4-6
Introduction
The following table shows which CAN-Library property value depending on the
used board or boards.
* the setting ‘1000 MB PCI’ is the same as ‘1000 PCI’ and is still supported in
order to provide backward compatibility to version 1.0 of xPC Target.
The environment setup allows to set one of the above property values. This does
imply that you cannot mix different types of Softing CAN-boards in the same
target system. For example you cannot use a CAN-AC2 (ISA) board together
with a CAN-AC2-PCI board in the same target PC (desktop). On the other hand
the xPC Target CAN-drivers support multiple boards of the same type
(CAN-AC2-PCI and CAN-AC2-104, but not CAN-AC2 (ISA)) in the same target
PC. For more information see the board specific driver block description.
After having chosen the right CAN-library push the “Update”-button to make
the current setting the actual setting. If this is the only property you have
changed in the environment setup the regeneration of the target boot floppy
disk is not necessary.
After this, close the xpcsetup-GUI. You are now ready to create the first target
application using CAN driver blocks
4-7
4 CAN I/O Support
CAN driver blocks for the CAN-AC2 (ISA) with Philips PCA
82C200 CAN-Controller
The driver blocks described here support the CAN-AC2 (ISA) without
piggyback modules. The Philips PCA 82C200 chip is used as the CAN
controller in this configuration and supports the Standard identifier range
only. The driver block set for this board is found in the xPC Target I/O block
library in the group CAN/Softing.
The first block group highlighted above contains the three available CAN
blocks: Setup, Send, and Receive.
4-8
CAN driver blocks for the CAN-AC2 (ISA) with Philips PCA 82C200 CAN-Controller
The dialog box of the Setup block lets you define the following settings.
CAN 1 - Baud rate — The first control (popup menu) lets you define the most
common baud rates for CAN port 1. If special timing is necessary (baud rate),
the value “User defined” can be selected. In this case the second control (edit
field) is used to provide the four values for the timing information. The vector
elements have the following meaning
[ Prescaler, Synchronisation-Jump-Width, Time-Segement-1,
Time-Segment-2 ]
4-9
4 CAN I/O Support
For more information about these values see the Softing user manual for this
board.
CAN 2 - Baud rate — The third control (popup menu) lets you define the most
common baud rates for CAN port 2. If special timing is necessary (baud rate),
the value “User defined” can be selected. In this case the fourth control (edit
field) is used to provide the four values for the timing information. The vector
elements have the following meaning
[ Prescaler, Synchronisation-Jump-Width, Time-Segement-1,
Time-Segment-2 ]
For more information about these values see the Softing user manual for this
board.
Initialization and Termination — The fifth and sixth control (edit fields) can
be used to define CAN messages sent during initialization and termination of
the Setup block.
Memory base address — The seventh control (popup menu) is used to define
the memory base address of the board. The address range used by the board
has to be set by hardware jumpers on the board itself. Refer to the Softing user
manual on how set the various address ranges. The setting in the dialog box
has to correspond to the jumper setting otherwise the board cannot be accessed.
The available address ranges (memory base address) in the popup menu are
those supported by the board. Because the xPC Target kernel only reserves a
sub range (C0000 – DC000) of the 640 kilobyte to 1 megabyte address range for
memory mapped devices, the valid settings when used within a xPC target
systems are:
1 (16k): D0000-D3FFF
2 (16k): D4000-D7FFF
The board allows to activate proper termination for each of the two CAN ports
separately by means of hardware jumpers. Refer to the Softing user manual on
how the jumpers have to be set. Both CAN ports have to be terminated properly
when you use the provided loop-back model in order to test the board and
drivers.
4-10
CAN driver blocks for the CAN-AC2 (ISA) with Philips PCA 82C200 CAN-Controller
The dialog box of the block lets you define the following settings.
CAN port — The first control (popup menu) is used to select at which CAN port
the CAN message will be sent out.
Identifiers — The second control (edit field) is used to define the identifiers of
the CAN-messages sent out by this block. It has to be a row vector where the
elements define a set of Standard identifiers. Each element has to be in the
range between 0 and 2031. The number of identifiers for each CAN port in a
model per physical CAN-board cannot exceed 200 (restriction of the firmware’s
dynamic object mode). The number of elements defined here, define at the same
time the number of inputs ports of the block. The block icon displays the
selected identifier at each input port. Each input port accepts the data frame
to be sent along with the CAN-message. The signal entering each input port
has to be a scalar of type double representing the maximum size of 8 bytes of a
CAN-message data frame.
Data frame sizes — The third control (edit field) is used to define the data
frame size for each identifier (CAN-message) in bytes. It has to be a row vector
4-11
4 CAN I/O Support
where the elements define a set of data frame sizes. Each element has to be in
the range between 1 and 8. If the data frame sizes for all identifiers defined in
the control above have to be the same, the size can be provided as a scalar only
and scalar expansion applies. If the sizes are different for at least two
identifiers (CAN-messages) one size element has to be provided for each
identifier defined in the control above. Therefore the length of the two vectors
have to be the same.
Show status output ports — The fourth control (check box) lets you enable
status output ports for each identifier (CAN-message). If the check box is
checked the block shows as many output ports as input ports. The data type of
each output port is a double and the value is identical to the return argument
of function CANPC_write_object(…) described in the Softing user manual.
Refer to the manual for more information.
Sample time — The fifth control (edit field) defines the sample time at which
the Send block is executed during a model (target application) run.
You can use as many instances of the Send block in the model as needed. For
example by using two instances of the block with different sample times,
CAN-messages can be sent out at different rates. Or you can use multiple
instances to structure your model more efficiently.
4-12
CAN driver blocks for the CAN-AC2 (ISA) with Philips PCA 82C200 CAN-Controller
The dialog box of the block lets you define the following settings.
CAN port — The first control (popup menu) is used to select from which CAN
port, the CAN messages will be retrieved from.
Identifiers — The second control (edit field) is used to define the identifiers of
the CAN-messages retrieved by this block. It has to be a row vector where the
elements define a set of Standard identifiers. Each element has to be in the
range between 0 and 2031. The number of identifiers for each CAN port in a
model per physical CAN board cannot exceed 200 (restriction of the firmware’s
dynamic object mode). The number of elements defined here, define at the same
time the number of output ports of the block. The block icon displays the
selected identifier at each output port. Each output port will output the data
frame being retrieved along with the CAN-message. The signal leaving each
output port is a scalar of type double representing the maximum size of 8 bytes
of a CAN message data frame.
Output port options — The third control (popup menu) lets you define which
type of retrieved data is output at each output port. Three different types of
data can be output, which are data frame, status and timestamp. The status
4-13
4 CAN I/O Support
4-14
CAN driver blocks for the CAN-AC2 (ISA) with Intel 82527 CAN-Controller
CAN driver blocks for the CAN-AC2 (ISA) with Intel 82527
CAN-Controller
The driver blocks described here support the CAN-AC2 (ISA) with piggyback
modules. The Intel 82527 chip is used as the CAN-controller in this
configuration and supports both Standard and Extended identifier ranges in
parallel. The driver block set for this board is found in the xPC Target I/O block
library in the group CAN/Softing.
The second block group highlighted above contains the three available CAN
blocks: Setup, Send, and Receive.
4-15
4 CAN I/O Support
CAN 1 - Baud rate — The first control (popup menu) lets you define the most
common baud rates for CAN port 1. If special timing is necessary (baud rate),
the value “User defined” can be selected. In this case the second control (edit
field) is used to provide the four values for the timing information. The vector
elements have the following meaning
[ Prescaler, Synchronisation-Jump-Width, Time-Segement-1,
Time-Segment-2 ]
For more information about these values see the Softing user manual for this
board.
4-16
CAN driver blocks for the CAN-AC2 (ISA) with Intel 82527 CAN-Controller
CAN 2 - Baud rate — The third control (popup menu) lets you define the most
common baud rates for CAN port 1. If special timing is necessary (baud rate),
the value “User defined” can be selected. In this case the fourth control (edit
field) is used to provide the four values for the timing information. The vector
elements have the following meaning
[ Prescaler, Synchronisation-Jump-Width, Time-Segement-1,
Time-Segment-2 ]
For more information about these values see the Softing user manual for this
board.
Initialization and Termination — The fifth and sixth control (edit fields) can
be used to define CAN messages sent during initialization and termination of
the Setup block.
Memory base address — The seventh control (popup menu) is used to define
the memory base address of the board. The address range used by the board
has to be set by hardware jumpers on the board itself. Refer to the Softing user
manual on how set the various address ranges. The setting in the dialog box
has to correspond to the jumper setting otherwise the board cannot be accessed.
The available address ranges (memory base address) in the popup menu are
those supported by the board. Because the xPC Target kernel only reserves a
sub range (C0000 – DC000) of the 640 kilobyte to 1 megabyte address range for
memory mapped devices, the valid settings when used within a xPC target
systems only are:
1 (16k): D0000-D3FFF
2 (16k): D4000-D7FFF
The board allows activating proper termination for each of the two CAN ports
separately by means of hardware jumpers. Refer to the Softing user manual on
how the jumpers have to be set. Both CAN ports have to be terminated properly
when you use the provided loop-back model in order to test the board and
drivers.
4-17
4 CAN I/O Support
The dialog box of the block lets you define the following settings.
CAN port — The first control (popup menu) is used to select at which CAN port
the CAN message will be sent out.
CAN identifier range — The second control (popup menu) is used to select the
identifier range of the CAN messages sent out by this block instance. If an
application makes use of mixed Standard and Extended identifier ranges, at
least two instances of this block have to be used, each defining the
corresponding identifier range.
Identifiers — The third control (edit field) is used to define the identifiers of
the CAN-messages sent out by this block. It has to be a row vector where the
elements define a set of either Standard or Extended identifiers. Each element
has to be in the range between 0 and 2031 for Standard identifiers or 0 and
(2^29)-1 for Extended identifiers. The number of identifiers for each CAN port
in a model per physical CAN-board cannot exceed 200 (restriction of the
4-18
CAN driver blocks for the CAN-AC2 (ISA) with Intel 82527 CAN-Controller
firmware’s dynamic object mode). The number of elements defined here, define
at the same time the number of inputs ports of the block. The block icon
displays the selected identifier at each input port. Each input port accepts the
data frame to be sent along with the CAN-message. The signal entering each
input port has to be a scalar of type double representing the maximum size of
8 bytes of a CAN-message’s data frame.
Data frame sizes — The fourth control (edit field) is used to define the data
frame size for each identifier (CAN-message) in bytes. It has to be a row vector
where the elements define a set of data frame sizes. Each element has to be in
the range between 1 and 8. If the data frame sizes for all identifiers defined in
the control above have to be the same, the size can be provided as a scalar only
and scalar expansion applies. If the sizes are different for at least two
identifiers (CAN-messages) one size element has to be provided for each
identifier defined in the control above. Therefore the length of the two vectors
have to be the same.
Show status: Output ports — The fourth control (checkbox) lets you enable
status output ports for each identifier (CAN message). If the checkbox is
checked, the block shows as many output ports as input ports. The data type of
each output port is a double and the value is identical to the return argument
of function CANPC_write_object(…) described in the Softing user manual.
Refer to the manual for more information.
Sample time — The fifth control (edit field) defines the sample time at which
the Send block is executed during a model (target application) run.
You can use as many instances of the Send block in the model as needed. For
example by using two instances of the block, different sample times at which
CAN messages are sent out can be defined. Or you can use multiple instances
to structure your model more efficiently.
4-19
4 CAN I/O Support
The dialog box of the block lets you define the following settings.
CAN port — The Receive driver block is used to retrieve data from a
CAN network to be used within a block model. The first control (popup menu)
is used to select from which CAN port, the CAN messages will be retrieved
from.
CAN identifier range — The second control (popup menu) is used to select the
identifier range of the CAN messages retrieved by this block instance. If an
application makes use of mixed Standard and Extended identifier ranges, at
least two instances of this block have to be used, each defining the
corresponding identifier range.
Identifiers — The third control (edit field) is used to define the identifiers of
the CAN messages retrieved by this block. It has to be a row vector where the
elements define a set of either Standard or Extended identifiers. Each element
has to be in the range between 0 and 2031 for Standard identifiers or 0 and
229 - 1 for Extended identifiers. The number of identifiers for each CAN port in
4-20
CAN driver blocks for the CAN-AC2 (ISA) with Intel 82527 CAN-Controller
a model per physical CAN board cannot exceed 200 (restriction of the
firmware’s dynamic object mode). The number of elements defined here, define
at the same time the number of output ports of the block. The block icon
displays the selected identifier at each output port. Each output port will
output the data frame being retrieved along with the CAN-message. The signal
leaving each output port is a scalar of type double representing the maximum
size of 8 bytes of a CAN-message’s data frame.
Output port options — The fourth control (popup menu) lets you define which
type of retrieved data is output at each output port. Three different types of
data can be output, which are data frame, status and timestamp. The status
information is of type double and is identical to the return value of function
CANPC_read_rcv_data(…) described in the Softing user manual. Refer to the
manual for more information. The timestamp information is of type double and
outputs the latest time at which a CAN message with the corresponding
identifier has been received. This time information in seconds (with a
resolution of 1 microsecond) can be used to implement timeout-logic within
your model.
The popup menu lets you select which output information is output at each
output port of the block. If “Data” is selected each output port signal is a scalar
only. If “Data – Status” is selected each output port signal is a vector with two
elements, where the first element contains the data frame and the second
element the status information. If “Data – Status – Timestamp” is selected
each output port signal is a vector with three elements, where the first element
contains the data frame, the second element the status information, and the
third element the timestamp.
Generate interrupts — The fifth control (check box) lets you define if the CAN
messages defined in this instance of the block will initiate an interrupt from
the CAN board each time they are received. If checked this allows driving the
model (target application) execution controlled by CAN messages.
Sample time — The sixth control (edit field) defines the sample time at which
the Send block is executed during a model (target application) run.
You can use as many instances of the Receive block in the model as needed. For
example by using two instances of the block with different sample times, CAN
messages can be retrieved at different rates. Or you can use multiple instances
to structure your model more efficiently.
4-21
4 CAN I/O Support
4-22
CAN driver blocks for the CAN-AC2-PCI with Philips SJA1000 CAN-Controller
The third block group highlighted above contains the three available CAN
blocks: Setup, Send, and Receive.
4-23
4 CAN I/O Support
The dialog box of the Setup block lets you define the following settings.
Board — The first control (popup menu) lets you define which board is being
accessed by this driver block instance. The board number (1…3) can be seen as
a reference identifier in order to differentiate the boards if multiple boards are
present in the target system. The physical board finally referenced by the
board number depends on the PCI Slot edit field described further below. If just
one board is present in the target system, board number 1 should be selected.
CAN 1 - Physical bus — The second control (popup menu) is used to define the
physical CAN bus type of CAN port 1. In the board standard hardware
configuration only Highspeed CAN is supported. By extending the board with
Lowspeed CAN piggyback modules it is possible to additionally select
Lowspeed CAN as the physical bus. The value of this control shouldn’t be
4-24
CAN driver blocks for the CAN-AC2-PCI with Philips SJA1000 CAN-Controller
For more information about these values see the Softing user manual for this
board.
CAN 2 - Physical bus — The fifth control (popup menu) is used to define the
physical CAN bus type of CAN port 2. In the board’s standard hardware
configuration only Highspeed CAN is supported. By extending the board with
Lowspeed CAN piggyback modules it is possible to additionally select
Lowspeed CAN as the physical bus. The value of this control shouldn’t be
changed to Lowspeed if no module is present for the corresponding CAN port.
If the module is present (see the Softing user manual on how to install the
modules) you can select between Highspeen and Lowspeed CAN here.
CAN 2 - Baud rate — The sixth control (popup menu) lets you define the most
common baud rates for CAN port 2. If special timing is necessary (baud rate),
the value “User defined” can be selected. In this case the seventh control (edit
field) is used to provide the four values for the timing information. The vector
elements have the following meaning
[ Prescaler, Synchronisation-Jump-Width, Time-Segement-1,
Time-Segment-2 ]
For more information about these values see the Softing user manual for this
board.
Initialization and Termination — The eighth and ninth control (edit fields)
can be used to define CAN messages sent during initialization and termination
of the Setup block.
PCI slot (-1: autosearch) — The tenth control (edit field) is used to define the
PCI slot in which the referenced board (board number) resides. If only one
board is present in the target system the value for this control should be –1
4-25
4 CAN I/O Support
(autosearch). This value makes sure that the xPC Target kernel automatically
finds the board independently of the PCI slot it is plugged into. If more than
one board is present in the target system the correct PCI slot number has to be
provided for each board. Use the xPC Target function ‘xpcgetpci’ to query the
target system for installed PCI boards and the PCI slots they are plugged into.
For more information see ‘help getxpcpci’.
The board allows activating proper termination for each of the two CAN ports
separately by means of DIP-switches at the rear panel of the board. Refer to the
Softing user manual on how the DIP-switches have to be set. Both CAN ports
have to be terminated properly when you use the provided loop-back model in
order to test the board and drivers.
4-26
CAN driver blocks for the CAN-AC2-PCI with Philips SJA1000 CAN-Controller
The dialog box of the block lets you define the following settings.
Board — The first control (popup menu) lets you define which physically
present board is used to send out the CAN-messages defined by this block
instance. For more information about the meaning of the board number see the
Setup driver block described above. If just one board is present in the target
system, board number 1 should be selected.
CAN Port — The second control (popup menu) is used to select at which CAN
port the CAN message will be sent out.
CAN Identifier range — The third control (popup menu) is used to select the
identifier range of the CAN-messages sent out by this block instance. If an
application makes use of mixed Standard and Extended identifier ranges, at
4-27
4 CAN I/O Support
least two instances of this block have to be used, each defining the
corresponding identifier range.
Identifiers — The fourth control (edit field) is used to define the identifiers of
the CAN-messages sent out by this block. It has to be a row vector where the
elements define a set of either Standard or Extended identifiers. Each element
has to be in the range between 0 and 2031 for Standard identifiers or 0 and
(2^29)-1 for Extended identifiers. The number of identifiers for each CAN port
in a model per physical CAN board cannot exceed 200 (restriction of the
firmware’s dynamic object mode). The number of elements defined here, define
at the same time the number of inputs ports of the block. The block icon
displays the selected identifier at each input port. Each input port accepts the
data frame to be sent along with the CAN message. The signal entering each
input port has to be a scalar of type double representing the maximum size of
8 bytes of a CAN message’s data frame.
Data frame size — The fifth control (edit field) is used to define the data frame
size for each identifier (CAN-message) in bytes. It has to be a row vector where
the elements define a set of data frame sizes. Each element has to be in the
range between 1 and 8. If the data frame sizes for all identifiers defined in the
control above have to be the same, the size can be provided as a scalar only and
scalar expansion applies. If the sizes are different for at least two identifiers
(CAN messages) one size element has to be provided for each identifier defined
in the control above. Therefore the length of the two vectors have to be the
same.
Show status output ports — The sixth control (check box) lets you enable
status output ports for each identifier (CAN-message). If the check box is
checked the block shows as many output ports as input ports. The data type of
each output port is a double and the value is identical to the return argument
of function CANPC_write_object(…) described in the Softing user manual.
Refer to the manual for more information.
Sample time — The seventh control (edit field) defines the sample time at
which the Send block is executed during a model (target application) run.
You can use as many instances of the Send block in the model as needed. For
example by using two instances of the block, different sample times at which
CAN-messages are sent out can be defined. Or you can use multiple instances
to structure your model more efficiently.
4-28
CAN driver blocks for the CAN-AC2-PCI with Philips SJA1000 CAN-Controller
Board — The dialog box of the block lets you define the following settings.
The first control (popup menu) lets you define from which physically present
board the CAN messages defined by this block instance are retrieved from. For
more information about the meaning of the board number see the Setup driver
block described above. If just one board is present in the target system, board
number 1 should be selected.
CAN Port — The second control (popup menu) is used to select from which
CAN port, the CAN messages will be retrieved from.
CAN Identifier range — The third control (popup menu) is used to select the
identifier range of the CAN-messages retrieved by this block instance. If an
application makes use of mixed Standard and Extended identifier ranges, at
4-29
4 CAN I/O Support
least two instances of this block have to be used, each defining the
corresponding identifier range.
Identifiers — The fourth control (edit field) is used to define the identifiers of
the CAN-messages retrieved by this block. It has to be a row vector where the
elements define a set of either Standard or Extended identifiers. Each element
has to be in the range between 0 and 2031 for Standard identifiers or 0 and
229 - 1 for Extended identifiers. The number of identifiers for each CAN port in
a model per physical CAN board cannot exceed 200 (restriction of the
firmware’s dynamic object mode). The number of elements defined here, define
at the same time the number of output ports of the block. The block icon
displays the selected identifier at each output port. Each output port will
output the data frame being retrieved along with the CAN message. The signal
leaving each output port is a scalar of type double representing the maximum
size of 8 bytes of a CAN message’s data frame.
Output port options — The fifth control (popup menu) lets you define which
type of retrieved data is output at each output port. Three different types of
data can be output, which are data frame, status and timestamp. The status
information is of type double and is identical to the return value of function
CANPC_read_rcv_data (…) described in the Softing user manual. Refer to the
manual for more information. The timestamp information is of type double and
outputs the latest time at which a CAN message with the corresponding
identifier has been received. This time information in seconds (with a
resolution of 1 microsecond) can be used to implement timeout-logic within
your model. The popup menu lets you select which output information is output
at each output port of the block. If Data is selected each output port signal is a
scalar only. If Data – Status is selected each output port signal is a vector with
two elements, where the first element contains the data frame and the second
element the status information. If Data – Status – Timestamp is selected each
output port signal is a vector with three elements, where the first element
contains the data frame, the second element the status information, and the
third element the timestamp.
Generate interrupts — The sixth control (check box) lets you define if the
CAN messages defined in this instance of the block will initiate an interrupt
from the CAN board each time they are received. If checked this allows driving
the model (target application) execution controlled by CAN messages.
Sample time — The seventh control (edit field) defines the sample time at
which the Send block is executed during a model (target application) run.
4-30
CAN driver blocks for the CAN-AC2-104 (PC/104) with Philips SJA1000 CAN-Controller
The fourth block group highlighted above contains the three available CAN
blocks: Setup, Send, and Receive.
4-31
4 CAN I/O Support
The dialog box of the Setup block lets you define the following settings.
Board — The first control (popup menu) lets you define which board is being
accessed by this driver block instance. The board number (1…3) can be seen as
a reference identifier in order to differentiate the boards if multiple boards are
present in the target system. The physical board finally referenced by the
4-32
CAN driver blocks for the CAN-AC2-104 (PC/104) with Philips SJA1000 CAN-Controller
board number depends on the I/O Base Address edit field described further
below. If just one board is present in the target system, board number 1 should
be selected.
CAN 1 - Baud rate — The second control (popup menu) lets you define the most
common baud rates for CAN port 1. If special timing is necessary (baud rate),
the value CAN 1 - User defined baud rate can be selected. In this case the
third control (edit field) is used to provide the four values for the timing
information. The vector elements have the following meaning
[ Prescaler, Synchronisation-Jump-Width, Time-Segement-1,
Time-Segment-2 ]
For more information about these values see the Softing user manual for this
board.
CAN 1 - Baud rate — The fourth control (popup menu) lets you define the most
common baud rates for CAN port 2. If special timing is necessary (baud rate),
the value “User defined” can be selected. In this case the fifth control (edit field)
is used to provide the four values for the timing information. The vector
elements have the following meaning
[ Prescaler, Synchronisation-Jump-Width, Time-Segement-1,
Time-Segment-2 ]
For more information about these values see the Softing user manual for this
board.
Initialization and Termination — The sixth and seventh control (edit fields)
can be used to define CAN messages sent during initialization and termination
of the Setup block.
I/O Base address — The eighth control (edit field) is used to define the I/O base
address of the board to be accessed by this block instance. The I/O Base address
is given by the DIP-switch setting on the board itself. The I/O address range is
3 bytes and is mainly used to transfer the information which memory base
address the board should use. See the Softing user manual for this board on
how the I/O base address can be set. The I/O base address entered in this
control has to correspond with the DIP-switch setting on the board. If more
than one board is present in the target system a different I/O base address has
to be entered for each board. In this case the I/O base address itself defines
which board is referenced by which board number.
4-33
4 CAN I/O Support
Memory base address — The ninth control (edit field) is used to define the
memory base address of the board to be accessed by this block instance. The
memory base address is a software setting only (no corresponding DIP-switch
is found on the board). The memory address range is 64 kilobytes. If more than
one board is present in the target system a different memory base address has
to be entered for each board and you have to make sure that the defined
address ranges do not overlap. Because the xPC Target kernel only reserves a
subset of the address range between 640 kilobytes and 1megabytes for memory
mapped devices the address ranges have to lie within the following range:
C0000 – DC000
The board allows activating proper termination for each of the two CAN ports
separately by means of jumpers found on the board. Refer to the boards user
manual on how the DIP-switches have to be set. Both CAN ports have to be
terminated properly when you use the provided loop-back model in order to test
the board and drivers.
4-34
CAN driver blocks for the CAN-AC2-104 (PC/104) with Philips SJA1000 CAN-Controller
The dialog box of the block lets you define the following settings.
Baud — The first control (popup menu) lets you define which physically
present board is used to send out the CAN messages defined by this block
instance. For more information about the meaning of the board number see the
Setup driver block described above. If just one board is present in the target
system, board number 1 should be selected.
CAN Port — The second control (popup menu) is used to select at which CAN
port the CAN message will be sent out.
CAN Identifier range — The third control (popup menu) is used to select the
identifier range of the CAN-messages sent out by this block instance. If an
application makes use of mixed Standard and Extended identifier ranges, at
4-35
4 CAN I/O Support
least two instances of this block have to be used, each defining the
corresponding identifier range.
Identifiers — The fourth control (edit field) is used to define the identifiers of
the CAN messages sent out by this block. It has to be a row vector where the
elements define a set of either Standard or Extended identifiers. Each element
has to be in the range between 0 and 2031 for Standard identifiers or 0 and
229 - 1 for Extended identifiers. The number of identifiers for each CAN port in
a model per physical CAN-board cannot exceed 200 (restriction of the
firmware’s dynamic object mode). The number of elements defined here, define
at the same time the number of inputs ports of the block. The block icon
displays the selected identifier at each input port. Each input port accepts the
data frame to be sent along with the CAN message. The signal entering each
input port has to be a scalar of type double representing the maximum size of
8 bytes of a CAN message’s data frame.
Data frame sizes — The fifth control (edit field) is used to define the data
frame size for each identifier (CAN-message) in bytes. It has to be a row vector
where the elements define a set of data frame sizes. Each element has to be in
the range between 1 and 8. If the data frame sizes for all identifiers defined in
the control above have to be the same, the size can be provided as a scalar only
and scalar expansion applies. If the sizes are different for at least two
identifiers (CAN messages) one size element has to be provided for each
identifier defined in the control above. Therefore the length of the two vectors
have to be the same.
Show status output ports — The sixth control (check box) lets you enable
status output ports for each identifier (CAN message). If the check box is
checked the block shows as many output ports as input ports. The data type of
each output port is a double and the value is identical to the return argument
of function CANPC_write_object(…) described in the Softing user manual.
Refer to the manual for more information.
Sample time — The seventh control (edit field) defines the sample time at
which the Send block is executed during a model (target application) run.
You can use as many instances of the Send block in the model as needed. For
example by using two instances of the block, different sample times at which
CAN messages are sent out can be defined. Or you can use multiple instances
to structure your model more efficiently.
4-36
CAN driver blocks for the CAN-AC2-104 (PC/104) with Philips SJA1000 CAN-Controller
The dialog box of the block lets you define the following settings.
Board — The first control (popup menu) lets you define from which physically
present board the CAN messages defined by this block instance are retrieved
from. For more information about the meaning of the board number see the
Setup driver block described above. If just one board is present in the target
system, board number 1 should be selected.
CAN Port — The second control (popup menu) is used to select from which
CAN port, the CAN messages will be retrieved from.
CAN Identifier range — The third control (popup menu) is used to select the
identifier range of the CAN messages retrieved by this block instance. If an
application makes use of mixed Standard and Extended identifier ranges, at
4-37
4 CAN I/O Support
least two instances of this block have to be used, each defining the
corresponding identifier range.
Identifiers — The fourth control (edit field) is used to define the identifiers of
the CAN messages retrieved by this block. It has to be a row vector where the
elements define a set of either Standard or Extended identifiers. Each element
has to be in the range between 0 and 2031 for Standard identifiers or 0 and
229 - 1 for Extended identifiers. The number of identifiers for each CAN port in
a model per physical CAN board cannot exceed 200 (restriction of the
firmware’s dynamic object mode). The number of elements defined here, define
at the same time the number of output ports of the block. The block icon
displays the selected identifier at each output port. Each output port will
output the data frame being retrieved along with the CAN message. The signal
leaving each output port is a scalar of type double representing the maximum
size of 8 bytes of a CAN-message’s data frame.
Output port options — The fifth control (popup menu) lets you define which
type of retrieved data is output at each output port. Three different types of
data can be output, which are data frame, status and timestamp. The status
information is of type double and is identical to the return value of function
CANPC_read_rcv_data(…) described in the Softing user manual. Refer to the
manual for more information. The timestamp information is of type double and
outputs the latest time at which a CAN message with the corresponding
identifier has been received. This time information in seconds (with a
resolution of 1 microsecond) can be used to implement timeout-logic within
your model.
The popup menu lets you select which output information is output at each
output port of the block. If “Data” is selected each output port signal is a scalar
only. If “Data – Status” is selected each output port signal is a vector with two
elements, where the first element contains the data frame and the second
element the status information. If “Data – Status – Timestamp” is selected
each output port signal is a vector with three elements, where the first element
contains the data frame, the second element the status information, and the
third element the timestamp.
Generate interrupts — The sixth control (check box) lets you define if the
CAN messages defined in this instance of the block will initiate an interrupt
from the CAN board each time they are received. If checked this allows driving
the model (target application) execution controlled by CAN messages. Sample
time - The seventh control (edit field) defines the sample time at which the
Send block is executed during a model (target application) run.
4-38
Constructing and Extracting CAN Data Frames
The main purpose of the two blocks is to be used in conjunction with CAN Send
and Receive driver blocks, but they can be used as well for other types of data
manipulation. Their functionality is entirely independent of any CAN driver
blocks or CAN library.
4-39
4 CAN I/O Support
The dialog box contains one single control (edit field) which lets you define the
bit patterns in a flexible way. The data type entered in the control has to be a
MATLAB cell array vector. The number of elements in the cell array define the
number of input ports shown by this block instance. The cell array elements
have to be of type double array and define where each bit of the incoming value
(data typed input port) comes to lie at what position in the outgoing double
value (data frame).
From a data type perspective (input ports) the block behaves like a Simulink
sink block and therefore the data types of the input ports are inherited from
the driving blocks.
The sample time of the block is also inherited from the driving blocks.
Therefore no explicit sample time has to be provided in the block’s dialog box.
The functionality of the block is easiest explained by means of an example.
4-40
Constructing and Extracting CAN Data Frames
We assume that a node on the CAN network needs to receive a CAN message
with identifier 156 having the following data frame content. The data frame
has to be 6 bytes long.
The bit pattern cell array, which bit-packs the data frame according to the
above specification, can look as follows.
{ [0:7] , [15:-1:8] , [16:23] , [25] , [-1,-1,26:31] , [32:47] }
And the Simulink model simulating the needed behavior would be as show
below.
4-41
4 CAN I/O Support
4-42
Constructing and Extracting CAN Data Frames
has to get bit 15, the second bit 14 and so on. It is easiest to define this mapping
by the MATLAB colon operator: and an increment of –1.
The third input is only necessary because the reserved byte 2 has to have all
bits set to 1. If a bit position in the outgoing data frame isn’t referenced by a bit
pattern array element, the bit will be by default 0, but there is no construct to
have them set to 1 as the default. Therefore a uint8 constant with value 255
has to be externally brought in. The constant 255 has to get to bit position 16
to 23 (byte 2) of the outgoing data frame.
Because bit 0 of data frame byte 3 (bit 24) has to be 0 and 0 is the default bit
value if not referenced by a bit pattern array element, no explicit action has to
be taken here.
The fourth input is the Flag of type boolean, which has an example value of 1.
This value has to become bit 1 of byte 3 (bit 25) of the data frame. Therefore the
single bit (element 1 of double array [25]) has to get bit 25 of the data frame.
The fifth input is the Control of type int8, which has an example value of 121.
But only bits 2 to 7 have to be mapped into the outgoing data frame or in other
words bits 0 and 1 have to be thrown away. Because indexing of incoming
values always starts with the first bit (bit 0) a special indexing value (-1) has
to be used in order to skip bit 0 and 1 of the incoming int8 value. Bits 2 to 7 will
be directly mapped to bit 2 to 7 of byte 3 (bits 26 to 31) of the outgoing data
frame. This leads to the following bit pattern: [-1,-1,26:31]
The sixth input is the Value of type int16, which has an example value of –
12270. This value has to become byte 4 and 5 (bits 32 to 47) of the outgoing data
frame. Therefore the first bit (element 1 of double array [32:47]) has to get bit
32 of the data frame, the second bit 33 and so on. It is easiest to define this
mapping by the MATLAB colon operator:.
The output of the block then consists of a double value representing the packed
data types within the first 6 bytes. The last two bytes are zero. This means that
even in the case were less than 8 bytes are significant, the CAN data frame is
always represented by a double value (8 bytes). The value of the constructed
floating point double doesn’t have any particular meaning but still can be
inspected by a numerical display.
4-43
4 CAN I/O Support
The data frame is then propagated to the CAN Send driver block and is sent
out as part of a CAN-message having identifier 156. When looking at the Send
block’s dialog box, the data frame size is defined as 6 bytes. This makes sure
that only the first 6 bytes of the incoming double value are transmitted as part
of the CAN-message.
4-44
Constructing and Extracting CAN Data Frames
The sample time of the block is inherited from the driving block. Therefore no
explicit sample time has to be provided in the block’s dialog box.
The functionality of the block is easiest explained by means of an example. We
take the same example as used above to demonstrate the functionality of the
bit-packing block. But in this case, the data frame is sent by an external CAN
node and is received by the target application running on an xPC Target
system. Therefore the bit-unpacking block has to be used in order to extract the
various data fields out of the entire data frame. Because the bit pattern
4-45
4 CAN I/O Support
definition of the packing and unpacking block are symmetric, the bit pattern
definition could look exactly the same. There is one simple optimization
possible: We don’t have to extract byte 2 (reserved area), because it’s content is
known. The bit pattern edit field can therefore look as follows,
{ [0:7] , [15:-1:8] , [25] , [-1,-1,26:31] , [32:47] }
4-46
Constructing and Extracting CAN Data Frames
4-47
4 CAN I/O Support
4-48
Detecting Timeouts When Receiving CAN Messages
The dialog box of the CAN Timeout Detection block has one edit field and lets
you define the timeout value in seconds. The output of the block will be 0 if no
timeout has been detected and 1 otherwise. See as well the loop-back example
for the CAN-AC2-PCI and CAN-AC2-104 boards (xpccanpci and xpccanpc104)
which make use of this utility block as well.
4-49
4 CAN I/O Support
1 The timer interrupt line in the kernel setup has to be replaced by the board’s
hardware interrupt line.
2 The CAN Setup and CAN Receive blocks have to be properly set up.
Both steps are slightly different for each of the three supported CAN boards.
Therefore the two steps are explained for each board type below.
CAN-AC2 (ISA)
The CAN-AC2 is an ISA-board, and the hardware interrupt line is set by means
of hardware jumpers on the board. Refer to the Softing user manual of the
board on how to set a certain interrupt line. Select an interrupt line, which is
not used by any other hardware device in the xPC Target system (for example
by the Ethernet card).
1 In the Simulink window, and from the Tools menu, point to Real-Time
Workshop, and then click Options. Select the category “xPC Target code
generations options” in the displayed dialog box. In the “Real-Time
Interrupt Source” popup menu select the interrupt line number which you
have set by the jumpers on the board. Close the dialog box and save the
model.
2 Open the dialog box of the CAN Receive block in the model which defines the
CAN message (identifier) to be used to fire the interrupt. Check the
4-50
Model execution driven by CAN-messages (Interrupt capability of CAN Receive blocks)
Generate interrupts check box. Checking this box will declare all
CAN-messages defined in this Receive block instance through their
identifiers as messages, which will fire an interrupt. Or in other words it is
not possible to define a single CAN message within the set of defined
identifiers to be the only one to fire an interrupt. In most cases only the
reception of one specific message is used to drive the application execution.
Therefore use at least two instances of the Receive block. One to receive the
CAN message, which drives the execution (Generate Interrupts checked)
and the other for all other “normal” CAN-messages to be received (Generate
Interrupts unchecked).
CAN-AC2-PCI
The CAN-AC2 is a PCI-board, and the hardware interrupt line is automatically
assigned by the PCI BIOS during the boot-up of the target system. Use the xPC
Target function ‘getxpcpci’ (see ‘help getxpcpci’) at the MATLAB command
prompt to query the target system for installed PCI devices and the assigned
resources. Write down the interrupt line number assigned to the
CAN-AC2-PCI board.
1 In the Simulink window, and from the Tools menu, point to Real-Time
Workshop, and then click Options. Select the category “xPC Target code
generations options” in the displayed dialog box. In the “Real-Time
Interrupt Source” popup menu select the interrupt line number which you
have retrieved by calling ‘getxpcpci’. Close the dialog box and save the
model.
2 Open the dialog box of the CAN Receive block in the model which defines the
CAN-message (identifier) to be used to fire the interrupt. Check the
Generate interrupts check box. Checking this box will declare all
CAN-messages defined in this Receive block instance through their
identifiers as messages, which will fire an interrupt. Or in other words it is
not possible to define a single CAN-message within the set of defined
identifiers to be the only one to fire an interrupt. In most cases only the
reception of one specific message is used to drive the application execution.
Therefore use at least two instances of the Receive block. One to receive the
CAN-message, which drives the execution (Generate Interrupts checked)
and the other for all other “normal” CAN-messages to be received (Generate
Interrupts unchecked).
4-51
4 CAN I/O Support
CAN-AC2-104 (PC/104)
The CAN-AC2-104 is an ISA-board (PC/104), and the hardware interrupt line
is set by means of a software setting within the CAN Setup driver block. Write
down a free interrupt line, which is not used by any other hardware device in
the xPC target system (for example by the Ethernet card).
1 In the Simulink window, and from the Tools menu, point to Real-Time
Workshop, and then click Options. Select the category “xPC Target code
generations options” in the displayed dialog box. In the “Real-Time
Interrupt Source” popup menu select the interrupt line number which you
have chosen.
2 In the model open the dialog box of the CAN Setup block for the
CAN-AC2-104 board. Select the chosen interrupt line in the “Interrupt Line”
popup menu and close the dialog box. Open the dialog box of the CAN
Receive block in the model which defines the CAN-message (identifier) to be
used to fire the interrupt. Check the “Generate interrupts” check box.
Checking this box will declare all CAN-messages defined in this Receive
block instance through their identifiers as messages, which will fire an
interrupt. Or in other words it is not possible to define a single
CAN-message within the set of defined identifiers to be the only one to fire
an interrupt. In most cases only the reception of one specific message is used
to drive the application execution. Therefore use at least two instances of the
Receive block. One to receive the CAN-message, which drives the execution
(Generate Interrupts checked) and the other for all other “normal”
CAN-messages to be received (Generate Interrupts unchecked).
After having completed the two steps the model is ready to be built. After the
downloading has succeeded and the target application execution has been
started, the execution is now driven by the selected CAN-message(s). The
execution time information displayed on the target screen is now directly
dependent on the reception of the corresponding message. If no message is
received the time will not advance. You should make sure, that the
corresponding CAN-message on the other CAN node is only generated if the
xPC target application is running, otherwise “unexpected interrupt” messages
may be displayed on the target screen.
4-52
Defining Initialization and Termination CAN Messages
4-53
4 CAN I/O Support
Example
Let’s consider an A/D converter module with a CANOpen interface. After the
node has been powered up, the module is in pre-operational mode, which is
common for CANOpen nodes. At least two initialization messages have to be
sent to the node in order to get the module fully operational.
The first message puts the node from pre-operational into operational mode.
The second message programs the module in such a sense, that each time the
converted A/D value differs for more than 10 mVolts from the former
conversion, a CAN-message is automatically sent out, with the converted value
as the data frame.
After the target application has been started and the node is properly
initialized, the node will automatically send out CAN message, which the xPC
target application receives and then processes the contained frame data.
Before the target application execution is actually stopped, the module (node)
has to be brought back into pre-operational mode. This is achieved by sending
out one corresponding termination message.
The initialization and termination message struct for this example could look
as follows.
% put node into operational mode
init(1).port=1;
init(1).type=’Standard’;
init(1).identifier=1536+11;
init(1).data=[hex2dec(’22’),hex2dec(’23’),hex2dec(’64’),hex2d
ec(’00’),hex2dec(’01’)];
init(1).pause=0.02;
4-54
5
CAN I/O Support for FIFO
Introduction . . . . . . . . . . . . . . . . . . . 13-2
FIFO Mode drivers for CAN boards from Softing . . . . . . 13-3
Examples . . . . . . . . . . . . . . . . . . . . 13-40
Example 1 . . . . . . . . . . . . . . . . . . . . 13-40
Example 2 . . . . . . . . . . . . . . . . . . . . 13-42
Example 3 . . . . . . . . . . . . . . . . . . . . 13-43
Example 4 - . . . . . . . . . . . . . . . . . . . . 13-44
Example 5 . . . . . . . . . . . . . . . . . . . . 13-45
Example 6 . . . . . . . . . . . . . . . . . . . . 13-46
5 CAN I/O Support for FIFO
Introduction
This chapter describes the alternative First In First Out (FIFO) CAN drivers
provided with xPC Target. The standard CAN drivers, for the CAN boards from
Softing GmbH, program the CAN board firmware to run in Dynamic Object
Buffer (DOB) mode. This mode is best suited for real-time environments where
it is mandatory that the driver latency time is time deterministic. Actually,
running the firmware in Dynamic Object Buffer mode would always be the best
choice, but this mode has the undesired side effect of high driver latency times.
• Sending a CAN message — When sending out a CAN message, the latency
time is the time interval between the time accessing the board in order to
provide all the information of the CAN message to be sent out and the time
the board returns the acknowledgement that the information has been
received by the firmware.
• Receiving a CAN message — When receiving a CAN message, the latency
time is the time interval between the time accessing the board in order to ask
for current data (object data) of a certain CAN identifier and the time the
board returns the actual data and other information about the CAN
message.
With such an application, base sample times below 800us are impossible even
if the dynamics of the corresponding Simulink model are simple and would only
need 20us of computational time.
5-2
Introduction
Advantages of Dynamic Object Buffer mode - However, even if the CAN I/O
latency time in the Dynamic Object Buffer mode is high, the benefit of this
mode is that the latency time stays constant almost independent of the traffic
volume on the CAN network. This leads to the conclusion that the Dynamic
Object Buffer mode is best suited for xPC Target applications which only have
to deal with a smaller subset of all CAN messages going over the CAN network.
5-3
5 CAN I/O Support for FIFO
total latency may easily exceed the latency encountered when using the
Dynamic Object Buffer mode driver scheme for the same application. There is
another restriction specific to the FIFO mode concept. Using more than one
Read Receive FIFO block in a Simulink model is not recommended, because a
new event (message) read by one block instance cannot be read out again by
another block instance (the event is no longer in the FIFO).Therefore the entire
CAN receive part has to be concentrated in one Read Receive FIFO block in
your model. For the write transmit FIFO side, this restriction does not apply.
Here you can use as many instances as you want.
The Setup block for the CAN FIFO mode allows controlling the CAN
acceptance filters of the CAN controller. The acceptance filter allows defining
a range of CAN messages not to be forwarded to the receive FIFO. Filtering out
unwanted CAN messages can drastically reduce the read receive FIFO latency
time because the unwanted messages do not reach the receive FIFO.
Unfortunately, the acceptance filter process uses binary evaluation, which does
not allow filtering messages below and above a certain decimal range.
Therefore the use of the acceptance filter does only resolve the problem for a
small subset of CAN network applications. See “Acceptance Filters” on page
5-38 for more information on this.
Lets look again at our example of 12 messages to be received and 8 messages
to be transmitted. If those 20 messages with their specific identifiers are the
only messages going over the CAN network (100% usage ratio) the total latency
time is:
12*17us + 8*4us = 236us
This is a considerable smaller value than the 800us, which result when using
the Dynamic Object Buffer mode drivers.
For the next case we assume that there are 12 additional messages going
regularly over the network which have not to be processed by the target
application. Additionally, we assume that those messages cannot be filtered
out by the CAN controller acceptance filter. Then the total latency time
increases to
12*17us +20*4us = 284us
There is no impact to the final result. That’s the trade-off. Therefore the FIFO
mode drivers are best suited for either CAN network monitoring applications
or low latency CAN applications where the ratio between the number of
5-4
Introduction
messages to be processed and the number of total messages going over the
network is high.
Especially for monitor type of applications the FIFO mode drivers are well
suited, because the FIFO mode can return additional information like the bus
state or the reception of error frames. The Dynamic Object Buffer mode drivers
do not allow querying such information.
This documentation only covers the differences between the Dynamic Object
Buffer mode drivers (which are the standard drivers), and the FIFO mode
drivers introduced here. It is assumed that you are familiar with the Dynamic
Object Buffer mode drivers and have successfully run one of the loop-back tests
provided with xPC Target.
If you use the FIFO mode drivers in your model, you have to replace all
Dynamic Object Buffer mode blocks (Setup, Send, Receive) by FIFO mode
driver blocks. The CAN-AC2-xxx boards from Softing do not allow to run the
two CAN ports in different modes. Therefore the mode has to be same for both
ports, but you can use more than one CAN board and run the boards in
different modes just by selecting the correct I/O driver blocks.
As mentioned in the standard CAN chapter we do not recommend using the
CAN-AC2 (ISA) for any new projects. Instead use the CAN-AC2-PCI. As a
consequence FIFO mode drivers are only provided for the CAN-AC2-PCI and
the CAN-AC2-104 boards.
5-5
5 CAN I/O Support for FIFO
The third block group highlighted above contains the FIFO mode sub group.
The highlighted group then contains all driver blocks available for FIFO Mode
CAN.
5-6
CAN FIFO driver blocks for the CAN-AC2-PCI with Philips SJA1000 CAN-Controller
5-7
5 CAN I/O Support for FIFO
Board — Defines which board is being accessed by this driver block instance.
The board number (1…3) can be seen as a reference identifier in order to
differentiate the boards if multiple boards are present in the target system.
The physical board finally referenced by the board number depends on the PCI
5-8
CAN FIFO driver blocks for the CAN-AC2-PCI with Philips SJA1000 CAN-Controller
Slot edit field described further below. If just one board is present in the target
system, board number 1 should be selected.
CAN - Physical bus — Defines the physical CAN bus type of the CAN port 1.
In the board’s standard hardware configuration, only High speed CAN is
supported. By extending the board with Low speed CAN piggyback modules, it
is possible to additionally select Low speed CAN as the physical bus. The value
of this control shouldn’t be changed to Low speed if no module is present for the
corresponding CAN port. If the module is present (see the Softing user manual
on how to install the modules), you can select between High speed and Low
speed CAN.
CAN 1 - Baud rate — Defines the most common baud rates for CAN port 1. If
special timing is necessary (baud rate), select User defined.
CAN 1 - User defined baud rate — If you select User defined from the CAN-1
Baud rate list, enter the four values for the timing information. The vector
elements have the following meaning
[ Prescaler, Synchronisation-Jump-Width, Time-Segement-1,
Time-Segment-2 ]
For more information about these values see the Softing user manual for this
board.
CAN 2 - Physical bus — Defines the physical CAN bus type of the CAN port 2.
In the board’s standard hardware configuration, only High speed CAN is
supported. By extending the board with Low speed CAN piggyback modules, it
is possible to additionally select Low speed CAN as the physical bus. The value
of this control shouldn’t be changed to Low speed if no module is present for the
corresponding CAN port. If the module is present (see the Softing user manual
on how to install the modules), you can select between High speed and Low
speed CAN here.
CAN 2- Baud rate — Defines the most common baud rates for CAN port 2. If
special timing is necessary (baud rate), select User defined.
CAN 1 - User defined baud rate — If you select User defined from the CAN-2
Baud rate list, enter the four values for the timing information. The vector
elements have the following meaning
[ Prescaler, Synchronisation-Jump-Width, Time-Segement-1,
Time-Segment-2 ]
5-9
5 CAN I/O Support for FIFO
For more information about these values see the Softing user manual for this
board.
CAN 2 - Acceptance — Defines the acceptance filters for the CAN 1 port.
Because the receive FIFO gets filled with any CAN messages going over the
bus, the use of the CAN controller acceptance filters becomes important in
order to filter out unwanted messages already at the controller level. This
acceptance filter information is provided by a row vector with 4 elements,
where the first two are used to define the acceptance mask and acceptance code
for Standard identifiers and the latter two for Extended identifiers. The default
value defined by the Setup block doesn’t filter out any messages. For
information on how to define the acceptance information in order to filter
certain messages, see “Acceptance Filters” on page 5-38.
Enable error frame detection — If the CAN controller should detect Error
frames and forward these to the Receive FIFO, check this box. Checking this
box makes sense for monitoring applications where you want to be informed
about all events going over the bus. For low latency time applications, checking
this box may increase the FIFO Read driver block latency time because the
receive FIFO gets filled with additional events.
Initialization (struct) and Termination (struct) — Define the CAN messages
sent during initialization and termination of the Setup block. For more
information, see the standard CAN driver documentation in See “Defining
Initialization and Termination CAN Messages” on page 4-53.
PCI Slot (-1: autosearch) — Defines the PCI slot in which the referenced board
(board number) resides. If only one CAN board is present in the target system,
the value for this control should be –1 for auto search. This value makes sure
that the xPC Target kernel automatically finds the board independently of the
PCI slot it is plugged into. If more than one board is present in the target
system the correct PCI slot number has to be provided for each board. Use the
xPC Target function xpcgetpci to query the target system for installed PCI
boards and the PCI slots they are plugged into. For more information see ‘help
getxpcpci’.
The board allows activating proper termination for each of the two CAN ports
separately by means of DIP-switches at the rear panel of the board. Refer to the
Softing user manual on how the DIP-switches have to be set. Both CAN ports
have to be terminated properly where you use the provided loop-back model in
order to test the board and drivers.
5-10
CAN FIFO driver blocks for the CAN-AC2-PCI with Philips SJA1000 CAN-Controller
Port — The value can be either 1 (port 1) or 2 (port 2) and defines at which port
the CAN message is sent out from.
Identifier — This is the identifier of the CAN message to be sent out. If it is a
Standard CAN message the valid range is 0 to 2047. If the CAN message is
extended, the range is 0 to 229-1.
Identifier type — The value can be either 0 (Standard identifier range) or 1
(Extended identifier range) and defines the identifier type of the outgoing CAN
message.
Data frame size — The value can be in the range of 0 to 8 and defines the data
frame size in bytes of the outgoing CAN message
Data — This is the data for the data frame itself and is defined as a double
value (8 bytes). The CAN packing block is used to construct the data as a double
value.
Because all this information can be dynamically changed in FIFO mode during
application execution, the information is provided at the block input instead of
using block parameters. In order to be able to transmit more than one CAN
message per block instance, a matrix signal is used as a container for all
information.
The dimension of the matrix signal entering the block has to be n*5, where n is
the number of CAN messages to be sent out by this block instance. Therefore
5-11
5 CAN I/O Support for FIFO
each row of the matrix signal defines one CAN message and each row combines
the 5 elements of information defined above (in this order).
For more on how to construct the correct matrix signal for the FIFO write
block, see See “Examples” on page 5-40.
For certain applications it may be necessary to make the writing of a CAN
message into the transmit FIFO dependent on the model dynamics. For this
case, the matrix signal can also be of dimension n*6 instead of n*5. In this case,
the sixth column defines if the corresponding CAN message is written into the
transmit FIFO (value 1) or not (value 0).
The dialog box of the block lets you define the following settings.
Board — Define which physically present board is used to send out the CAN
messages defined by this block instance. For more information about the
meaning of the board number see the Setup driver block described above. If just
one board is present in the target system, you should select 1.
Show status output port — Check this box to enable the status output port.
If the box is unchecked, the block does not have an output port. If enabled, a
port is shown. The signal leaving the block is a vector of type double where the
number of elements depends on the signal dimension of the block input port.
There is one element for each CAN message written into the transmit FIFO
and the value is identical to the return argument of function
CANPC_send_data(…) described in the Softing user manual. Refer to that
manual for more information.
Sample time — Defines the sample time at which the FIFO Write block is
executed during a model (target application) run.
5-12
CAN FIFO driver blocks for the CAN-AC2-PCI with Philips SJA1000 CAN-Controller
You can use as many instances of the FIFO Write block in the model as needed.
For example by using two instances of the block, different sample times at
which CAN messages are sent out can be defined. Or you can use multiple
instances to structure your model more efficiently.
Port — The value will be either 1 (port 1) or 2 (port 2) and reports at which port
the CAN message was received.
Identifier — This is the identifier of the CAN message being received. If it is
a Standard CAN message the range is 0 to 2047, if is an extended CAN
message, the range is 0 to 229-1.
5-13
5 CAN I/O Support for FIFO
Event type — This value defines the type of event read out of the receive FIFO.
The following values are defined from the Softing user manual.
0 No new event
1 Standard data frame received
2 Standard remote frame received
3 Transmission of a standard data frame is confirmed
4 -
5 Change of bus state
6 -
7 -
8 Transmission of a standard remote frame is confirmed
9 Extended data frame received
10 Transmission of an extended data frame is confirmed
11 Transmission of an extended remote frame is confirmed
12 Extended remote frame received
13 -
14 -
15 Error frame detected
Data frame size — If a data frame has been received, the length of the data in
bytes is reported by this element. Possible values are 0 to 8.
Timestamp — This element reports the time at which the event was received.
The resolution of the timestamp counter is 1us.
Data — This is the data of the data frame itself and is returned as a double
value (8 bytes). The CAN unpacking block is used to extract the data out of the
double value.
The dialog box of the block lets you define the following settings.
5-14
CAN FIFO driver blocks for the CAN-AC2-PCI with Philips SJA1000 CAN-Controller
Board — Defines which physically present board is used to send out the CAN
messages defined by this block instance. For more information about the
meaning of the board number see the Setup driver block described above. If one
board is present in the target system, select board number 1.
FIFO read depth — Defines the number of receive FIFO read attempts. Each
time the block gets executed it reads this fixed amount of events (CAN
messages) which lead to a deterministic time behavior independent of the
number of events currently stored in the receive FIFO. The Read depth (m)
defines at the same time the size of the matrix signal (m*6) leaving the first
output port. If no event is currently stored in the receive FIFO, the FIFO will
be read anyway, but the Event type will be reported as 0 (No new event).
Show status output port — Check this box to enable the Status output port.
If the box is unchecked (disabled) the block has one output port for the events.
If enabled, a second port is shown. The signal leaving that port is a vector of
type double with two elements.
[Number of lost messages (events), Bus state]
5-15
5 CAN I/O Support for FIFO
The first element returns the current value of the lost messages counter. The
receive FIFO can store up to 255 events. If the receive FIFO is not regularly
accessed for reading events, the FIFO gets filled and the lost messages counter
starts to count up. This is an indicator that events (messages) will be
unavoidably lost. The second element returns the current bus state. Possible
values are:
0 Error active
1 Error passive
2 Bus off
Sample time — The fourth control (edit field) defines the sample time at which
the FIFO Read block is executed during a model (target application) run.
It is strongly recommended that you only use one instance of this block per
physical CAN board in your model. Otherwise you may get the unwanted
behavior that one instance would read events while they have to be processed
by blocks connected to the other, second instance.
5-16
CAN FIFO driver blocks for the CAN-AC2-PCI with Philips SJA1000 CAN-Controller
CAN port — Defines the filter criterion for the CAN port. From the list, select
Any, 1, or 2.
Message type command — Defines the filter criterion for the event types. This
entry can consist of a concatenation of space delimited keywords which are:
SDF Standard data frame
SRF Standard remote frame
EDF Extended data frame
ERF Extended remote frame
EF Error frame
NE No new event
CBS Change of bus state
Message type selection mode — Defines how the event type (message type)
entered in the control above is treated. If you select Include, the event type
criterion is the sum of the concatenated keywords. If you select Exclude, the
event type criterion is equal to all event types minus the sum of the
concatenated keywords.
Identifier(s) — Defines the filter criterion for the CAN message identifiers. A
set of identifiers can be provided as a row vector.
Identifier selection mode — Defines how the identifier criterion entered in
the control above is treated. If you select Include, the identifier criterion is the
5-17
5 CAN I/O Support for FIFO
sum of all specified identifiers. If you select Exclude, the identifier criterion is
equal to all identifiers minus the specified identifiers.
You can use as many instances of this block in your model as needed. Usually,
you connect several instances in parallel to the output of the FIFO Read driver
block in order to filter out particular messages or events. For more information
on how to do this, see See “Examples” on page 5-40.
5-18
CAN FIFO driver blocks for the CAN-AC2-PCI with Philips SJA1000 CAN-Controller
The dialog box of the block lets you define the following settings.
Board — Defines which physically present board is accessed to reset the
transmit FIFO. For more information about the meaning of the board number
see the Setup driver block described above. If just one board is present in the
target system, board number 1 should be selected.
Sample time — Defines the sample time at which the FIFO Reset XMT driver
block is executed during a model (target application) run.
5-19
5 CAN I/O Support for FIFO
The dialog box of the block lets you define the following settings.
Board — Defines which physically present board is accessed to read the
current receive FIFO level. For more information about the meaning of the
board number see the Setup driver block described above. If just one board is
present in the target system, board number 1 should be selected.
Sample time — Defines the sample time at which the FIFO Read RCV Level
driver block is executed during a model (target application) run.
5-20
CAN FIFO driver blocks for the CAN-AC2-PCI with Philips SJA1000 CAN-Controller
The dialog box of the block lets you define the following settings.
Board — Defines which physically present board is accessed to reset the
receive FIFO. For more information about the meaning of the board number
see the Setup driver block described above. If just one board is present in the
target system, board number 1 should be selected.
Sample time — Defines the sample time at which the FIFO Reset RCV driver
block is executed during a model (target application) run.
5-21
5 CAN I/O Support for FIFO
The fourth block group highlighted above contains the FIFO Mode sub group.
The highlighted group then contains all driver blocks available for FIFO Mode
CAN.
5-22
CAN FIFO Driver Blocks for the CAN-AC2-104 with Philips SJA1000 CAN-Controller
5-23
5 CAN I/O Support for FIFO
Board — Define which board is being accessed by this driver block instance. If
multiple boards are present in the target system, the board number (1, 2 or3)
can be seen as a reference identifier in order to differentiate the boards. The
physical board finally referenced by the board number depends on the PCI Slot
5-24
CAN FIFO Driver Blocks for the CAN-AC2-104 with Philips SJA1000 CAN-Controller
edit field described further below. If just one board is present in the target
system, board number 1 should be selected.
CAN 1 - Baud rate — Defines the most common baud rates for CAN port 1. If
special timing is necessary (baud rate), you can select User defined.
CAN 1 - User defined baud rate — If you selected User defined from the CAN
1 - Baud rate list, enter four values for the timing information. The vector
elements have the following meaning
[ Prescaler, Synchronisation-Jump-Width, Time-Segement-1,
Time-Segment-2 ]
For more information about these values see the Softing user manual for this
board.
CAN 1 - Acceptance — Defines the acceptance filters for CAN port 1. Because
the receive FIFO gets filled with any CAN messages going over the bus, the use
of the CAN controller acceptance filters becomes important in order to filter out
unwanted messages already at the controller level. This acceptance filter
information is provided by a row vector with 4 elements, where the first two are
used to define the acceptance mask and acceptance code for Standard
identifiers and the latter two for Extended identifiers. The default value
defined by the Setup block doesn’t filter out any messages. For information how
to define the acceptance information in order to filter certain messages, see See
“Acceptance Filters” on page 5-38.
CAN 2 - Baud rate — Defines the most common baud rates for CAN port 2. If
special timing is necessary (baud rate), You can select User defined.
CAN 2- User defined baud rate — If you selected User defined from the CAN
1 - Baud rate list, enter four values for the timing information. The vector
elements have the following meaning
[ Prescaler, Synchronisation-Jump-Width, Time-Segement-1,
Time-Segment-2 ]
For more information about these values see the Softing user manual for this
board.
CAN 2 Acceptance — Defines the acceptance filters for CAN port 2. Because
the receive FIFO gets filled with any CAN messages going over the bus, the use
of the CAN controller acceptance filters becomes important in order to filter out
unwanted messages already at the controller level. This acceptance filter
5-25
5 CAN I/O Support for FIFO
information is provided by a row vector with 4 elements, where the first two are
used to define the acceptance mask and acceptance code for Standard
identifiers and the latter two for Extended identifiers. The default value
defined by the Setup block doesn’t filter out any messages. For information how
to define the acceptance information in order to filter certain messages, see See
“Acceptance Filters” on page 5-38.
Enable error frame detection — Defines if the CAN controller should detect
Error frames and forward these to the Receive FIFO. Checking this box makes
sense for monitoring applications where you want to be informed about all
events going over the bus. For low latency time applications, checking this box
may increase the FIFO Read driver block latency because the receive FIFO
gets filled with additional events.
Initialization (struct) and Termination (struct) — Define CAN messages
sent during initialization and termination of the Setup block. For more
information, see Chapter 4, “CAN I/O Support”.
I/O Base address — Defines the I/O base address of the board to be accessed
by this block instance. The I/O base address is given by the DIP-switch setting
on the board itself. The I/O address range is 3 bytes and is mainly used to
transfer the information which memory base address the board should use. See
the Softing user manual for this board on how the I/O base address can be set.
The I/O base address entered in this control has to correspond with the
DIP-switch setting on the board. If more than one board is present in the target
system a different I/O base address has to be entered for each board. In this
case the I/O base address itself defines which board is referenced by which
board number.
Memory base address — Defines the memory base address of the board to be
accessed by this block instance. The memory base address is a software setting
only (no corresponding DIP-switch is found on the board). The memory address
range is 64k bytes. If more than one board is present in the target system a
different memory base address has to be entered for each board and you have
to make sure that the defined address ranges do not overlap. Because the xPC
Target kernel only reserves a subset of the address range between 640k bytes
and 1M bytes for memory mapped devices the address ranges have to lie within
the following range:
C0000 – DC000
5-26
CAN FIFO Driver Blocks for the CAN-AC2-104 with Philips SJA1000 CAN-Controller
The board allows activating proper termination for each of the two CAN ports
separately by means of DIP-switches at the rear panel of the board. Refer to the
Softing user manual on how the DIP-switches have to be set. Both CAN ports
have to be terminated properly where you use the provided loop-back model in
order to test the board and drivers.
Port — The value can be either 1 (port 1) or 2 (port 2) and defines at which port
the CAN message will be sent out from.
Identifier — This is the identifier of the CAN message to be sent out. If it is a
Standard CAN message the valid range is 0 to 2047, if extended the range is 0
tp 229-1.
Identifier type — The value can be either 0 (Standard identifier range) or 1
(Extended identifier range) and defines the identifier type of the outgoing CAN
message.
Data frame size — The value can be in the range of 0 to 8 and defines the data
frame size in bytes of the outgoing CAN message
Data — This is the data for the data frame itself and is defined as a double
value (8 bytes). The CAN packing block is used to construct the data as a double
value.
Because all this information can be dynamically changed in FIFO mode during
application execution, the information is provided at the block input instead of
5-27
5 CAN I/O Support for FIFO
using the block parameters. In order to be able to transmit more than one CAN
message per block instance a matrix signal is used as a container for all
information.
The dimension of the matrix signal entering the block has to be n*5, where n is
the number of CAN messages to be sent out by this block instance. Therefore,
each row of the matrix signal defines one CAN message and each row combines
the 5 elements of information defined above (in this order).
For more information on how to construct the correct matrix signal for the
FIFO write block, see “Examples” on page 5-40.
For certain applications it may be necessary to make the writing of a CAN
message into the transmit FIFO dependent on the model dynamics. For this,
the matrix signal can also be of dimension n*6 instead of n*5. In this case, the
sixth column defines if the corresponding CAN message is written into the
transmit FIFO (value 1) or not (value 0).
The dialog box of the block lets you define the following settings.
Board — Defines which physically present board is used to send out the CAN
messages defined by this block instance. For more information about the
meaning of the board number see the Setup driver block described above. If just
one board is present in the target system, board number 1 should be selected.
Show status output port — Checking this box lets you enable the Status
output port. If the box is unchecked (disabled), the block does not have an
output port. If enabled, a port is shown. The signal leaving the block is a vector
of type double where the number of elements depends on the signal dimension
of the block input port. There is one element for each CAN message written into
the transmit FIFO and the value is identical to the return argument of function
5-28
CAN FIFO Driver Blocks for the CAN-AC2-104 with Philips SJA1000 CAN-Controller
Port — The value will be either 1 (port 1) or 2 (port 2) and reports at which port
the CAN message was received.
Identifier — This is the identifier of the CAN message being received. If it is
a Standard CAN message the range is 0 to 2047 If the CAN message is
extended, the range is 0 to 229-1.
5-29
5 CAN I/O Support for FIFO
Event type — This value defines the type of event read out of the receive FIFO.
The following values are defined from the Softing user manual:
16 No new event
17 Standard data frame received
18 Standard remote frame received
19 Transmission of a standard data frame is confirmed
20 -
21 Change of bus state
22 -
23 -
24 Transmission of a standard remote frame is confirmed
25 Extended data frame received
26 Transmission of an extended data frame is confirmed
27 Transmission of an extended remote frame is confirmed
28 Extended remote frame received
29 -
30 -
31 Error frame detected
Data frame size — If a data frame has been received the length of the data in
bytes is reported by this element. Possible values are 0 to 8.
Timestamp — This element reports the time at which the event was received.
The resolution of the timestamp counter is 1us.
Data — This is the data of the data frame itself and is returned as a double
value (8 bytes). The CAN unpacking block is used to extract the data out of the
double value.
5-30
CAN FIFO Driver Blocks for the CAN-AC2-104 with Philips SJA1000 CAN-Controller
The dialog box of the block lets you define the following settings.
Board — Defines which physically present board is used to send out the CAN
messages defined by this block instance. For more information about the
meaning of the board number see the Setup driver block described above. If just
one board is present in the target system, board number 1 should be selected.
FIFO read depth — Defines the number of receive FIFO read attempts. Each
time the block gets executed it reads this fixed amount of events (CAN
messages) which leads to a deterministic time behavior independent of the
number of events currently stored in the receive FIFO. The Read depth (m)
defines at the same time the size of the matrix signal (m*6) leaving the first
output port. If no event is currently stored in the receive FIFO, the FIFO will
be read anyway but the Event type will be reported as 0 (No new event).
Show status output port — Checking this box lets you enable the Status
output port. If the box is unchecked (disabled), the block has one output port
for the events. If enabled, a second port is shown. The signal leaving that port
is a vector of type double with two elements.
[Number of lost messages (events), Bus state]
The first element returns the current value of the lost messages counter. The
receive FIFO can store up to 255 events. If the receive FIFO is not regularly
accessed for reading events, the FIFO gets filled and the lost messages counter
starts to count up. This is an indicator that events (messages) will be
5-31
5 CAN I/O Support for FIFO
unavoidably lost. The second element returns the current bus state. Possible
values are:
3 Error active
4 Error passive
5 Bus off
Sample time — Defines the sample time at which the FIFO Read block is
executed during a model (target application) run.
It is strongly recommended that you only use one instance of this block per
physical CAN board in your model. Otherwise you may get the unwanted
behavior that one instance would read events while they have to be processed
by blocks connected to the other, second instance.
5-32
CAN FIFO Driver Blocks for the CAN-AC2-104 with Philips SJA1000 CAN-Controller
The dialog box of the block lets you define the following settings.
CAN port — Defines the filter criterion for the CAN port. Possible choices are:
Any, 1 or 2.
Message type command — Defines the filter criterion for the event types. This
entry can consist of a concatenation of space delimited keywords which are:
SDF Standard data frame
SRF Standard remote frame
EDF Extended data frame
ERF Extended remote frame
EF Error frame
NE No new event
CBS Change of bus state
Message type selection mode — Defines how the event type (message type)
entered in the control above is treated. If you select Include, the event type
criterion is the sum of the concatenated keywords. If you select Exclude, the
event type criterion is equal to all event types minus the sum of the
concatenated keywords.
Identifier(s) — Defines the filter criterion for the CAN message identifiers. A
set of identifiers can be provided as a row vector.
5-33
5 CAN I/O Support for FIFO
The dialog box of the block lets you define the following settings.
Board — Defines which physically present board is accessed to read the
current transmit FIFO level. For more information about the meaning of the
board number see the Setup driver block described above. If just one board is
present in the target system, board number 1 should be selected.
5-34
CAN FIFO Driver Blocks for the CAN-AC2-104 with Philips SJA1000 CAN-Controller
Sample time — Defines the sample time at which the FIFO Read XMT Level
driver block is executed during a model (target application) run.
The dialog box of the block lets you define the following settings.
Board — Defines which physically present board is accessed to reset the
transmit FIFO. For more information about the meaning of the board number
see the Setup driver block described above. If just one board is present in the
target system, board number 1 should be selected.
Sample time — Defines the sample time at which the FIFO Reset XMT driver
block is executed during a model (target application) run.
5-35
5 CAN I/O Support for FIFO
condition and take appropriate action, like stopping the execution or resetting
the receive FIFO.
The block has a single output port of type double returning a scalar value
containing the current receive FIFO level (number of messages to be
processed).
The dialog box of the block lets you define the following settings.
Board — Defines which physically present board is accessed to read the
current receive FIFO level. For more information about the meaning of the
board number see the Setup driver block described above. If just one board is
present in the target system, board number 1 should be selected.
Sample time — The second control (edit field) defines the sample time at which
the FIFO Read RCV Level driver block is executed during a model (target
application) run.
5-36
CAN FIFO Driver Blocks for the CAN-AC2-104 with Philips SJA1000 CAN-Controller
The dialog box of the block lets you define the following settings.
Board — The first control (popup menu) lets you define which physically
present board is accessed to reset the receive FIFO. For more information
about the meaning of the board number see the Setup driver block described
above. If just one board is present in the target system, board number 1 should
be selected.
Sample time — Defines the sample time at which the FIFO Reset RCV driver
block is executed during a model (target application) run.
5-37
5 CAN I/O Support for FIFO
Acceptance Filters
As mentioned earlier, the CAN controller’s acceptance filters can be used to
ensure that certain received messages referenced by their identifiers get
written into the receive FIFO. Therefore, fewer read attempts are necessary to
get at the messages which are of importance for the target application.
The behavior of the acceptance filter is described for standard and extended
identifier ranges individually (one for standard identifiers and one for
extended identifiers). Each acceptance filter is defined by a mask parameter
and a code parameter.
The mask parameter defines for each bit of the identifier, if the filtering process
cares about this bit or not. A 0 means “don’t care” and a 1 means “do care”.
The code parameter then defines for each bit of the identifier the filtering
process cares about (defined by the mask parameter), what the bit value has to
be (‘0’ or ‘1’).
For standard identifiers the mask parameter and code parameter have to be
both in the range 0 to 2047. For extended identifiers the mask parameter and
code parameter have to be both in the range 0 to 229-1.
The filtering process evaluates the following binary expression
and( xor( mask, identifier ), code )
If all bits of the resulting value are 0, the message with this identifier will be
accepted, if one single bit is 1 the message will be voided.
According to this description, acceptance filters work using binary evaluation
while most applications use the mental model of differentiating messages
(identifiers) in a decimal or hexadecimal manner. As a consequence, it is
possible to filter messages, which identifiers are above a certain decimal
number, while the opposite (identifiers below a certain decimal number) can
not be achieved in a general way.
Examples
The default values in the FIFO setup driver block are both 0 for the mask
parameter and the code parameter. These parameter values assure (the above
expression always evaluates to 0) that all incoming messages will reach the
receive FIFO (no filtering takes place). All parameter values have to be defined
5-38
Acceptance Filters
using decimal numbers. You can use the MATLAB function ‘hex2dec’ to also
define hexadecimal numbers in the dialog box entry.
Lets assume a CAN application where messages with the following identifiers
(standard) are crossing the CAN network:
2-30, 48-122 (decimal)
5-39
5 CAN I/O Support for FIFO
Examples
Example 1
Lets start with a simple model using the FIFO Setup block, FIFO Write block,
FIFO Read block, and FIFO Read Filter block. The entire CAN network
consists of a single physical connection between CAN port 1 and port 2
(loop-back configuration). For this, both CAN ports have to be terminated
properly.
The objective of the application is the following:
• Send a message with extended identifier 5100 and change data every
millisecond on port 1
• Send a message with standard identifier 112 and change data every even
millisecond on port 1
• Send a message with standard identifier 114 and change data every odd
millisecond on port 1
• Read 3 events every millisecond from the receive FIFO on port 2
• Display the incoming data of the 3 messages separately
• Acceptance filtering is not used (all messages are accepted)
The data transmitted with the CAN messages are double values in all the
following examples. This has been chosen for simplicity. You should refer to the
bit-packing and bit-unpacking chapter of the standard CAN driver
documentation, on how to construct from respectively extract into bit fields.
The first implementation uses the following scheme.
The matrix signal entering the FIFO Write block consists of all three messages
including the Control element (sixth element), therefore the matrix size will be
[3,6]. The sample time of the FIFO Write block is defined as 1 ms. For the
standard identifiers which have to be sent out every other millisecond, the
Control element is alternated accordingly. This is achieved by using a Unit
delay block with corresponding feedback as the Control element value.
The FIFO Read block has a Read depth of 3 and also a base sample of 1 ms.
Three FIFO filter blocks are connected to the output of the FIFO read block (in
parallel) to extract the information of the incoming CAN messages. You can
display the model by typing, in the MATLAB command window, either
xpccanpcififo1.mdl or xpccan104fifo1.mdl.
5-40
Examples
The model uses several xPC Target scope blocks to display different type of
data on the target screen:
• Scope 1 (numerical): displays the status vector leaving the FIFO Write block
• Scope 2 (numerical): displays the status vector [lost-message-counter, bus
state] leaving the FIFO Read block
• Scope 3 (graphical): plots the data of all three CAN messages being received
• Scopes 4-6 (numerical): display the other message relevant data of the three
incoming CAN messages individually (port, identifier, type, data length,
timestamp)
5-41
5 CAN I/O Support for FIFO
Example 2
When looking at the time behavior of the model, you can observe that at each
millisecond 2 CAN messages are sent out via the FIFO Write block, while the
FIFO Read block reads each millisecond 3 events out of the receive FIFO. This
implies that one of the three events leaving the FIFO Read block will be of type
"No new event”. This can be visually shown, by attaching another FIFO Filter
block in parallel, which filters “No new events”, and then by displaying the
second output port, which reports the number of matching events. You can
display the model by typing, in the MATLAB command window, either
xpccanpcififo2.mdl or xpccan104fifo2.mdl.
Having observed this, we could then reduce the Read depth of the FIFO Read
block from 3 to 2. This would not change anything of the overall behavior of the
5-42
Examples
model. As a positive side effect, the latency time of the FIFO Read block gets
smaller and therefore the model’s cycle time as well.
Example 3
We now look at a second implementation on the FIFO Write side. Instead of
providing three messages in parallel, we can just write 2 messages and then
alternate the identifier and data of the second CAN message to be sent.
Because the messages are now sent out every millisecond in any case, the
Control element has no longer to be provided, therefore reducing the matrix
entering the FIFO Write block to a size of [2,5]. You can display the model by
typing, in the MATLAB command window, either xpccanpcififo3.mdl or
xpccan104fifo3.mdl.
5-43
5 CAN I/O Support for FIFO
This implementation behaves exactly like the first implementation, but nicely
shows how CAN messages (to be sent out) can be constructed dynamically at
run-time.
Example 4
Now lets look at the situation where the Read depth parameter of the FIFO
Read block in the model above is set to 1 instead of 2 or 3. This leads to a receive
FIFO overflow when the execution time reaches 256 ms. Here, as an example,
the execution should be stopped, if the overflow occurs. This can be easily
achieved by evaluating the lost message counter value leaving the status
output port of the FIFO Read block. You can display the model by typing, in the
MATLAB command window, either xpccanpcififo4.mdl or xpccan104fifo4.mdl.
5-44
Examples
Example 5
Now lets consider a different handling of the receive FIFO overflow: If the
receive FIFO level reaches the value of 200, the receive FIFO should be reset
in order to delete all currently stored events. The application execution has to
continue normally. For this, two new driver blocks have to be added to the
model which are used to read the receive FIFO level and then reset it
accordingly. You can display the model by typing, in the MATLAB command
window, either xpccanpcififo5.mdl or xpccan104fifo5.mdl.
5-45
5 CAN I/O Support for FIFO
Example 6
The next example shows the use of the CAN acceptance filters. First the Read
depth parameter of the FIFO Read block is set back to a value of 2. Then the
identifier of the second standard message is changed from 114 to 188. The goal
is to filter any CAN messages with an identifier larger than 127 what would
mean that the receive FIFO would never contain the CAN message with
identifier 188. Additionally the FIFO Filter block, filtering CAN message with
identifier 114 is changed to filter the message with identifier 188.
For this the Acceptance Filters parameter of CAN port 2 in the FIFO Setup
block has to be set accordingly:
[2047-127, 0, 0, 0]
• Scope with Id 6 shows 0 for all elements of the vector leaving the
corresponding FIFO Filter block. The message with identifier 188 is never
received.
• Scope with Id 3 shows one of the data traces always being zero.
• Scope with Id 7 shows a value of 1 which reflects that the Read depth could
be reduced to 1, because only one message per millisecond reaches the
receive FIFO now.
You can display the model by typing, in the MATLAB command window, either
is xpccanpcififo6.mdl or xpccan104fifo6.mdl.
5-46
Examples
5-47
5 CAN I/O Support for FIFO
5-48
6
ADDI-DATA
6 ADDI-DATA
6-2
APCI-1710
APCI-1710
The APCI-1710 is a general purpose counting board with four function
modules.
xPC Target supports this board with one driver block:
• “APCI-1710 Incremental Encoder”
Board Characteristics
Manufacturer ADDI-DATA
6-3
6 ADDI-DATA
6-4
APCI-1710
Hystheresis - From the list choose either off or on. The Hystheresis
parameter specifies if a counter should skip a tick if the direction changes (see
the APC1-1700 manual).
Resolution - The Resolution field specifies the resolution of the connected
incremental encoder for one revolution.
Sampletime - Model base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in your target PC, enter
-1
If two or more boards of this type are physically present in your target PC,
enter the PCI slot number of the board associated with this driver block.
6-5
6 ADDI-DATA
PA-1700
The PA1700 is a counter board with three 24-bit counters for connecting three
incremental encoders.
xPC Target supports this board with one driver block:
• “PA-1700 Incremental Encoder”
Board Characteristics
Manufacturer ADDI-DATA
6-6
PA-1700
Hystheresis - From the list choose either off or on. The Hystheresis
parameter specifies if a counter should skip a tick if the direction changes (see
the PA1700 manual).
Resolution - The Resolution field specifies the resolution of the connected
incremental encoder for one revolution.
Sampletime - Model base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. It is important that this
entry corresponds to the DIP-switch settings on the board. For example, if the
base address is 300 (hexadecimal), enter
0x300
The following jumpers must be set according to the parameters entered above:
For information on how to electrically connect the encoders to the board, see
the PA1700-manual.
If you want to use the 5V power supply from the board (PIN20), you have to
insert Fuse 1 on the board. Refer to the PA1700-manual.
6-7
6 ADDI-DATA
6-8
7
Advantech
7 Advantech
“PCL-1800” x x x x ISA
“PCL-726” x x x ISA
“PCL-727” x x x ISA
“PCL-728” x ISA
“PCL-818” x x x x ISA
“PCL-818H” x x x x ISA
“PCL-818HD” x x x x ISA
“PCL-818HG” x x x x ISA
“PCL-818L” x x x x ISA
7-2
PCL-1800
PCL-1800
The PCL-1800 is an I/O board with 16 single or 8 differential analog channels
(12-bit) with a maximum sample rate of 330 kHz, 2 analog output D/A channels
(12-bit), and 16 digital input lines and 16 digital output lines.
xPC Target supports this board with four driver blocks:
Board Characteristics
Manufacturer Advantech
volts double 1
7-3
7 Advantech
Number the channels beginning with 1 even if the board manufacturer starts
to number the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
board allows the range of each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0 to +5 5
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 5 volts, enter
[-10,5]
The range settings have to correspond to the DIP-switch settings on the board.
MUX - From the list, choose either single-ended(16 channels) or
differential (8 channels). Your choice must correspond to the MUX-switch
setting on the board.
Sampletime - Base sample time or a multiple of the base sample time.
7-4
PCL-1800
BaseAddress - Enter the base address of the board. It is important that this
entry corresponds to the DIP-switch settings on the board. For example, if the
base address is 300 (hexadecimal), enter
0x300
volts double 1
Number the channels beginning with 1 even if the board manufacture starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
board allows the range of each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
0 to +10 10 0 to +5 5
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 5 volts, enter
[-10,5]
7-5
7 Advantech
The range settings have to correspond to the DIP-switch settings on the board.
Sampletime - Base sample time of a multiple of the base sample time.
BaseAddress - Enter the base address of the board. It is important that this
entry corresponds to the DIP-switch settings on the board. For example, if the
base address is 300 (hexadecimal), enter
0x300
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
7-6
PCL-1800
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
7-7
7 Advantech
PCL-726
The PCL-726 is an I/O board with, 6 independent analog output D/A channels
(12-bit), 16 digital input lines and 16 digital output lines.
xPC Target supports this board with three driver blocks:
• “PCL-726 Analog Output (D/A)”
• “PCL-726 Digital Input”
• “PCL-726 Digital Output”
Board Characteristics
Manufacturer Advantech
volts double 1
7-8
PCL-726
Number the channels beginning with 1 even if the board manufacture starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
board allows the range of each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
0 to +10 10 0 to +5 5
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 5 volts, enter
[-10,5]
The range settings have to correspond to the DIP-switch settings on the board.
Sampletime - Base sample time of a multiple of the base sample time.
BaseAddress - Enter the base address of the board. It is important that this
entry corresponds to the DIP-switch settings on the board. For example, if the
base address is 300 (hexadecimal), enter
0x300
7-9
7 Advantech
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
7-10
PCL-726
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
7-11
7 Advantech
PCL-727
The PCL-727 is an I/O board with, 12 independent analog output D/A channels
(12-bit), 16 digital input lines and 16 digital output lines.
xPC Target supports this board with three driver blocks:
• “PCL-727 Analog Output (D/A)”
• “PCL-727 Digital Input”
• “PCL-727 Digital Output”
Board Characteristics
Manufacturer Advantech
volts double 1
7-12
PCL-727
[1, 2]
Number the channels beginning with 1 even if the board manufacture starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
board allows the range of each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
0 to 10 10
-5 to +5 -5 0 to +5 5
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 5 volts, enter
[-10,5]
The range settings have to correspond to the DIP-switch settings on the board.
Sampletime - Base sample time of a multiple of the base sample time.
BaseAddress - Enter the base address of the board. It is important that this
entry corresponds to the DIP-switch settings on the board. For example, if the
base address is 300 (hexadecimal), enter
0x300
7-13
7 Advantech
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
7-14
PCL-727
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
7-15
7 Advantech
PCL-728
The PCL-728 is an I/O board with, 2 independent analog output D/A channels
(12-bit).
xPC Target supports this board with one driver block:
• “PCL-728 Analog Output (D/A)”
Board Characteristics
Manufacturer Advantech
volts double 1
7-16
PCL-728
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0 to +5 5
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 5 volts, enter
[-10,5]
The range settings have to correspond to the DIP-switch settings on the board.
Sampletime - Base sample time of a multiple of the base sample time.
BaseAddress - Enter the base address of the board. It is important that this
entry corresponds to the DIP-switch settings on the board. For example, if the
base address is 300 (hexadecimal), enter
0x300
7-17
7 Advantech
PCL-818
The PCL-818 is an I/O board with 16 single or 8 differential analog channels
(12-bit) with a maximum sample rate of 100 kHz, 2 analog output D/A channels
(12-bit), and 16 digital input lines and 16 digital output lines.
xPC Target supports this board with four driver blocks:
Board Characteristics
Manufacturer Advantech
volts double 1
7-18
PCL-818
enter numbers between 1 and 8. For example, to use the first and second analog
output (A/D) channels, enter
[1,2]
Number the channels beginning with 1 even if the board manufacture starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
board allows the range of each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0 to +5 5
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 5 volts, enter
[-10,5]
The range settings have to correspond to the DIP-switch settings on the board.
MUX - From the list, choose either single-ended(16 channels) or
differential (8 channels). Your choice must correspond to the MUX-switch
setting on the board.
Sampletime - Base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. It is important that this
entry corresponds to the DIP-switch settings on the board. For example, if the
base address is 300 (hexadecimal), enter
0x300
7-19
7 Advantech
volts double 1
Number the channels beginning with 1 even if the board manufacture starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
board allows the range of each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
-5 to +5 V -5 0 to +5 V 5
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 5 volts, enter
[-10,5]
The range settings have to correspond to the DIP-switch settings on the board.
Sampletime - Base sample time of a multiple of the base sample time.
7-20
PCL-818
BaseAddress - Enter the base address of the board. It is important that this
entry corresponds to the DIP-switch settings on the board. For example, if the
base address is 300 (hexadecimal), enter
0x300
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
7-21
7 Advantech
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
7-22
PCL-818H
PCL-818H
The PCL-818H is an I/O board with 16 single or 8 differential analog channels
(12-bit) with a maximum sample rate of 100 kHz, 1 analog output D/A channel
(12-bit), and 16 digital input lines and 16 digital output lines.
xPC Target supports this board with four driver blocks:
Board Characteristics
Manufacturer Advantech
volts double 1
7-23
7 Advantech
enter numbers between 1 and 8. For example, to use the first and second analog
output (A/D) channels, enter
[1,2]
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0 to +5 5
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 5 volts, enter
[-10,5]
The range settings have to correspond to the DIP-switch settings on the board.
MUX - From the list, choose either single-ended(16 channels) or
differential (8 channels). Your choice must correspond to the MUX-switch
setting on the board.
Sampletime - Base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. It is important that this
entry corresponds to the DIP-switch settings on the board. For example, if the
base address is 300 (hexadecimal), enter
0x300
7-24
PCL-818H
volts double 1
7-25
7 Advantech
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
7-26
PCL-818HD
PCL-818HD
The PCL-818HD is an I/O board with 16 single or 8 differential analog channels
(12-bit) with a maximum sample rate of 100 kHz, 1 analog output D/A channels
(12-bit), and 16 digital input lines and 16 digital output lines.
xPC Target supports this board with four driver blocks:
Board Characteristics
Manufacturer Advantech
volts double 1
7-27
7 Advantech
enter numbers between 1 and 8. For example, to use the first and second analog
output (A/D) channels, enter
[1,2]
Number the channels beginning with 1 even if the board manufacture starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
board allows the range of each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0 to +5 5
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 5 volts, enter
[-10,5]
The range settings have to correspond to the DIP-switch settings on the board.
MUX - From the list, choose either single-ended(16 channels) or
differential (8 channels). Your choice must correspond to the MUX-switch
setting on the board.
Sampletime - Base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. It is important that this
entry corresponds to the DIP-switch settings on the board. For example, if the
base address is 300 (hexadecimal), enter
0x300
7-28
PCL-818HD
volts double 1
7-29
7 Advantech
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
7-30
PCL-818HG
PCL-818HG
The PCL-818 is an I/O board with 16 single or 8 differential analog input
(A/D) channels (12-bit) with a maximum sample rate of 100 kHz, 1 analog
output (D/A) channel (12-bit), and 16 digital input lines and 16 digital output
lines.
xPC Target supports this board with four driver blocks:
Board Characteristics
Manufacturer Advantech
volts double 1
7-31
7 Advantech
Number the channels beginning with 1 even if the board manufacture starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
board allows the range of each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0 to +1 1
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 5 volts, enter
[-10,5]
The range settings have to correspond to the DIP-switch settings on the board.
MUX - From the list, choose either single-ended(16 channels) or
differential (8 channels). Your choice must correspond to the MUX-switch
setting on the board.
Sampletime - Base sample time or a multiple of the base sample time.
7-32
PCL-818HG
BaseAddress - Enter the base address of the board. It is important that this
entry corresponds to the DIP-switch settings on the board. For example, if the
base address is 300 (hexadecimal), enter
0x300
volts double 1
7-33
7 Advantech
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
7-34
PCL-818HG
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
7-35
7 Advantech
PCL-818L
The PCL-818L is an I/O board with 16 single or 8 differential analog input
(A/D) channels (12-bit) with a maximum sample rate or 40 kHz, 1 analog
output (D/A) channels (12-bit), 16 digital input lines, and 16 digital output
lines.
xPC Target supports this board with four driver blocks:
Board Characteristics
Manufacturer Advantech
volts double 1
7-36
PCL-818L
Number the channels beginning with 1 even if the board manufacture starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
board allows the range of each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5
For example, if the first channel is -10 to +10 volts, and the second channel is
-5 to 5 volts, enter
[-10,-5]
The range settings have to correspond to the DIP-switch settings on the board.
MUX - From the list, choose either single-ended(16 channels) or
differential (8 channels). Your choice must correspond to the MUX-switch
setting on the board.
Sampletime - Base sample time or a multiple of the base sample time.
7-37
7 Advantech
BaseAddress - Enter the base address of the board. It is important that this
entry corresponds to the DIP-switch settings on the board. For example, if the
base address is 300 (hexadecimal), enter
0x300
volts double 1
7-38
PCL-818L
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
7-39
7 Advantech
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
7-40
8
Burr-Brown
8 Burr-Brown
“PCI-20003M” x ISA
“PCI-20019M” x ISA
“PCI-20023M” x ISA
“PCI-20041C” x x ISA
“PCI-20098” x x x ISA
8-2
PCI-20003M
PCI-20003M
The PCI-20003M is an I/O board with 2 analog output (D/A) channels (12-bit).
xPC Target supports this board when it is installed on a PCI-20041C carrier
board with one driver block:
• “PCI-20003M Analog Output (D/A)”
Board Characteristics
Manufacturer Burr-Brown
volts double 1
8-3
8 Burr-Brown
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
0-5 5
For example, if the first channel is -10 to + 10 volts and the second channel is
0 to +5 volts, enter
[-10,5]
The jumpers W1 to W5, W13, W14, W27, W31, W7 to W11, W30, W32 on the
module must correspond to this range setting.
Sample Time - Enter the base sample time or a multiple of the base sample
time.
Module No - Enter a number from 1 to 3 to identify the connector on the
carrier board where the I/O module is inserted. This driver verifies if the
module is placed on the specified module connector.
BaseAddress or Carrier Board (ie: 0xd000) - Enter the base address of the
board. This entry must correspond to the DIP-switch settings on the board. For
example, if the base address is 300 (hexadecimal), enter
0x300
8-4
PCI-20019M
PCI-20019M
The PCI-20019M is an I/O board with 8 single analog input (A/D) channels
(12-bit).
xPC Target supports this board when it is installed on a PCI-20041C carrier
board with one driver block:
• “PCI-20019M Analog Input (A/D)”
Board Characteristics
Manufacturer Burr-Brown
volts double 1
8-5
8 Burr-Brown
Input Range - Enter an input range code for all A/D channels. This driver does
not allow the selection of a different range for individual channel. The input
range is the same for all A/D channels
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0-5 5
Other jumper on this board. The switch and jumper settings, that are not
mentioned here, have no influence on the running of xPC Target.
W8 in W27 out
8-6
PCI-20019M
W11 in W31 -
W12 out
8-7
8 Burr-Brown
PCI-20023M
The PCI-20023M is an I/O board with 8 single analog input (A/D) channels
(12-bit).
xPC Target supports this board when it is installed on a PCI-20041C carrier
board with one driver block:
• “PCI-20023M Analog Input (A/D)”
Board Characteristics
Manufacturer Burr-Brown
volts double 1
8-8
PCI-20023M
Input Range - Enter an input range code for all A/D channels. This driver does
not allow the selection of a different range for individual channel. The input
range is the same for all A/D channels.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5
The jumpers W1, W2, W4, W5, W33 on the module must correspond to this
range setting. The switch and jumper settings, that are not mentioned here,
have no influence on running xPC Target.
Sample Time - Enter the base sample time or a multiple of the base sample
time.
Module Number (1-3) - Enter a number from 1 to 3 to identify the connector
on the carrier board where the I/O module is inserted. This driver verifies if the
module is placed on the specified module connector.
BaseAddress of Carrier Board (ie. 0xd000) - Enter the base address of the
I/O board. It is important that this entry corresponds to the DIP-switch
settings on the board. For example, if the base address is 300 (hexadecimal),
enter
0x300
Other jumpers on this board. The switch and jumper settings, that are not
mentioned here, have no influence on the running of xPC Target.
W8 in W27 out
W9 - W30 -
8-9
8 Burr-Brown
W11 in
8-10
PCI-20041C
PCI-20041C
The PCI-20041C is a carrier board with 32 digital I/O-lines grouped into four
ports that can be configured as digital input or output. Each port has a
maximum of 8 digital lines.
xPC Target supports this board with two driver blocks:
Board Characteristics
Manufacturer Burr-Brown
8-11
8 Burr-Brown
Port Number (0-3) - Enter a number from 1 to 3 to identify the port used with
this block of digital input lines.
Sample Time - Enter a base sample time or a multiple of the base sample
time.
Module Number (1-3) - Enter a number from 1 to 3 to identify the connector
on the carrier board where the I/O module is inserted. This driver verifies if the
module is placed on the specified module connector.
BaseAddress or Carrier Board (ie: 0xd000) - Enter the base address of the
board. This entry must correspond to the DIP-switch settings on the board. For
example, if the base address is 300 (hexadecimal), enter
0x300
8-12
PCI-20041C
BaseAddress or Carrier Board (ie: 0xd000) - Enter the base address of the
board. This entry must correspond to the DIP-switch settings on the board. For
example, if the base address is 300 (hexadecimal), enter
0x300
8-13
8 Burr-Brown
PCI-20098
The PCI-20041C is a carrier board with 8 single or 16 differential analog input
(A/D) channels (12-bit), and 16 digital I/O-lines grouped into two 8-line ports.
xPC Target supports this board with 3 driver blocks:
Board Characteristics
Manufacturer Burr-Brown
volts double 1
8-14
PCI-20098
driver does not allow the selection of individual channels or a different MUX
setting for each channel.
Range - From the list, choose either +-10V (-10 to +10 volts), +-5V (-5 to +5
volts), or 0-10V.This driver does not allow the selection of a different range for
each channel. The input range is the same for all A/D channels
MUX (16/8) - From the list, choose either 16 single-ended or 8 differential.
This entry must correspond to the MUX-switch setting on the board.
Sample Time - Enter the base sample time or a multiple of the base sample
time.
BaseAddress or Carrier Board (ie: 0xd000) - Enter the base address of the
board. This entry must correspond to the DIP-switch settings on the board. For
example, if the base address is 300 (hexadecimal), enter
0x300
8-15
8 Burr-Brown
BaseAddress or Carrier Board (ie: 0xd000) - Enter the base address of the
board. This entry must corresponds to the DIP-switch settings on the board.
For example, if the base address is 300 (hexadecimal), enter
0x300
8-16
9
ComputerBoards
9 ComputerBoards
“CIO-DAC08/16” x ISA
“CIO-DAC16/16” x ISA
“CIO-DAS16/300” x - - ISA
“CIO-DAS16/JR (/ x - - ISA
12)”
x
ex
p
“CIO-DAS16JR/ x - - ISA
16”
“CIO-DAS1601/ x x x x ISA
12”
“CIO-DAS1602/ x x x x ISA
12”
9-2
Board Name A/ D/ DI DO Other Bus
D A N UT type
“CIO-DAS1602/ x x x x ISA
16”
“CIO-DDA06 (/ x x x ISA
12)”
“CIO-DDA06/16” x x x ISA
“CIO-DIO24H” x x ISA
“CIO-DIO48” x x ISA
“CIO-DIO48H” x x ISA
“CIO-DIO96” x x ISA
“CIO-DIO192” x x ISA
“CIO-DO24DD” x ISA
“CIO-PDISO16” x x ISA
“PC104-DAC06 (/ x ISA
12)” PC104
“PC104-DAS16JR/ x x x ISA
12” PC104
“PC104-DAS16JR/ x x x ISA
16” PC104
“PC104-DIO48” x x ISA
PC104
9-3
9 ComputerBoards
“PCI-DAS1200” x x x x PCI
“PCI-DAS1200/ x x x PCI
JR”
“PCI-DAS1602/12” x x x x PCI
“PCI-DAS1602/16” x x x x PCI
“PCI-DDA02/12” x x x PCI
“PCI-DDA04/12” x x x PCI
“PCI-DDA08/12” x x x PCI
“PCI-DIO24H” x x PCI
“PCI-DIO48” x x PCI
“PCI-DIO96H” x x PCI
9-4
CIO-CTR05
CIO-CTR05
The CIO-CTR05 is an I/O board with 5 counter/timer channels (16-bit).
It contains one AM9513A counter/timer chip. For additional information about
the various counter/timer modes of that chip see the AM9513A data sheet
which is part of the board documentation.
xPC Target supports this board with six driver blocks:
Board Characteristics
Manufacturer ComputerBoards
9-5
9 ComputerBoards
TTL double 0 to 1
9-6
CIO-CTR05
Sample Time - Enter the base sample time or a multiple of the base sample
time. The sample time indicates the update rate of registration on the input
(Duty Cycle)
BaseAddress -Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
9-7
9 ComputerBoards
Initial Duty Cycle - Enter a value between 0 and 1 to set the initial duty cycle.
The Duty Cycle defines the duty cycle at the initialization phase of the driver
similar to a initial value of an integrator.
Initial Toggle State - From the list, choose high or low. The Initial Toggle
State sets the initial digital level (high or low) of the output. For example, if
the Initial Duty Cycle is 0.25 and the Initial Toggle State is High, the first 25%
of the period will have a high level and the last 75% will have a low level.
Initial ARM State - From the list, choose Disarmed or Armed. The Initial
ARM State defines if the counter should be armed or disarmed after driver
initialization. The ARM State during a simulation can be controlled by the
second block input. If a value 0 is asserted, the counter is disarmed. If a value
1 is asserted, the counter gets armed.
Sample Time - Enter the base sample time or a multiple of the base sample
time. The sample time indicates the update rate of registration on the input
(Duty Cycle)
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
CIO-CTR05 Counter FM
The CIO-CTR05 has one AM9513A chip with 5 counters.
The CIO-CTR05 FM driver programs the AM9513A for FM (Frequency
Modulation) signal generation (a square wave with fixed duty cycle and
variable frequency).
TTL double 0 to 1
9-8
CIO-CTR05
9-9
9 ComputerBoards
9-10
CIO-CTR05
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
TTL double 0 to 1
9-11
9 ComputerBoards
CIO-CTR05 FM Capture
This block programs the AMD9513A for capturing FM signals.
There is one output for relative frequency compared to the base frequency. To
get the actual frequency, multiply the base frequency by the relative frequency.
TTL double 0 to 1
9-12
CIO-CTR10
CIO-CTR10
The CIO-CTR10 is an I/O board with 10 counter/timer channels (16-bit).
It contains one AM9513A counter/timer chip. For additional information about
the various counter/timer modes of that chip see the AM9513A data sheet
which is part of the board documentation.
xPC Target supports this board with six driver blocks:
Board Characteristics
Manufacturer ComputerBoards
9-13
9 ComputerBoards
TTL double 0 to 1
9-14
CIO-CTR10
Sample Time - Enter the base sample time or a multiple of the base sample
time. The sample time indicates the update rate of registration on the input
(Duty Cycle)
BaseAddress -Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
9-15
9 ComputerBoards
Initial Duty Cycle - Enter a value between 0 and 1 to set the initial duty cycle.
The Duty Cycle defines the duty cycle at the initialization phase of the driver
similar to a initial value of an integrator.
Initial Toggle State - From the list, choose high or low. The Initial Toggle
State sets the initial digital level (high or low) of the output. For example, if
the Initial Duty Cycle is 0.25 and the Initial Toggle State is High, the first 25%
of the period will have a high level and the last 75% will have a low level.
Initial ARM State - From the list, choose Disarmed or Armed. The Initial
ARM State defines if the counter should be armed or disarmed after driver
initialization. The ARM State during a simulation can be controlled by the
second block input. If a value 0 is asserted, the counter is disarmed. If a value
1 is asserted, the counter gets armed.
Sample Time - Enter the base sample time or a multiple of the base sample
time. The sample time indicates the update rate of registration on the input
(Duty Cycle)
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
CIO-CTR10 Counter FM
The CIO-CTR10 has two AM9513A chip with 10 counters.
The CIO-CTR05 FM driver programs the AM9513A for FM (Frequency
Modulation) signal generation (a square wave with fixed duty cycle and
variable frequency).
TTL double 0 to 1
9-16
CIO-CTR10
9-17
9 ComputerBoards
9-18
CIO-CTR10
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
TTL double 0 to 1
9-19
9 ComputerBoards
CIO-CTR10 FM Capture
This block programs the AMD9513A for capturing FM signals.
There is one output for relative frequency compared to the base frequency. To
get the actual frequency, multiply the base frequency by the relative frequency.
TTL double 0 to 1
9-20
CIO-DAC08 (/12)
CIO-DAC08 (/12)
The CIO-DAC08 (/12) is an I/O board with 8 analog output (D/A) channels
(12-bit).
xPC Target supports this board with one driver block:
• “CIO-DAC08 Analog Output (D/A)”
Board Characteristics
Manufacturer ComputerBoards
volts double 1
9-21
9 ComputerBoards
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Range code for each of the channels in the channel vector. The
range vector must have the same length as the channel vector. This board
allows the range of each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0-5 5
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 5 volts, enter
[-10,5]
The range settings have to correspond to the DIP-switch settings on the board.
Sampletime - Base sample time of a multiple of the base sample time.
BaseAddress - Enter the base address of the board. It is important that this
entry corresponds to the DIP-switch settings on the board. For example, if the
base address is 300 (hexadecimal), enter
0x300
9-22
CIO-DAC08/16
CIO-DAC08/16
The CIO-DAC08/16 is an I/O board with 8 analog output (D/A) channels
(16-bit).
xPC Target supports this board with one driver block:
• “CIO-DAC08/16 Analog Output (D/A)”
Board Characteristics
Manufacturer ComputerBoards
volts double 1
9-23
9 ComputerBoards
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Range code for each of the channels in the channel vector. The
range vector must be the same length as the channel vector. This driver allows
the range of each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0-5 5
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 5 volts, enter
[-10,5]
The range settings have to correspond to the DIP-switch settings on the board.
Sampletime - Base sample time of a multiple of the base sample time.
BaseAddress - Enter the base address of the board. It is important that this
entry corresponds to the DIP-switch settings on the board. For example, if the
base address is 300 (hexadecimal), enter
0x300
9-24
CIO-DAC16 (/12)
CIO-DAC16 (/12)
The CIO-DAC016 is an I/O board with 16 analog output (D/A) channels (12-bit).
xPC Target supports this board with one driver block:
• “CIO-DAC16 Analog Output (D/A)”
Board Characteristics
Manufacturer ComputerBoards
volts double 1
9-25
9 ComputerBoards
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
board allows the range of each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0-5 5
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 5 volts, enter
[-10,5]
The range settings have to correspond to the DIP-switch settings on the board.
Sampletime - Base sample time of a multiple of the base sample time.
BaseAddress - Enter the base address of the board. It is important that this
entry corresponds to the DIP-switch settings on the board. For example, if the
base address is 300 (hexadecimal), enter
0x300
The jumpers by the range DIP switches on the board all have to be in the XFER
position. The Wait-State jumper has to be in the off position.
9-26
CIO-DAC16/16
CIO-DAC16/16
The CIO-DAC16/16 is an I/O board with 16 analog output (D/A) channels
(16-bit).
xPC Target supports this board with one driver block:
• “CIO-DAC16/16 Analog Output (D/A)”
Board Characteristics
Manufacturer ComputerBoards
volts double 1
9-27
9 ComputerBoards
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
board allows the range of each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0-5 5
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 5 volts, enter
[-10,5]
The range settings have to correspond to the DIP-switch settings on the board.
Sampletime - Base sample time of a multiple of the base sample time.
BaseAddress - Enter the base address of the board. It is important that this
entry corresponds to the DIP-switch settings on the board. For example, if the
base address is 300 (hexadecimal), enter
0x300
The jumpers by the range DIP switches on the board all have to be in the XFER
position. The Wait-State jumper has to be in the off position.
9-28
CIO-DAS16/300
CIO-DAS16/300
The CIO-DAS16/330 is an I/O board with 16 single or 8 differential analog
input (A/D) channels (12-bit) with a maximum sample rate of 330 kHz, 4 digital
input lines, and 4 digital output lines.
xPC Target supports this board with one driver block:
• “CIO-DAS16/330 Analog Input (A/D)”
Note xPC Target does not support the digital I/O on this board.
Board Characteristics
Manufacturer ComputerBoards
9-29
9 ComputerBoards
volts double 1
9-30
CIO-DAS16/JR (/12)
CIO-DAS16/JR (/12)
The CIO-DAS16/JR is an I/O board with 16 single or 8 differential analog input
(A/D) channels (12-bit) with a maximum sample rate of 130 kHz, 4 digital input
lines, 4 digital output lines, and 3 counter/timers (16-bit). An external signal
conditioning board can be added to the CIO-DAS16/JR board.
xPC Target supports this board with two driver blocks:
Note xPC Target does not support the digital I/O or counters on this board.
Board Characteristics
Manufacturer ComputerBoards
9-31
9 ComputerBoards
volts double 1
9-32
CIO-DAS16/JR (/12)
volts double 1
• EXP16
• EXP32
• EXP-BRIDGE16
• EXP-RTD
• EXP-GP
9-33
9 ComputerBoards
If EXP Channel Vector is an empty vector EXP Gain Vector has to be an empty
vector as well.
A/D Board Channel - field specifies to which A/D-channel of the
CIO-DAS16Jr the block of 16 EXP-channels are mapped. Because the input
coupling of the A/D board has to be single-ended channel 0 to 16 can be used.
The channel selection jumpers on the EXP-boards have to be set accordingly to
this software setting.
A/D Board Range - field specifies the input voltage range for the CIO-DAS16/
JR which is the same for all 16 single-ended channels.
9-34
CIO-DAS16/JR (/12)
From the list, choose either +-10V (-10 volts to +10 volts), +-5V, +-2.5V,
+-1.25V, +-0.625V, 0-10V, 0-5V, 0-2.5V, or 0-1.25V.This driver does not allow
the selection of different range for each channel.
Sampletime - Enter the base sample time or a multiple of the base sample
time.
BaseAddress - Enter the base address of the board. It is important that this
entry corresponds to the DIP-switch settings on the board. For example, if the
base address is 300 (hexadecimal), enter
0x300
Important: If this driver is used the input coupling switch on the CIO-DAS16Jr
has always to be in the 16 (single-ended) position.
9-35
9 ComputerBoards
CIO-DAS16JR/16
The CIO-DAS16JR/16 is an I/O board with 16 single or 8 differential analog
input (A/D) channels (16-bit) with a maximum sample rate of 100 kHz, 4 digital
input lines, 4 digital output lines and 3 counter/timers.
xPC Target supports this board with one driver block:
• “CIO-DAS16JR/16 Analog Input (A/D)”
Note xPC Target does not support the digital I/O or the counters on this
board.
Board Characteristics
Manufacturer ComputerBoards
9-36
CIO-DAS16JR/16
volts double 1
9-37
9 ComputerBoards
CIO-DAS1601/12
The CIO-DAS1601/12 is an I/O board with 16 single or 8 differential analog
input (A/D) channels (12-bit) with a maximum sampling rate of 160 kHz, 2
analog output (D/A) channels (12-bit), 32 digital input and output lines, and 3
counters (16-bit).
xPC Target supports this board with four driver blocks:
Note xPC Target supports only 24 digital I/O lines and does not support the
counters on this board.
Manufacturer ComputerBoards
Multiple block instance support A/D: No, D/A: Yes, Digital I/O: Yes
9-38
CIO-DAS1601/12
volts double 1
9-39
9 ComputerBoards
volts double 1
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
board allows the range of each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0-5 5
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 5 volts, enter
[-10,5]
The range settings have to correspond to the DIP-switch settings on the board.
Also the Bipolar/ Unipolar jumpers have to be placed according to the ranges
used.
9-40
CIO-DAS1601/12
Number the lines beginning with 1 even if the board manufacturer starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The port name defines which port of the 8255 chip is used for this
driver block. Each port has a maximum of 8 digital lines that can be configured
as inputs or outputs depending on which driver block is chosen. In each case,
one block is needed for each port.
9-41
9 ComputerBoards
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
Number the lines beginning with 1 even if the board manufacturer starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The port name defines which port of the 8255 chip is used for this
driver block. Each port has a maximum or 8 digital lines that can be configured
as inputs or outputs depending on which driver block is chosen. In each case,
one block is needed for each port.
9-42
CIO-DAS1601/12
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
9-43
9 ComputerBoards
CIO-DAS1602/12
The CIO-DAS1602/12 is an I/O board with 16 single or 8 differential analog
input (A/D) channels (12-bit) with a maximum sampling rate of 100kHz, 2
analog output (D/A) channels (12-bit), 32 digital input and output lines, and 3
counters (16-bit).
xPC Target supports this board with four driver blocks:
Note xPC Target supports only 24 digital I/O lines and does not support the
counters on this board.
Manufacturer ComputerBoards
Multiple block instance support A/D: No, D/A: Yes, Digital I/O: Yes
9-44
CIO-DAS1602/12
volts double 1
9-45
9 ComputerBoards
volts double 1
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
board allows the range of each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0-5 5
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 5 volts, enter
[-10,5]
The range settings have to correspond to the DIP-switch settings on the board.
Also the Bipolar/ Unipolar jumpers have to be planted according to the ranges
used.
9-46
CIO-DAS1602/12
Number the lines beginning with 1 even if the board manufacturer starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The port name defines which port of the 8255 chip is used for this
driver block. Each port has a maximum or 8 digital lines that can be configured
as inputs or outputs depending on which driver block is chosen. In each case,
one block is needed for each port.
9-47
9 ComputerBoards
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
Number the lines beginning with 1 even if the board manufacturer starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The port name defines which port of the 8255 chip is used for this
driver block. Each port has a maximum or 8 digital lines that can be configured
as inputs or outputs depending on which driver block is chosen. In each case,
one block is needed for each port.
9-48
CIO-DAS1602/12
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
9-49
9 ComputerBoards
CIO-DAS1602/16
The CIO-DAS1602/16 is an I/O board with 16 single or 8 differential analog
input (A/D) channels (16-bit) with a maximum sampling rate of 100kHz, 2
analog output (D/A) channels (12-bit), 32 digital I/O lines, and 3 counters
916-bit).
xPC Target supports this board with four driver blocks:
Note xPC Target supports only 24 digital I/O lines and does not support the
counters on this board.
Manufacturer ComputerBoards
Multiple block instance support A/D: No, D/A: Yes, Digital I/O: Yes
9-50
CIO-DAS1602/16
volts double 1
9-51
9 ComputerBoards
volts double 1
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
board allows the range of each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0-5 5
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 5 volts, enter
[-10,5]
The range settings have to correspond to the DIP-switch settings on the board.
Also the Bipolar/ Unipolar jumpers have to be planted according to the ranges
used.
9-52
CIO-DAS1602/16
Number the lines beginning with 1 even if the board manufacturer starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The port name defines which port of the 8255 chip is used for this
driver block. Each port has a maximum or 8 digital lines that can be configured
9-53
9 ComputerBoards
Number the lines beginning with 1 even if the board manufacturer starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The port name defines which port of the 8255 chip is used for this
9-54
CIO-DAS1602/16
driver block. Each port has a maximum or 8 digital lines that can be configured
as inputs or outputs depending on which driver block is chosen. In each case,
one block is needed for each port.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
9-55
9 ComputerBoards
CIO-DDA06 (/12)
The CIO-DDA06 (/12) is an I/O board with 6 analog output (D/A) channels
(12-bit), and 24 digital I/O lines.
xPC Target supports this board with three driver blocks:
Board Characteristics
Manufacturer ComputerBoards
9-56
CIO-DDA06 (/12)
volts double 1
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
board allows the range of each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0 to +5 5
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 5 volts, enter
9-57
9 ComputerBoards
[-10,5]
The range settings have to correspond to the DIP-switch settings on the board.
The jumpers by the range DIP-switches on the board all have to be in the XFER
position. The Wait-State jumper has to be in the off position.
Sampletime - Base sample time of a multiple of the base sample time.
BaseAddress - Enter the base address of the board. It is important that this
entry corresponds to the DIP-switch settings on the board. For example, if the
base address is 300 (hexadecimal), enter
0x300
Number the lines beginning with 1 even if the board manufacturer starts
numbering the lines with 0.
9-58
CIO-DDA06 (/12)
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The port name defines which port of the 8255 chip is used for this
driver block. Each port has a maximum or 8 digital lines that can be configured
as inputs or outputs depending on which driver block is chosen. In each case,
one block is needed for each port.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
Number the lines beginning with 1 even if the board manufacturer starts
numbering the lines with 0.
9-59
9 ComputerBoards
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The port name defines which port of the 8255 chip is used for this
driver block. Each port has a maximum or 8 digital lines that can be configured
as inputs or outputs depending on which driver block is chosen. In each case,
one block is needed for each port.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
9-60
CIO-DDA06/16
CIO-DDA06/16
The CIO-DDA06/16) is an I/O board with 6 analog output (D/A) channels
(12-bit), and 24 digital I/O lines.
xPC Target supports this board with three driver blocks:
Board Characteristics
Manufacturer ComputerBoards
9-61
9 ComputerBoards
volts double 1
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
board allows the range of each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0 to +5 5
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 5 volts, enter
9-62
CIO-DDA06/16
[-10,5]
The range settings have to correspond to the DIP-switch settings on the board.
The jumpers by the range DIP-switches on the board all have to be in the XFER
position. The Wait-State jumper has to be in the off position.
Sampletime - Base sample time of a multiple of the base sample time.
BaseAddress - Enter the base address of the board. It is important that this
entry corresponds to the DIP-switch settings on the board. For example, if the
base address is 300 (hexadecimal), enter
0x300
Number the lines beginning with 1 even if the board manufacturer starts
numbering the lines with 0.
9-63
9 ComputerBoards
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The port name defines which port of the 8255 chip is used for this
driver block. Each port has a maximum or 8 digital lines that can be configured
as inputs or outputs depending on which driver block is chosen. In each case,
one block is needed for each port.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
9-64
CIO-DDA06/16
Number the lines beginning with 1 even if the board manufacturer starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The port name defines which port of the 8255 chip is used for this
driver block. Each port has a maximum or 8 digital lines that can be configured
as inputs or outputs depending on which driver block is chosen. In each case,
one block is needed for each port.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
9-65
9 ComputerBoards
CIO-DIO24
The CIO-DIO24 is an I/O board with 24 digital I/O lines.
xPC Target supports this board with three driver blocks:
Board Characteristics
Manufacturer ComputerBoards
9-66
CIO-DIO24
Number the lines beginning with 1 even if the board manufacturer starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
9-67
9 ComputerBoards
Number the lines beginning with 1 even if the board manufacturer starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
9-68
CIO-DIO24H
CIO-DIO24H
The CIO-DIO24H is an I/O board with 24 digital I/O lines.
xPC Target supports this board with two driver blocks:
Board Characteristics
Manufacturer ComputerBoards
9-69
9 ComputerBoards
Number the lines beginning with 1 even if the board manufacturer starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
9-70
CIO-DIO24H
Number the lines beginning with 1 even if the board manufacturer starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
9-71
9 ComputerBoards
CIO-DIO48
The CIO-DIO48 is an I/O board with 48 digital I/O lines.
xPC Target supports this board with two driver blocks:
Board Characteristics
Manufacturer ComputerBoards
9-72
CIO-DIO48
Channel Vector - Enter numbers between 1 and 8 to select the digital input
lines used with this port. This driver allows the selection of individual digital
input lines in any order. The number of elements defines the number of digital
lines used.
For example, to use all of the digital inputs for one port, enter
[1,2,3,4,5,6,7,8]
Number the lines beginning with 1 even if the board manufacturer starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has two 8255 chips
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Chip - From the list choose 1 or 2. The Chip parameter defines which of the
two 8255 chips is used.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
9-73
9 ComputerBoards
Number the lines beginning with 1 even if the board manufacturer starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has two 8255 chips
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Chip - From the list choose 1 or 2. The Chip parameter defines which of the
two 8255 chips is used.
Sampletime. Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
9-74
CIO-DIO48H
CIO-DIO48H
The CIO-DIO48H is an I/O board with 48 digital I/O lines.
xPC Target supports this board with two driver blocks:
Board Characteristics
Manufacturer ComputerBoards
9-75
9 ComputerBoards
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has two 8255 chips
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Chip - From the list choose 1 or 2. The Chip parameter defines which of the
two 8255 chips is used.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
9-76
CIO-DIO48H
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has two 8255 chips
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Chip - From the list choose 1 or 2. The Chip parameter defines which of the
two 8255 chips is used.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter 0x300
9-77
9 ComputerBoards
CIO-DIO96
The CIO-DIO96 is an I/O board with 96 digital I/O lines.
xPC Target supports this board with two driver blocks:
Board Characteristics
Manufacturer ComputerBoards
9-78
CIO-DIO96
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has two 8255 chips
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Chip - From the list choose 1, 2, 3, or 4. The Chip parameter defines which of
the four 8255 chips is used.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
9-79
9 ComputerBoards
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has two 8255 chips
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Chip - From the list choose 1, 2, 3, or 4. The Chip parameter defines which of
the four 8255 chips is used.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
9-80
CIO-DIO192
CIO-DIO192
The CIO- - DIO192 is an I/O board with 192 digital I/O lines.
xPC Target supports this board with two driver blocks:
Board Characteristics
Manufacturer ComputerBoards
9-81
9 ComputerBoards
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has two 8255 chips
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Chip - From the list choose 1, 2, 3, 4, 5, 6, 7, or 8. The Chip parameter defines
which of the eight 8255 chips is used.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
9-82
CIO-DIO192
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has two 8255 chips
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Chip - From the list choose 1, 2, 3, 4, 5, 6, 7, or 8. The Chip parameter defines
which of the eight 8255 chips is used.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
9-83
9 ComputerBoards
CIO-DO24DD
The CIO-DO24DD is an I/O board with 24 open-collector digital output lines.
xPC Target supports this board with one driver block:
• “CIO-DO24DD Digital Output”
Board Characteristics
Manufacturer ComputerBoards
9-84
CIO-DO24DD
output lines in any order. The number of elements defines the number of digital
lines used.
For example, to use all of the digital outputs for one port, enter
[1,2,3,4,5,6,7,8]
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
9-85
9 ComputerBoards
CIO-PDISO16
The CIO-PCISO16 is an I/O board with 16 isolated digital input lines and 16
relay driven digital output lines.
xPC Target supports this board with two driver blocks:
Note xPC Target does not support the 16 relays on this board.
Board Characteristics
Manufacturer ComputerBoards
9-86
CIO-PDISO16
9-87
9 ComputerBoards
9-88
CIO-QUAD02
CIO-QUAD02
The CIO-QUAD02 is a 24-bit counting board with 2 channels. This board
typically connects to incremental encoders. Incremental encoders convert
physical motion into electrical pulses than can be used to determine velocity,
direction, and distance.
xPC Target supports this board with one driver block:
• “CIO-QUAD02 Incremental Encoder”
Board Characteristics
Characteristic
Manufacturer ComputerBoards
9-89
9 ComputerBoards
9-90
CIO-QUAD02
9-91
9 ComputerBoards
CIO-QUAD04
Board Characteristics
Manufacturer ComputerBoards
9-92
CIO-QUAD04
9-93
9 ComputerBoards
9-94
PC104-DAC06 (/12)
PC104-DAC06 (/12)
The PC104-DAC06 (12) is an I/O board with 6 analog output (D/A) channels
(12-bit).
xPC Target supports this board with one driver block:
• “PC104-DAC06 (/12) Analog Output (D/A)”
Board Characteristics
volts double 1
9-95
9 ComputerBoards
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Range code for each of the channels in the channel vector. The
range vector must be the same length as the channel vector. This board allows
the range of each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0-5 5
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 5 volts, enter
[-10,5]
The range settings have to correspond to the jumper settings on the board.
Sampletime - Base sample time of a multiple of the base sample time.
BaseAddress - Enter the base address of the board. It is important that this
entry corresponds to the DIP-switch settings on the board. For example, if the
base address is 300 (hexadecimal), enter
0x300
The jumpers by the range DIP-switches on the board all have to be in the XFER
position. The Wait-State jumper has to be in the off position.
9-96
PC104-DAS16JR/12
PC104-DAS16JR/12
The PC104-DAS16JR/12 is an I/O board with 16 single or 8 differential analog
input channels (12-bit) with a maximum sample rate of 150 kHz, 4 digital input
lines and 4 digital output lines.
xPC Target supports this board with three driver blocks:
Manufacturer ComputerBoards
volts double 1
9-97
9 ComputerBoards
to select the number of A/D channels used. This driver does not allow the
selection of individual channels or to mix single-ended and differential inputs.
Number the channels beginning with 1 even if the board manufacturer starts
numbering channels with 0.
Range - From the list, choose either +-10V (-10 volts to +10 volts), +-5V,
+-2.5V, +-1.25V, +-0.625V, 0-10V, 0-5V, 0-2.5V, or 0-1.25V.This driver does
not allow the selection of a different range for each channel.
MUX - From the list, choose either single-ended(16 channels) or
differential (8 channels). Your choice must correspond to the MUX-switch
setting on the board.
Sampletime - Enter the base sample time or a multiple of the base sample
time.
BaseAddress - Enter the base address of the board. It is important that this
entry corresponds to the DIP-switch settings on the board. For example, if the
base address is 300 (hexadecimal), enter
0x300
9-98
PC104-DAS16JR/12
9-99
9 ComputerBoards
The switch and jumper settings, that are not mentioned here, have no influence
on the running of xPC Target.
9-100
PC104-DAS16JR/16
PC104-DAS16JR/16
The PC104-DAS16JR/16 is an I/O board with 16 single or 8 differential analog
input (A/D) channels (16-bit) with a maximum sample rate of 100 kHz, 4 digital
input lines and 4 digital output lines.
xPC Target supports this board with three driver blocks:
Manufacturer ComputerBoards
volts double 1
9-101
9 ComputerBoards
differential is chosen from the MUX list, then enter a number between 1 and 8
to select the number of A/D channels used. This driver does not allow the
selection of individual channels or to mix single-ended and differential inputs.
Number the channels beginning with 1 even if the board manufacturer starts
numbering channels with 0.
Range - From the list, choose either +-10V (-10 volts to +10 volts), +-5V,
+-2.5V, +-1.25V, +-0.625V, 0-10V, 0-5V, 0-2.5V, or 0-1.25V.This driver does
not allow the selection of different range for each channel.
MUX - From the list, choose either single-ended(16 channels) or
differential (8 channels). Your choice must correspond to the MUX-switch
setting on the board.
Sampletime - Enter the base sample time or a multiple of the base sample
time.
BaseAddress - Enter the base address of the board. It is important that this
entry corresponds to the DIP-switch settings on the board. For example, if the
base address is 300 (hexadecimal), enter
0x300
9-102
PC104-DAS16JR/16
9-103
9 ComputerBoards
9-104
PC104-DIO48
PC104-DIO48
The PC104-DIO48 is an I/O board with 48 digital I/O lines.
xPC Target supports this board with two driver blocks:
• “PC104-DIO48 Digital Input”
• “PC104-DIO48 Digital Output”
Manufacturer ComputerBoards
9-105
9 ComputerBoards
Number the lines beginning with 1 even if the board manufacturer starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has two 8255 chips
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Chip - From the list choose 1 or 2. The Chip parameter defines which of the
two 8255 chips is used.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
9-106
PC104-DIO48
Number the lines beginning with 1 even if the board manufacturer starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has two 8255 chips
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Chip - From the list choose 1 or 2. The Chip parameter defines which of the
two 8255 chips is used.
Sampletime. Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
9-107
9 ComputerBoards
PCI-CTR05
The CIO-CTR05 is an I/O board with 5 counter/timer channels (16-bit).
It contains one AM9513A counter/timer chip. For additional information about
the various counter/timer modes of that chip see the AM9513A data sheet
which is part of the board documentation.
xPC Target supports this board with six driver blocks:
Board Characteristics
Manufacturer ComputerBoards
9-108
PCI-CTR05
TTL double 0 to 1
9-109
9 ComputerBoards
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
9-110
PCI-CTR05
Initial Duty Cycle - Enter a value between 0 and 1 to set the initial duty cycle.
The Duty Cycle defines the duty cycle at the initialization phase of the driver
similar to a initial value of an integrator.
Initial Toggle State - From the list, choose high or low. The Initial Toggle
State sets the initial digital level (high or low) of the output. For example, if
the Initial Duty Cycle is 0.25 and the Initial Toggle State is High, the first 25%
of the period will have a high level and the last 75% will have a low level.
Initial ARM State - From the list, choose Disarmed or Armed. The Initial
ARM State defines if the counter should be armed or disarmed after driver
initialization. The ARM State during a simulation can be controlled by the
second block input. If a value 0 is asserted, the counter is disarmed. If a value
1 is asserted, the counter gets armed.
Sample Time - Enter the base sample time or a multiple of the base sample
time. The sample time indicates the update rate of registration on the input
(Duty Cycle)
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
PCI-CTR05 Counter FM
The PCI-CTR05 has one AM9513A chip with 5 counters.
The PCI-CTR05 FM driver programs the AM9513A for FM (Frequency
Modulation) signal generation (a square wave with fixed duty cycle and
variable frequency).
TTL double 0 to 1
9-111
9 ComputerBoards
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
9-112
PCI-CTR05
9-113
9 ComputerBoards
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
TTL double 0 to 1
9-114
PCI-CTR05
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
PCI-CTR05 FM Capture
This block programs the AMD9513A for capturing FM signals.
There is one output for relative frequency compared to the base frequency. To
get the actual frequency, multiply the base frequency by the relative frequency.
TTL double 0 to 1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
9-115
9 ComputerBoards
PCI-DAS1200
The PCI-DAS1200 is an I/O board with 16 single or 8 differential analog input
(A/D) channels (12-bit) with a maximum sample rate of 330 kHz, 2 analog
output (D/A) channels (12-bit), and 24 digital input and output lines.
xPC Target supports this board with four driver blocks:
Board Characteristics
Manufacturer ComputerBoards
Multiple block instance support A/D: No, D/A: Yes, Digital I/O: Yes
volts double 1
9-116
PCI-DAS1200
differential is chosen from the MUX list, then enter a number between 1 and 8
to select the number of A/D channels used. This driver does not allow the
selection of individual channels or to mix single-ended and differential inputs.
Number the channels beginning with 1 even if the board manufacturer starts
numbering channels with 0.
Range - From the list, choose either +-10V (-10 volts to +10 volts), +-5V,
+-2.5V, +-1.25V, 0-10V, 0-5V, 0-2.5V, or 0-1.25V.This driver does not allow the
selection of different range for each channel.
MUX - From the list, choose either single-ended(16 channels) or
differential (8 channels). Your choice must correspond to the MUX-switch
setting on the board.
Sampletime - Enter the base sample time or a multiple of the base sample
time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
volts double 1
9-117
9 ComputerBoards
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
board allows the range of each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0-5 5
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 5 volts, enter
[-10,5]
The range settings have to correspond to the DIP-switch settings on the board.
Also the Bipolar/ Unipolar jumpers have to be placed according to the ranges
used.
Sampletime - Base sample time of a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
9-118
PCI-DAS1200
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
9-119
9 ComputerBoards
Use a separate diver block for each port. By selecting the digital output driver
block, the port is configured as output.
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
9-120
PCI-DAS1200/JR
PCI-DAS1200/JR
The PCI-DAS1200/JR is an I/O board with 16 single or 8 differential analog
input (A/D) channels (12-bit) with a maximum sample rate of 330 kHz, and 24
digital I/O lines.
xPC Target supports this board with three driver blocks:
Board Characteristics
Manufacturer ComputerBoards
volts double 1
9-121
9 ComputerBoards
to select the number of A/D channels used. This driver does not allow the
selection of individual channels or to mix single-ended and differential inputs.
Number the channels beginning with 1 even if the board manufacturer starts
numbering channels with 0.
Range - From the list, choose either +-10V (-10 volts to +10 volts), +-5V,
+-2.5V, +-1.25V, 0-10V, 0-5V, 0-2.5V, or 0-1.25V.This driver does not allow the
selection of different range for each channel.
MUX - From the list, choose either single-ended(16 channels) or
differential (8 channels). Your choice must correspond to the MUX-switch
setting on the board.
Sampletime - Enter the base sample time or a multiple of the base sample
time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
9-122
PCI-DAS1200/JR
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
9-123
9 ComputerBoards
Use a separate diver block for each port. By selecting the digital output driver
block, the port is configured as output.
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
9-124
PCI-DAS1602/12
PCI-DAS1602/12
Note xPC Target supports only 24 digital I/O lines and does not support the
counters on this board.
Characteristic
Manufacturer ComputerBoards
9-125
9 ComputerBoards
volts double 1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
9-126
PCI-DAS1602/12
volts double 1
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0-5 5
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 5 volts, enter
[-10,5]
The range settings have to correspond to the DIP-switch settings on the board.
Also the Bipolar/ Unipolar jumpers have to be planted according to the ranges
used.
9-127
9 ComputerBoards
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The port name defines which port of the 8255 chip is used for this
driver block. Each port has a maximum or 8 digital lines that can be configured
9-128
PCI-DAS1602/12
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
9-129
9 ComputerBoards
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The port name defines which port of the 8255 chip is used for this
driver block. Each port has a maximum or 8 digital lines that can be configured
as inputs or outputs depending on which driver block is chosen. In each case,
one block is needed for each port.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
9-130
PCI-DAS1602/16
PCI-DAS1602/16
The PCI-DAS1602/16 is an I/O board with 16 single or 8 differential analog
input (A/D) channels (16-bit) with a maximum sampling rate of 200kHz, 2
analog output (D/A) channels (16-bit), and 24 digital input and output lines and
3 counters (16-bit).
xPC Target supports this board with four driver blocks:
Note xPC Target supports only 24 digital I/O lines and does not support the
counters on this board.
Characteristic
Manufacturer ComputerBoards
9-131
9 ComputerBoards
volts double 1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
9-132
PCI-DAS1602/16
volts double 1
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0-5 5
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 5 volts, enter
[-10,5]
The range settings have to correspond to the DIP-switch settings on the board.
Also the Bipolar/ Unipolar jumpers have to be planted according to the ranges
used.
9-133
9 ComputerBoards
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The port name defines which port of the 8255 chip is used for this
9-134
PCI-DAS1602/16
driver block. Each port has a maximum or 8 digital lines that can be configured
as inputs or outputs depending on which driver block is chosen. In each case,
one block is needed for each port.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch). Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
9-135
9 ComputerBoards
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The port name defines which port of the 8255 chip is used for this
driver block. Each port has a maximum or 8 digital lines that can be configured
as inputs or outputs depending on which driver block is chosen. In each case,
one block is needed for each port.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
9-136
PCI-DDA02/12
PCI-DDA02/12
The PCI-DDA02/12) is an I/O board with 2 analog output (D/A) channels
(12-bit), and 48 digital I/O lines.
xPC Target supports this board with three driver blocks:
Board Characteristics
volts double 1
9-137
9 ComputerBoards
[1,2]
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
board allows the range of each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0 - +5 5
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 5 volts, enter
[-10,5]
The range settings have to correspond to the DIP-switch settings on the board.
Also the Bipolar/ Unipolar jumpers have to be placed according to the ranges
used.
Sampletime - Base sample time of a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
9-138
PCI-DDA02/12
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has two 8255 chips
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Chip - From the list choose 1 or 2. The Chip parameter defines which of the
two 8255 chips is used.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
9-139
9 ComputerBoards
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has two 8255 chips
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Chip - From the list choose 1 or 2. The Chip parameter defines which of the
two 8255 chips is used.
9-140
PCI-DDA02/12
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
9-141
9 ComputerBoards
PCI-DDA04/12
The PCI-DDA04/12) is an I/O board with 4 analog output (D/A) channels
(12-bit), and 48 digital I/O lines.
xPC Target supports this board with three driver blocks:
Board Characteristics
volts double 1
9-142
PCI-DDA04/12
[1,2]
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
board allows the range of each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0 - +5 5
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 5 volts, enter
[-10,5]
The range settings have to correspond to the DIP-switch settings on the board.
Also the Bipolar/ Unipolar jumpers have to be placed according to the ranges
used.
Sampletime - Base sample time of a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
9-143
9 ComputerBoards
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has two 8255 chips
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Chip - From the list choose 1 or 2. The Chip parameter defines which of the
two 8255 chips is used.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
9-144
PCI-DDA04/12
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has two 8255 chips
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum of 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Chip - From the list choose 1 or 2. The Chip parameter defines which of the
two 8255 chips is used.
9-145
9 ComputerBoards
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
9-146
PCI-DDA08/12
PCI-DDA08/12
The PCI-DDA08/12) is an I/O board with 8 analog output (A/D) channels
(12-bit), and 48 digital I/O lines.
xPC Target supports this board with three driver blocks:
Board Characteristics
Manufacturer ComputerBoards
volts double 1
9-147
9 ComputerBoards
[1,2]
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
board allows the range of each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0 - +5 5
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 5 volts, enter
[-10,5]
The range settings have to correspond to the DIP-switch settings on the board.
Also the Bipolar/ Unipolar jumpers have to be placed according to the ranges
used.
Sampletime - Base sample time of a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
9-148
PCI-DDA08/12
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has two 8255 chips
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Chip - From the list choose 1 or 2. The Chip parameter defines which of the
two 8255 chips is used.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
9-149
9 ComputerBoards
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has two 8255 chips
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Chip - From the list choose 1 or 2. The Chip parameter defines which of the
two 8255 chips is used.
9-150
PCI-DDA08/12
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
9-151
9 ComputerBoards
PCI-DIO24
The PCI-DIO24 is an I/O board with 24 digital I/O lines.
xPC Target supports this board with three driver blocks:
Board Characteristics
Manufacturer ComputerBoards
9-152
PCI-DIO24
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
9-153
9 ComputerBoards
Use a separate diver block for each port. By selecting the digital output driver
block, the port is configured as output.
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
9-154
PCI-DIO24
9-155
9 ComputerBoards
PCI-DIO24H
The PCI-DIO24H is an I/O board with 24 digital I/O lines.
xPC Target supports this board with two driver blocks:
Board Characteristics
Manufacturer ComputerBoards
9-156
PCI-DIO24H
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
9-157
9 ComputerBoards
Use a separate diver block for each port. By selecting the digital output driver
block, the port is configured as output.
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
9-158
PCI-DIO48
PCI-DIO48
The PCI-DIO48 is an I/O board with 48 digital I/O lines.
xPC Target supports this board with two driver blocks:
Board Characteristics
Manufacturer ComputerBoards
9-159
9 ComputerBoards
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has two 8255 chips
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Chip - From the list choose 1 or 2. The Chip parameter defines which of the
two 8255 chips is used.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
9-160
PCI-DIO48
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has two 8255 chips
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Chip - From the list choose 1 or 2. The Chip parameter defines which of the
two 8255 chips is used.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
9-161
9 ComputerBoards
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
9-162
PCI-DIO96H
PCI-DIO96H
The PCI-DIO96 is an I/O board with 96 digital I/O lines.
xPC Target supports this board with two driver blocks:
Board Characteristics
Manufacturer ComputerBoards
9-163
9 ComputerBoards
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has two 8255 chips
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Chip - From the list choose 1, 2, 3, or 4. The Chip parameter defines which of
the four 8255 chips is used.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
9-164
PCI-DIO96H
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has two 8255 chips
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Chip - From the list choose 1, 2, 3, or 4. The Chip parameter defines which of
the four 8255 chips is used.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
9-165
9 ComputerBoards
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
9-166
PCI-QUAD04
PCI-QUAD04
Board Characteristics
Manufacturer ComputerBoards
9-167
9 ComputerBoards
9-168
PCI-QUAD04
9-169
9 ComputerBoards
9-170
10
Diamond
10 Diamond
“Diamond-MM” x x x x ISA
PC104
“Diamond-MM-32” x x x x PC104
“Quartz-MM 5” x x counter FM
counter FM&ARM
counter PWM
counterPWM&AR
PWM capture
Frequency capture
10-2
Diamond-MM
Diamond-MM
The Diamond-MM is a DAS16 compatible I/O board with 16 single or 8
differential analog input (A/D) channels (12-bit) with a maximum sample rate
or 100 kHz, 2 analog output (D/A) channels (12-bit), 8 digital input lines, and 8
digital output lines.
xPC Target supports this board with four driver blocks:
Board Characteristics
10-3
10 Diamond
volts double 1
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0 to +5 5
-1 to +1 -1 0 to +1 1
-0.5 to +0.5 -5
The gain jumpers on the board have to be in the correct positions for the chosen
range.The bipolar jumper on the board has to be in the bipolar position, if a
bipolar range is used or in the unipolar position, when a unipolar range is used.
MUX (16/8) - Enter 16 for single-ended or 8 for differential A/D channels. This
entry must correspond to the MUX-switch setting on the board.
10-4
Diamond-MM
Sample Time - Enter the base sample time or a multiple of the base sample
time.
BaseAddress - Enter the base address of the board. This entry must
correspond to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
volts double 1
Input range (V) Range code Input range (V) Range code
0 to +10 10
0 to +5 5
For example, if the first channel is 0 to + 10 volts and the second channel is 0
to +5 volts, enter
[10,5]
10-5
10 Diamond
Sample Time - Enter the base sample time or a multiple of the base sample
time.
BaseAddress - Enter the base address of the board. This entry must
correspond to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
10-6
Diamond-MM
10-7
10 Diamond
Diamond-MM-32
The Diamond MM-32 is a PC104 I/O board with 32 single or 16 differential
analog input (A/D) channels (16-bit) with a maximum sample rate or 200 kHz,
4 analog output (D/A) channels (12-bit), 24 digital input and output lines.
xPC Target supports this board with four driver blocks:
Board Characteristics
10-8
Diamond-MM-32
volts double 1
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0 to +5 5
-0.625 to -5
+0.625
10-9
10 Diamond
volts double 1
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0
Range — From the list, choose a range code. This driver does not allows a
different range for each or the 4 channels. This selection has to correspond to
the range and bipolar/unipolar jumper settings on the board.
10-10
Diamond-MM-32
The following table is a list of the ranges for this driver and the corresponding
range codes. The D/A specific jumpers on the board have to be in the correct
positions for the ranges entered.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0 to +5 5
For example, if the first channel is 0 to + 10 volts and the second channel is 0
to +5 volts, enter
[10,5]
Sample Time - Enter the base sample time or a multiple of the base sample
time.
BaseAddress - Enter the base address of the board. This entry must
correspond to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
10-11
10 Diamond
Number the lines beginning with 1 even if the board manufacturer starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
10-12
Diamond-MM-32
Number the lines beginning with 1 even if the board manufacturer starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
10-13
10 Diamond
Quartz-MM 5
The Quartz-MM 10 has 8 digital input lines, 8 digital output lines, and 10
counter/timers.
xPC Target supports this board with eight driver blocks:
• “Quartz-MM 5 Digital Input”
• “Quartz-MM 5 Digital Output”
• “Quartz-MM5 Counter PWM”
• “Quartz-MM5 counter PWM & ARM”
• “Quartz-MM5 Counter FM”
• “Quartz-MM5 Counter FM & ARM”
• “Quartz-MM5 PWM Capture”
• “Quartz-MM5 FM Capture”
Board Characteristics
10-14
Quartz-MM 5
10-15
10 Diamond
0x300
10-16
Quartz-MM 5
TTL double 0 to 1
10-17
10 Diamond
Sample Time - Enter the base sample time or a multiple of the base sample
time. The sample time indicates the update rate of registration on the input
(Duty Cycle)
BaseAddress -Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
10-18
Quartz-MM 5
Initial Duty Cycle - Enter a value between 0 and 1 to set the initial duty cycle.
The Duty Cycle defines the duty cycle at the initialization phase of the driver
similar to a initial value of an integrator.
Initial Toggle State - From the list, choose high or low. The Initial Toggle
State sets the initial digital level (high or low) of the output. For example, if
the Initial Duty Cycle is 0.25 and the Initial Toggle State is High, the first 25%
of the period will have a high level and the last 75% will have a low level.
Initial ARM State - From the list, choose Disarmed or Armed. The Initial
ARM State defines if the counter should be armed or disarmed after driver
initialization. The ARM State during a simulation can be controlled by the
second block input. If a value 0 is asserted, the counter is disarmed. If a value
1 is asserted, the counter gets armed.
Sample Time - Enter the base sample time or a multiple of the base sample
time. The sample time indicates the update rate of registration on the input
(Duty Cycle)
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
Quartz-MM5 Counter FM
The Quartz-MM5 has one AM9513A chip with 5 counters.
The Quartz-MM5 FM driver programs the AM9513A for FM (Frequency
Modulation) signal generation (a square wave with fixed duty cycle and
variable frequency).
TTL double 0 to 1
10-19
10 Diamond
10-20
Quartz-MM 5
10-21
10 Diamond
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
TTL double 0 to 1
10-22
Quartz-MM 5
Quartz-MM5 FM Capture
This block programs the AMD9513A for capturing FM signals.
There is one output for relative frequency compared to the base frequency. To
get the actual frequency, multiply the base frequency by the relative frequency.
TTL double 0 to 1
10-23
10 Diamond
Quartz-MM 10
The Quartz-MM 10 has 8 digital input line, 8 digital output lines, and 10
counter/timers.
xPC Target supports this board with three driver blocks:
• “Quartz-MM 10 Digital Input”
• “Quartz-MM 10 Digital Output”
• “Quartz-MM 10 Counter PWM”
• “Quartz-MM 10 Counter PWM & ARM”
• “Quartz-MM 10 Counter FM”
• “Quartz-MM 10 Counter FM & ARM”
• “Quartz-MM 10 PWM Capture”
• “Quartz-MM 10 FM Capture”
Board Characteristics
10-24
Quartz-MM 10
10-25
10 Diamond
0x300
10-26
Quartz-MM 10
TTL double 0 to 1
10-27
10 Diamond
Sample Time - Enter the base sample time or a multiple of the base sample
time. The sample time indicates the update rate of registration on the input
(Duty Cycle)
BaseAddress -Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
10-28
Quartz-MM 10
Initial Duty Cycle - Enter a value between 0 and 1 to set the initial duty cycle.
The Duty Cycle defines the duty cycle at the initialization phase of the driver
similar to a initial value of an integrator.
Initial Toggle State - From the list, choose high or low. The Initial Toggle
State sets the initial digital level (high or low) of the output. For example, if
the Initial Duty Cycle is 0.25 and the Initial Toggle State is High, the first 25%
of the period will have a high level and the last 75% will have a low level.
Initial ARM State - From the list, choose Disarmed or Armed. The Initial
ARM State defines if the counter should be armed or disarmed after driver
initialization. The ARM State during a simulation can be controlled by the
second block input. If a value 0 is asserted, the counter is disarmed. If a value
1 is asserted, the counter gets armed.
Sample Time - Enter the base sample time or a multiple of the base sample
time. The sample time indicates the update rate of registration on the input
(Duty Cycle)
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
Quartz-MM 10 Counter FM
The Quartz-MM10 has one AM9513A chip with 5 counters.
The Quartz-MM10 FM driver programs the AM9513A for FM (Frequency
Modulation) signal generation (a square wave with fixed duty cycle and
variable frequency).
TTL double 0 to 1
10-29
10 Diamond
10-30
Quartz-MM 10
10-31
10 Diamond
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
TTL double 0 to 1
10-32
Quartz-MM 10
Quartz-MM 10 FM Capture
This block programs the AMD9513A for capturing FM signals.
There is one output for relative frequency compared to the base frequency. To
get the actual frequency, multiply the base frequency by the relative frequency.
TTL double 0 to 1
10-33
10 Diamond
10-34
11
Gespac
11 Gespac
“GESADA-1” x x ISA
Indust
ry
“GESPIA-2A” x x ISA
Indust
ry
11-2
GESADA-1
GESADA-1
The GEADA-1 is an industrial I/O board with 16 single or 8 differential analog
input (A/D) channels, and 4 analog output (D/A) channels (10-bit).
xPC Target supports this board with two driver blocks:
Note xPC Target does not support the external trigger and interrupt
propagation on this board.
Board Characteristics
Manufacturer Gespas
volts double 1
11-3
11 Gespac
volts double 1
11-4
GESADA-1
Enter a range code for each of the channels used. This driver allows a different
range for each D/A channel with a maximum of 2 channels.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5
For example, if the first channel is -10 to + 10 volts and the second, third and
fourth channel are -5 to +5 volts, enter
[-10,5,5,5]
The range settings have to correspond to the jumper setting of J5 on the board.
Sample Time - Enter the base sample time or a multiple of the base sample
time.
BaseAddress - Enter the base address of the board. This entry must
correspond to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
The base address specifies the base address of the board and has to correspond
to the Jumper setting (J12) on the board.
11-5
11 Gespac
GESPIA-2A
The GESPIA-2A is an industrial I/O board with 32 digital I/O lines. The
GESPIA-2A has two 6821 PIAs (0 and 1) from Motorola. Each PIA has two
ports (A and B) with 8 digital lints which can be defined as input or output.
xPC Target supports this board with two driver blocks:
Board Characteristics
Manufacturer Gespac
11-6
GESPIA-2A
11-7
11 Gespac
11-8
12
Humusoft
12 Humusoft
12-2
AD 512
AD 512
The AD 512 is an I/O board with 8 single analog input (A/D) channels (12-bit)
with a maximum sample rate of 100 kHz, 2 analog output (D/A) channels
(12-bit), 8 digital inputs, and 8 digital outputs.
xPC Target supports this board with four driver blocks:
• “AD 512 Analog Input (A/D)”
• “AD 512 Analog Output (D/A)”
• “AD 512 Digital Input”
• “AD 512 Digital Output”
Board Characteristics
Manufacturer Humusoft
12-3
12 Humusoft
volts double 1
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels entered in the
channel vector. The range vector must be the same length as the channel
vector. This driver allows a different range for each channel.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0-5 5
For example, if the first channel is -10 to + 10 volts and the second and fifth
channels are 0 to +1 volts, enter
[-10,1,1]
Sample Time - Model base sample time or a multiple of the base sample time.
12-4
AD 512
BaseAddress - Enter the base address of the board. This entry must
correspond to the jumper settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
volts double 1
Input range (V) Range code Input range (V) Range code
-5 to + 5 -5 0-5 5
For example, if the first channel is -10 to + 10 volts and the second channel is
0 to +5 volts, enter
[-10,5]
Sample Time - Enter the base sample time or a multiple of the base sample
time.
12-5
12 Humusoft
BaseAddress - Enter the base address of the board. This entry must
correspond to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
Channel Vector - Enter a numbers between 1 and 8. This driver allows the
selection of individual digital line numbers in any order. The number of
elements defines the number of digital input lines used.
For example, to use the first, second and fifth digital input lines, enter
[1,2,5]
Number the lines beginning with 1, even if the board manufacturer starts
numbering the lines with 0.
Sample Time - Enter the base sample time or a multiple of the base sample
time.
BaseAddress - Enter the base address of the board. This entry must
correspond to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
12-6
AD 512
Channel Vector - Enter a numbers between 1 and 8. This driver allows the
selection of individual digital line numbers in any order. The number of
elements defines the number of digital output lines used.
For example, to use the first, second and fifth digital output lines, enter
[1,2,5]
Number the lines beginning with 1, even if the board manufacturer starts
numbering the lines with 0.
Sample Time - Enter the base sample time or a multiple of the base sample
time.
BaseAddress - Enter the base address of the board. This entry must
correspond to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
12-7
12 Humusoft
12-8
13
Keithley Metrabyte
13 Keithley Metrabyte
“DAS-1800HR” x x x ISA
“KCPI-1801HC”
“KPCI-1802HC”
13-2
DAS-1800HR
DAS-1800HR
The DAS-1800HR is an I/O board with 16 single or 8 differential analog input
(A/D) channels (16-bit) with a maximum sample rate of 100 kHz, 4 digital input
lines and 4 digital output lines.
xPC Target supports this board with three driver blocks:
Board Characteristics
Manufacturer Keithley
13-3
13 Keithley Metrabyte
volts double 1
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Gain Vector (1,2,4,8) - Enter 1, 2, 4, or 8 for each of the channels in the
channel vector to choose the gain code of that channel. The gain vector must be
the same length as the channel vector. This driver allows the gain of each
channel to be different.
Notice that by increasing the gain code the voltage range is decreased. The gain
divides the input voltage range.
For example, if the first channel has a gain code of 1 (10 volt range) and the
second and fifth channels have a gain code of 2 (5 volt range), enter
[1,2,2]
13-4
DAS-1800HR
The following table is a list of the ranges for this driver given the gain entered
and the range chosen.
1 -10 to +10 0 to 10
2 -5 to + 5 0 to +5
13-5
13 Keithley Metrabyte
Sample Time - Enter a base sample time or a multiple of the base sample
time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
13-6
KCPI-1801HC
KCPI-1801HC
The KCPI-1801 is an I/O board with 64 single or 32 differential analog input
(A/D) channels (12-bit) with a maximum sample rate of 333 kHz, 2 analog
output (D/A) channels (12-bit), and 4 digital input and output lines.
xPC Target supports this board with four driver blocks:
xPC Target does not support does not support the counter/timers on this board.
Board Characteristics
13-7
13 Keithley Metrabyte
volts double 1
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
driver allows each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0 to 5 5
-1 to +1 -1 0 to 1 1
For example, if the first channel is -5 to + 5 volts and the second and fifth
channels are 0 to +1 volts, enter
[-5,1,1]
13-8
KCPI-1801HC
Coupling Vector - Enter a coupling code for each of the channels in the
channel vector. The coupling vector must be the same length as the channel
vector. This driver allows a different coupling for each channel.
The following table is a list of the couplings for this driver and the
corresponding coupling codes.
For example, if the first and second channels are single input and the fifth
channel is a differential input, enter
[0,0,1]
The driver selects a second differential input 32 channels higher than the first
channel. In the example above, the driver would select the 37th channel as a
differential input with the fifth channel.
Sampletime - Model base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in your target PC, enter
-1
If two or more boards of this type are physically present in your target PC,
enter the PCI slot number of the board associated with this driver block.
13-9
13 Keithley Metrabyte
volts double 1
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Sampletime - Base sample time of a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
13-10
KCPI-1801HC
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
13-11
13 Keithley Metrabyte
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
13-12
KPCI-1802HC
KPCI-1802HC
The KCPI-1801 is an I/O board with 64 single or 32 differential analog input
(A/D) channels (12-bit) with a maximum sample rate of 333 kHz, 2 analog
output (D/A) channels (12-bit), and 4 digital input and output lines.
xPC Target supports this board with four driver blocks:
xPC Target does not support does not support the counter/timers on this board.
Board Characteristics
13-13
13 Keithley Metrabyte
volts double 1
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
driver allows each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0 to 5 5
For example, if the first channel is -10 to + 10 volts and the second and fifth
channels are 0 to +1 volts, enter
[-10,1,1]
13-14
KPCI-1802HC
Coupling Vector - Enter a coupling code for each of the channels in the
channel vector. The coupling vector must be the same length as the channel
vector. This driver allows a different coupling for each channel.
The following table is a list of the couplings for this driver and the
corresponding coupling codes.
For example, if the first and second channels are single input and the fifth
channel is a differential input, enter
[0,0,1]
The driver selects a second differential input 32 channels higher than the first
channel. In the example above, the driver would select the 37th channel as a
differential input with the fifth channel.
Sampletime - Model base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in your target PC, enter
-1
If two or more boards of this type are physically present in your target PC,
enter the PCI slot number of the board associated with this driver block.
13-15
13 Keithley Metrabyte
volts double 1
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Sampletime - Base sample time of a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
13-16
KPCI-1802HC
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
13-17
13 Keithley Metrabyte
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
13-18
14
National Instruments
14 National Instruments
“AT-AO-6” x
“AT-AO-10” x
“PC-DIO-24” x x PCI
“PCI-6023E” x x x PCI
“PCI-6024E” x x x x PCI
“PCI-6025E” x x x x PCI
“PCI-6031E” x x x x PCI
“PCI-6052E” x x x x PCI
“PCI-6071E” x x x x PCI
“PCI-6503” x x PCI
“PCI-6508” compa
ct PCI
“PCI-DIO-96” x x PCI
“PCI-MIO-16E-1” x x x x PCI
“PCI-MIO-16E-4” x x x x PCI
“PCI-MIO-16XE-1 x x x x PCI
0”
14-2
Board Name A/ D/ DI DO Other Bus
D A N UT type
“PXI-6040E” x x x x compa
ct PCI
“PXI-6070E” x x x x compa
ct PCI
“PXI-6508” x x compa
ct PCI
14-3
14 National Instruments
AT-AO-6
The AT-AO-6 is an I/O board with 6 analog output (D/A) channels (12-bit), and
16 digital I/O lines.
xPC Target supports this board with three driver blocks:
Board Characteristics
volts double 1
14-4
AT-AO-6
[1,2]
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
board allows the range of each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 10volts, enter
[-10,10]
The range settings have to correspond to the jumper settings on the board.
Sampletime - Base sample time of a multiple of the base sample time.
BaseAddress - Enter the base address of the board. It is important that this
entry corresponds to the DIP-switch settings on the board. For example, if the
base address is 300 (hexadecimal), enter
0x300
14-5
14 National Instruments
Number the lines beginning with 1 even if the board manufacturer starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
14-6
AT-AO-6
Number the lines beginning with 1 even if the board manufacturer starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
14-7
14 National Instruments
AT-AO-10
The AT-AO-10 is an I/O board with 10 analog output (D/A) channels (12-bit),
and 16 digital I/O lines.
xPC Target supports this board with three driver blocks:
Board Characteristics
volts double 1
14-8
AT-AO-10
[1,2]
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
board allows the range of each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 10volts, enter
[-10,10]
The range settings have to correspond to the jumper settings on the board.
Sampletime - Base sample time of a multiple of the base sample time.
BaseAddress - Enter the base address of the board. It is important that this
entry corresponds to the DIP-switch settings on the board. For example, if the
base address is 300 (hexadecimal), enter
0x300
14-9
14 National Instruments
Number the lines beginning with 1 even if the board manufacturer starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
14-10
AT-AO-10
Number the lines beginning with 1 even if the board manufacturer starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
14-11
14 National Instruments
GPIB-232CT-A
The GPIB-232CT-A is GPIB controller external to the target PC. It is connected
to the target PC with an RS232 cable.
xPC Target supports this board with two driver blocks:
• “GPIB-232CT-A Setup”
• “GPIB-232CT-A Send/Receive”
Board Characteristics
GPIB-232CT-A Setup
The setup block parameters must be set to match the jumper seatings on the
GPIB-232CT-A.
14-12
GPIB-232CT-A
GPIB-232CT-A Send/Receive
Driver Block Parameters
Port - From the list, choose COM1, COM2, COM3, or COM4. Serial connection
on the target PC to send and receive data
Message StructName - Enter the struct name that contains the messages to
be sent to the GPIB control and format information to receive data.
Sample Time - Enter a base sample time or a multiple of the base sample time.
14-13
14 National Instruments
PC-DIO-24
The PC-DIO-24 is an I/O board with 24 digital input and output lines.
xPC Target supports this board with two driver blocks:
Board Characteristics
14-14
PC-DIO-24
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
14-15
14 National Instruments
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
14-16
PC-TIO-10
PC-TIO-10
The PC-TIO-10 is an I/O board with 16 digital input and output lines, and 10
counter/timer channels (16-bit).
xPC Target supports this board with six driver blocks:
Board Characteristics
14-17
14 National Instruments
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either PIA A, or PCA B. The I/O board has a
MC6821 chip with 2 ports. The Port parameter defines which port of the
MC6821 chip is used for this driver block. Each port has a maximum or 8
digital lines that can be configured as inputs or outputs depending on which
driver block is chosen. In each case, one block is needed for each port.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
14-18
PC-TIO-10
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either PIA A, or PCA B. The I/O board has a
MC6821 chip with 2 ports. The Port parameter defines which port of the
MC6821 chip is used for this driver block. Each port has a maximum or 8
digital lines that can be configured as inputs or outputs depending on which
driver block is chosen. In each case, one block is needed for each port.
Sampletime - Enter the base sample time or a multiple of the base sample
time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
14-19
14 National Instruments
TTL double 0 to 1
14-20
PC-TIO-10
Sample Time - Enter the base sample time or a multiple of the base sample
time. The sample time indicates the update rate of registration on the input
(Duty Cycle)
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
14-21
14 National Instruments
Initial Duty Cycle - Enter a value between 0 and 1 to set the initial duty cycle.
The Duty Cycle defines the duty cycle at the initialization phase of the driver
similar to a initial value of an integrator.
Initial Toggle State - From the list, choose high or low. The Initial Toggle
State sets the digital level (high or low) of the output. For example, if the
Initial Duty Cycle is 0.25 and the Initial Toggle State is High, the first 25% of
the period will have a high-level and the last 75% will have a low-level.
Initial ARM State - From the list, choose Disarmed or Armed. The Initial
ARM State defines if the counter should be armed or disarmed after driver
initialization. The ARM State during a simulation can be controlled by the
second block input. If a value 0 is asserted, the counter is disarmed. If a value
1 is asserted, the counter gets armed.
Sample Time - Enter the base sample time or a multiple of the base sample
time. The sample time indicates the update rate of registration on the input
(Duty Cycle)
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
PC-TIO-10 Counter FM
The PC-TIO-10 has two AM9513A chips each with 5 counters for a total of 10
counters on the board.
The PC-TIO-10 FM driver programs the AM9513A for FM (Frequency
Modulation) signal generation (a square wave with fixed duty cycle and
variable frequency).
14-22
PC-TIO-10
TTL double 0 to 1
14-23
14 National Instruments
14-24
PC-TIO-10
Initial ARM State - From the list, choose Disarmed or Armed. The Initial
ARM State defines if the counter should be armed or disarmed after driver
initialization. The ARM State during a simulation can be controlled by the
second block input. If a value 0 is asserted, the counter is disarmed. If a value
1 is asserted, the counter gets armed.
Sample Time - Enter the base sample time or a multiple of the base sample
time. The sample time indicates the update rate of registration on the input
(Duty Cycle)
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
PC-TIO10 FM Capture
14-25
14 National Instruments
PCI-6023E
The PCI-6023E is an I/O board with 16 single or 8 differential analog input
(A/D) channels (12-bit) with a maximum sample rate of 200 kHz, 8 digital I/O
lines, and 2 counter/timers (24-bit)
xPC Target supports this board with three driver blocks:
Board Characteristics
14-26
PCI-6023E
volts double 1
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
driver allows each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
For example, if the first channel is -10 to + 10 volts and the second and fifth
channels are 0 to +1 volts, enter
[-10,1,1]
Coupling Vector - Enter a coupling code for each of the channels in the
channel vector. The coupling vector must be the same length as the channel
vector. This driver allows a different coupling for each channel.
14-27
14 National Instruments
The following table is a list of the couplings for this driver and the
corresponding coupling codes.
For example, if the first and second channels are single input and the fifth
channel is a differential input, enter
[0,0,2]
The driver selects a second differential input 8 channels higher than the first
channel. In the example above, the driver would select the thirteenth channel
as a differential input with the fifth channel.
Sampletime - Model base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in your target PC, enter
-1
If two or more boards of this type are physically present in your target PC,
enter the PCI slot number of the board associated with this driver block.
14-28
PCI-6023E
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n. If only one
board of this type is physically present in the target PC, enter
-1
14-29
14 National Instruments
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
14-30
PCI-6024E
PCI-6024E
The PCI-6024E is an I/O board with 16 single or 8 differential analog input
(A/D) channels (12-bit) with a maximum sample rate of 200 kHz, 2 analog
output (D/A) channels (12-bit), 8 digital input and output lines, and 2 counter/
timers (24-bit).
xPC Target supports this board with four driver blocks:
xPC Target does not support does not support the counter/timers on this board.
Board Characteristics
Multiple block instance support A/D: No, D/A: No, Digital I/O: Yes
14-31
14 National Instruments
volts double 1
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
driver allows each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
For example, if the first channel is -10 to + 10 volts and the second and fifth
channels are 0 to +1 volts, enter
[-10,1,1]
Coupling Vector - Enter a coupling code for each of the channels in the
channel vector. The coupling vector must be the same length as the channel
vector. This driver allows a different coupling for each channel.
14-32
PCI-6024E
The following table is a list of the couplings for this driver and the
corresponding coupling codes.
For example, if the first and second channels are single input and the fifth
channel is a differential input, enter
[0,0,2]
The driver selects a second differential input 8 channels higher than the first
channel. In the example above, the driver would select the thirteenth channel
as a differential input with the fifth channel.
Sampletime - Model base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in your target PC, enter
-1
If two or more boards of this type are physically present in your target PC,
enter the PCI slot number of the board associated with this driver block.
14-33
14 National Instruments
volts double 1
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Sampletime - Base sample time of a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
14-34
PCI-6024E
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
14-35
14 National Instruments
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
14-36
PCI-6025E
PCI-6025E
The PCI-6025E is an I/O board with 16 single or 8 differential analog inputs
(A/D) channels (12-bit) with a maximum sample rate of 200 kHz, 2 analog
output channels (12-bit), 32 digital input and output lines, and 2 counter/
timers (24-bit).
xPC Target supports this board with four driver blocks:
• “PCI-6025E Analog Input (A/D)”
• “PCI-6025E Analog Output (D/A)”
• “PCI-6025E Digital Input”
• “PCI-6025E Digital Output”
Note xPC Target does not support the counter/timers on this board.
Board Characteristics
Multiple block instance support A/D: No, D/A: No, Digital I/O: Yes
14-37
14 National Instruments
volts double 1
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
driver allows each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
For example, if the first channel is -10 to + 10 volts and the second and fifth
channels are 0 to +1 volts, enter
[-10,1,1]
Coupling Vector - Enter a coupling code for each of the channels in the
channel vector. The coupling vector must be the same length as the channel
vector. This driver allows a different coupling for each channel.
14-38
PCI-6025E
The following table is a list of the couplings for this driver and the
corresponding coupling codes.
For example, if the first and second channels are single input and the fifth
channel is a differential input, enter
[0,0,2]
The driver selects a second differential input 8 channels higher than the first
channel. In the example above, the driver would select the thirteenth channel
as a differential input with the fifth channel.
Sampletime - Model base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in your target PC, enter
-1
If two or more boards of this type are physically present in your target PC,
enter the PCI slot number of the board associated with this driver block.
14-39
14 National Instruments
volts double 1
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Sampletime - Base sample time of a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
14-40
PCI-6025E
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
14-41
14 National Instruments
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
14-42
PCI-6031E
PCI-6031E
The PCI-6031E is an I/O board with 64 single or 32 differential analog input
(A/D) channels (16-bit) with a maximum sample rate of 100 kHz, 2 analog
output (D/A) channels (16-bit), 8 digital input and output lines, and 2 counter/
timers (24-bit).
xPC Target supports this board with four driver blocks:
Note xPC Target does not support does not support the counter/timers on
this board.
Board Characteristics
Multiple block instance support A/D: No, D/A: No, Digital I/O: Yes
14-43
14 National Instruments
volts double 1
Number the channels beginning with 1, even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
driver allows each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0-5 5
-2 to +2 -2 0-2 2
-1 to + 1 -1 0-1 1
For example, if the first channel is -10 to + 10 volts and the second and fifth
channels are 0 to +1 volts, enter
14-44
PCI-6031E
[-10,1,1]
Coupling Vector - Enter a coupling code for each of the channels in the
channel vector. The coupling vector must be the same length as the channel
vector. This driver allows a different coupling for each channel.
The following table is a list of the couplings for this driver and the
corresponding coupling codes.
For example, if the first and second channels are single input and the fifth
channel is a differential input, enter
[0,0,2]
The driver selects a second differential input 8 channels higher than the first
channel. In the example above, the driver would select the thirteenth channel
as a differential input with the fifth channel.
Sampletime - Model base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in your target PC, enter
-1
14-45
14 National Instruments
If two or more boards of this type are physically present in your target PC,
enter the PCI slot number of the board associated with this driver block.
volts double 1
Number the channels begin with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
board allows the range of each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 10volts, enter
[-10,10]
14-46
PCI-6031E
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
14-47
14 National Instruments
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
14-48
PCI-6052E
PCI-6052E
Note xPC Target does not support does not support the counter/timers on
this board.
Board Characteristics
Multiple block instance support A/D: No, D/A: No, Digital I/O: Yes
14-49
14 National Instruments
volts double 1
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
driver allows each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0-5 5
-2 to +2 -2 0-2 2
-1 to + 1 -1 0-1 1
14-50
PCI-6052E
For example, if the first channel is -10 to + 10 volts and the second and fifth
channels are 0 to +1 volts, enter
[-10,1,1]
Coupling Vector - Enter a coupling code for each of the channels in the
channel vector. The coupling vector must be the same length as the channel
vector. This driver allows a different coupling for each channel.
The following table is a list of the couplings for this driver and the
corresponding coupling codes.
For example, if the first and second channels are single input and the fifth
channel is a differential input, enter
[0,0,2]
The driver selects a second differential input 8 channels higher than the first
channel. In the example above, the driver would select the thirteenth channel
as a differential input with the fifth channel.
Sampletime - Model base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
14-51
14 National Instruments
If only one board of this type is physically present in your target PC, enter
-1
If two or more boards of this type are physically present in your target PC,
enter the PCI slot number of the board associated with this driver block.
volts double 1
Number the channels begin with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
board allows the range of each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 5 volts, enter
[-10,5]
14-52
PCI-6052E
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
14-53
14 National Instruments
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
14-54
PCI-6071E
PCI-6071E
The PCI-6071E is an I/O board with 64 single or 8 differential analog input
(A/D) channels (12-bit) with a maximum sample rate of 1.25 MHz, 2 analog
output (D/A) channels (12-bit), 8 digital input and output lines, and 2 counter/
timers (24-bit).
xPC Target supports this board with four driver blocks:
xPC Target does not support does not support the counter/timers on this board.
Board Characteristics
Multiple block instance support A/D: No, D/A: No, Digital I/O: Yes
14-55
14 National Instruments
volts double 1
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
driver allows each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0 to +5 5
-2 to +2 -2 0 to +2 2
-1 to + 1 -1 0 to +1 1
14-56
PCI-6071E
Input range (V) Range code Input range (V) Range code
For example, if the first channel is -10 to + 10 volts and the second and fifth
channels are 0 to +1 volts, enter
[-10,1,1]
Coupling Vector - Enter a coupling code for each of the channels in the
channel vector. The coupling vector must be the same length as the channel
vector. This driver allows a different coupling for each channel.
The following table is a list of the couplings for this driver and the
corresponding coupling codes.
For example, if the first and second channels are single input and the fifth
channel is a differential input, enter
[0,0,2]
14-57
14 National Instruments
The driver selects a second differential input 8 channels higher than the first
channel. In the example above, the driver would select the thirteenth channel
as a differential input with the fifth channel.
Sampletime - Model base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in your target PC, enter
-1
If two or more boards of this type are physically present in your target PC,
enter the PCI slot number of the board associated with this driver block.
volts double 1
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
board allows the range of each channel to be different.
14-58
PCI-6071E
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 5 volts, enter
[-10,5]
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
14-59
14 National Instruments
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
14-60
PCI-6503
PCI-6503
The PCI-6503 is an I/O board with 24 digital input and output lines.
xPC Target supports this board with two driver blocks:
Board Characteristics
14-61
14 National Instruments
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
14-62
PCI-6503
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Sampletime - Enter a base sample time or a multiple of the base sample time.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
14-63
14 National Instruments
PCI-6508
14-64
PCI-DIO-96
PCI-DIO-96
The PC-DIO-96 is an I/O board with 96 digital input and output lines.
xPC Target supports this board with two driver blocks:
Board Characteristics
14-65
14 National Instruments
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has four 8255 chips
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Chip - From the list choose 1, 2, 3, or 4.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
14-66
PCI-DIO-96
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Chip - From the list choose 1, 2, 3, or 4.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
14-67
14 National Instruments
PCI-MIO-16E-1
The PCI-MIO-16E-1 is an I/O board with 16 single or 8 differential analog
input channels (12-bit) with a maximum sample rate of 1.25 MHz, 2analog
output channels (12-bit), 8 digital input and output lines, and 2 counter/timers
(24-bit).
xPC Target supports this board with four driver blocks:
xPC Target does not support does not support the counter/timers on this board.
Board Characteristics
Multiple block instance support A/D: No, D/A: No, Digital I/O: Yes
volts double 1
14-68
PCI-MIO-16E-1
Channel Vector - Enter numbers between 1 and 16. This driver allows you to
enter channel numbers in any order.
For example, to use the first, second and fifth channels, enter
[1,2,5]
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
driver allows each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0-5 5
-2 to +2 -2 0-2 2
-1 to + 1 -1 0-1 1
For example, if the first channel is -10 to + 10 volts and the second and fifth
channels are 0 to +1 volts, enter
[-10,1,1]
Coupling Vector - Enter a coupling code for each of the channels in the
channel vector. The coupling vector must be the same length as the channel
vector. This driver allows a different coupling for each channel.
14-69
14 National Instruments
The following table is a list of the couplings for this driver and the
corresponding coupling codes.
For example, if the first and second channels are single input and the fifth
channel is a differential input, enter
[0,0,2]
The driver selects a second differential input 8 channels higher than the first
channel. In the example above, the driver would select the thirteenth channel
as a differential input with the fifth channel.
Sampletime - Model base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in your target PC, enter
-1
If two or more boards of this type are physically present in your target PC,
enter the PCI slot number of the board associated with this driver block.
14-70
PCI-MIO-16E-1
volts double 1
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
board allows the range of each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 5 volts, enter
[-10,5]
14-71
14 National Instruments
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
14-72
PCI-MIO-16E-1
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
14-73
14 National Instruments
PCI-MIO-16E-4
The PCI-MIO-16E-4 is an I/O board with 16 single or 8 differential analog
input channels (12-bit) with a maximum sample rate of 500 kHz, 2 analog
output channels (12-bit), 8 digital input and output lines, and 2 counter/timers
(24-bit).
xPC Target supports this board with four driver blocks:
xPC Target does not support does not support the counter/timers on this board.
Board Characteristics
Multiple block instance support A/D: No, D/A: No, Digital I/O: Yes
14-74
PCI-MIO-16E-4
volts double 1
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
driver allows each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0-5 5
-2 to +2 -2 0-2 2
-1 to + 1 -1 0-1 1
14-75
14 National Instruments
Input range (V) Range code Input range (V) Range code
For example, if the first channel is -10 to + 10 volts and the second and fifth
channels are 0 to +1 volts, enter
[-10,1,1]
Coupling Vector - Enter a coupling code for each of the channels in the
channel vector. The coupling vector must be the same length as the channel
vector. This driver allows a different coupling for each channel.
The following table is a list of the couplings for this driver and the
corresponding coupling codes.
For example, if the first and second channels are single input and the fifth
channel is a differential input, enter
[0,0,2]
14-76
PCI-MIO-16E-4
The driver selects a second differential input 8 channels higher than the first
channel. In the example above, the driver would select the thirteenth channel
as a differential input with the fifth channel.
Sampletime - Model base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in your target PC, enter
-1
If two or more boards of this type are physically present in your target PC,
enter the PCI slot number of the board associated with this driver block.
volts double 1
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
board allows the range of each channel to be different.
14-77
14 National Instruments
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 5 volts, enter
[-10,5]
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
14-78
PCI-MIO-16E-4
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
14-79
14 National Instruments
PCI-MIO-16XE-10
The PCI-6024E is an I/O board with 16 single or 8 differential analog input
(A/D) channels (16-bit) with a maximum sample rate of 100 kHz, 2 analog
output (D/A) channels (16-bit), 8 digital input and output lines, and 2 counter/
timers (24-bit).
xPC Target supports this board with four driver blocks:
Note xPC Target does not support does not support the counter/timers on
this board.
Board Characteristics
Multiple block instance support A/D: No, D/A: No, Digital I/O: Yes
14-80
PCI-MIO-16XE-10
volts double 1
Number the channels beginning with 1, even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
driver allows each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0-5 5
-2 to +2 -2 0-2 2
-1 to + 1 -1 0-1 1
For example, if the first channel is -10 to + 10 volts and the second and fifth
channels are 0 to +1 volts, enter
14-81
14 National Instruments
[-10,1,1]
Coupling Vector - Enter a coupling code for each of the channels in the
channel vector. The coupling vector must be the same length as the channel
vector. This driver allows a different coupling for each channel.
The following table is a list of the couplings for this driver and the
corresponding coupling codes.
For example, if the first and second channels are single input and the fifth
channel is a differential input, enter
[0,0,2]
The driver selects a second differential input 8 channels higher than the first
channel. In the example above, the driver would select the thirteenth channel
as a differential input with the fifth channel.
Sampletime - Model base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in your target PC, enter
-1
14-82
PCI-MIO-16XE-10
If two or more boards of this type are physically present in your target PC,
enter the PCI slot number of the board associated with this driver block.
volts double 1
Number the channels begin with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
board allows the range of each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 10volts, enter
[-10,10]
14-83
14 National Instruments
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime- Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
14-84
PCI-MIO-16XE-10
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
14-85
14 National Instruments
PXI-6040E
The PXI-6040E is an I/O board with 16 single or 8 differential analog input
channels (12-bit) with a maximum sample rate of 500 kHz, 2 analog output
channels (12-bit), 8 digital input and output lines, and 2 counter/timers
(24-bit).
xPC Target supports this board with four driver blocks:
Note xPC Target does not support does not support the counter/timers on
this board.
Board Characteristics
Multiple block instance support A/D: No, D/A: No, Digital I/O: Yes
14-86
PXI-6040E
volts double 1
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
driver allows each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0-5 5
-2 to +2 -2 0-2 2
-1 to + 1 -1 0-1 1
14-87
14 National Instruments
Input range (V) Range code Input range (V) Range code
For example, if the first channel is -10 to + 10 volts and the second and fifth
channels are 0 to +1 volts, enter
[-10,1,1]
Coupling Vector - Enter a coupling code for each of the channels in the
channel vector. The coupling vector must be the same length as the channel
vector. This driver allows a different coupling for each channel.
The following table is a list of the couplings for this driver and the
corresponding coupling codes.
For example, if the first and second channels are single input and the fifth
channel is a differential input, enter
[0,0,2]
14-88
PXI-6040E
The driver selects a second differential input 8 channels higher than the first
channel. In the example above, the driver would select the thirteenth channel
as a differential input with the fifth channel.
Sampletime - Model base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in your target PC, enter
-1
If two or more boards of this type are physically present in your target PC,
enter the PCI slot number of the board associated with this driver block.
volts double 1
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
board allows the range of each channel to be different.
14-89
14 National Instruments
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 5 volts, enter
[-10,5]
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
14-90
PXI-6040E
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
14-91
14 National Instruments
PXI-6070E
The PXI-6070E is an I/O board with 16 single or 8 differential analog input
channels (12-bit) with a maximum sample rate of 1.25 MHz, 2 analog output
channels (12-bit), 8 digital input and output lines, and 2 counter/timers
(24-bit).
xPC Target supports this board with four driver blocks:
Note xPC Target does not support does not support the counter/timers on
this board.
Board Characteristics
Multiple block instance support A/D: No, D/A: No, Digital I/O: Yes
volts double 1
14-92
PXI-6070E
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
driver allows each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0-5 5
-2 to +2 -2 0-2 2
-1 to + 1 -1 0-1 1
For example, if the first channel is -10 to + 10 volts and the second and fifth
channels are 0 to +1 volts, enter
[-10,1,1]
Coupling Vector - Enter a coupling code for each of the channels in the
channel vector. The coupling vector must be the same length as the channel
vector. This driver allows a different coupling for each channel.
14-93
14 National Instruments
The following table is a list of the couplings for this driver and the
corresponding coupling codes.
For example, if the first and second channels are single input and the fifth
channel is a differential input, enter
[0,0,2]
The driver selects a second differential input 8 channels higher than the first
channel. In the example above, the driver would select the thirteenth channel
as a differential input with the fifth channel.
Sampletime - Model base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in your target PC, enter
-1
If two or more boards of this type are physically present in your target PC,
enter the PCI slot number of the board associated with this driver block.
14-94
PXI-6070E
volts double 1
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
board allows the range of each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 5 volts, enter
[-10,5]
14-95
14 National Instruments
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
14-96
PXI-6070E
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
14-97
14 National Instruments
PXI-6508
The PXI-6508 is an I/O board with 96 digital input and output lines.
xPC Target supports this board with two driver blocks:
Board Characteristics
14-98
PXI-6508
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Chip - From the list choose 1, 2, 3, or 4.
Sampletime - Enter a base sample time or a multiple of the base sample time.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
14-99
14 National Instruments
Number the lines beginning with 1 even if the board manufacture starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The I/O board has a 8255 chip
with 3 ports. The Port parameter defines which port of the 8255 chip is used
for this driver block. Each port has a maximum or 8 digital lines that can be
configured as inputs or outputs depending on which driver block is chosen. In
each case, one block is needed for each port.
Chip - From the list choose 1, 2, 3, or 4.
Sampletime - Enter a base sample time or a multiple of the base sample time.
Sampletime - Enter a base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
14-100
15
Real Time Devices
15 Real Time Devices
“DM6420” x ISA
PC104
“DM6430” x x ISA
PC104
“DM6604” x x x ISA
PC104
“DM6804” x x ISA
PC104
“DM6814” encoder
“DM7420” x x x PCI
PC104
2
DM6420
DM6420
The DM6420 is an I/O board with 16 single or 8 differential analog input (A/D)
channels (12-bit) with a maximum sample rate of 500 kHz, 2 analog output
(D/A) channels (12-bit), 8 independent digital I/O lines, 8 dependent digital I/O
lines, and 2 counter/timers (16-bit).
xPC Target supports this board with one driver block:
Note xPC Target does not support the analog output (D/A), digital I/O, or the
counter/timers on this board.
Board Characteristics
3
15 Real Time Devices
volts double 1
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Coupling Vector - Enter either 0 (single-ended) or 1 (differential) for each of
the channels in the channel vector to choose the coupling code. The coupling
vector must be the same length as the channel vector. This driver allows the
coupling of each channel to be different.
For example, if the first and second channels are single-ended and the fifth
channel is a differential input, enter
[0,0,1]
The driver selects a second differential input 8 channels higher than the first
channel. In the example above, the driver would select the thirteenth channel
as a differential input with the fifth channel.
Gain Vector - Enter 1, 2, 4, or 8 for each of the channels in the channel vector
to choose the gain code of that channel. The gain vector must be the same
length as the channel vector. This driver allows the gain of each channel to be
different.
4
DM6420
Note While this board has programmable input ranges of +5, +10 and 0 to
10, this driver sets the input range to +10, and then lets you select different
input ranges by choosing different gains.
The following table is a list of the ranges for this driver given the gain entered
in the gain vector.
1 -10 to 10
2 -5 to +5
4 -2.5 to 2.5
8 -1.25 to 1.25
Notice that by increasing the gain code the voltage range is decreased. The gain
divides the input voltage range.
For example, if the first channel has a gain code of 1 (10 volt range) and the
second and fifth channels have a gain code of 2 (5 volt range), enter
[1,2,2]
Sample Time - Base sample time of a multiple of the base sample time.
BaseAddress - Enter the base address of the board. It is important that this
entry corresponds to the DIP-switch settings on the board. For example, if the
base address is 300 (hexadecimal), enter
0x300
5
15 Real Time Devices
DM6430
The DM6420 is an ISA PC/104 I/O board with 16 single or 8 differential analog
input (A/D) channels (16-bit) with a maximum sample rate of 100 kHz, 1 analog
output (D/A) channel (16-bit), 16 digital I/O lines, and 2 counter/timers (16-bit).
xPC Target supports this board with two driver blocks:
Note xPC Target does not support the digital I/O, or the counter/timers on
this board.
Board Characteristics
volts double 1
6
DM6430
Channel Vector - Enter numbers between 1 and 16. This driver allows the
selection of individual A/D channels in any order. The number of elements
defines the number of A/D channels used.
For example, to use the first, second and fifth channels, enter
[1,2,5]
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Gain Vector - Enter 1, 2, 4, or 8 for each of the channels in the channel vector
to choose the gain code of that channel. The gain vector must be the same
length as the channel vector. This driver allows the gain of each channel to be
different.
The following table is a list of the ranges for this driver given the gain entered
in the gain vector.
1 0 to 10
2 0 to +5
4 0 to 2.5
8 0 to 1.25
Notice that by increasing the gain code the voltage range is decreased. The gain
divides the input voltage range.
For example, if the first channel has a gain code of 1 (10 volt range) and the
second and fifth channels have a gain code of 2 (5 volt range), enter
[1,2,2]
7
15 Real Time Devices
[0,0,1]
The driver selects a second differential input 8 channels higher than the first
channel. In the example above, the driver would select the thirteenth channel
as a differential input with the fifth channel.
Sample Time - Base sample time of a multiple of the base sample time.
BaseAddress - Enter the base address of the board. It is important that this
entry corresponds to the DIP-switch settings on the board. For example, if the
base address is 300 (hexadecimal), enter
0x300
volts double 1
8
DM6604
DM6604
The DM6604 is an ISA PC/104 I/O board with 8 analog output (D/A) channels
(12-bit), and 24 digital I/O lines.
xPC Target supports this board with three driver block:
Board Characteristics
volts double 1
9
15 Real Time Devices
[1,2,5]
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels entered in the
channel vector. The range vector must be the same length as the channel
vector. This driver allows a different range for each channel.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0-5 5
For example, if the first channel is -10 to + 10 volts and the second and fifth
channels are 0 to +5 volts, enter
[-10,5,5]
Sample Time - Enter the model base sample time or a multiple of the base
sample time.
BaseAddress - Enter the base address of the board. It is important that this
entry corresponds to the DIP-switch settings on the board. For example, if the
base address is 300 (hexadecimal), enter
0x300
10
DM6604
Number the lines beginning with 1 even if the board manufacturer starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The port name defines which port
is used for this driver block. Each port has a maximum of 8 digital lines that
can be configured as inputs. In each case, one block is needed for each port.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
Number the lines beginning with 1 even if the board manufacturer starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The port name defines which port
is used for this driver block. Each port has a maximum of 8 digital lines that
can be configured as outputs. In each case, one block is needed for each port.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
11
15 Real Time Devices
DM6804
The DM6604 is an ISA PC/104 I/O board with 24 digital I/O lines and 5 counter/
timer channels (16-bit).
It contains one 8255 chip with 3 digital I/O ports and one AM9513A counter/
timer chip. For additional information about the various counter/timer modes
of that chip see the AM9513A data sheet which is part of the board
documentation.
xPC Target supports this board with eight driver blocks:
Board Characteristics
12
DM6804
Use a separate driver block for each port. By selecting the digital input driver
block, the port is configured as input.
Channel Vector - Enter numbers between 1 and 8 to select the digital input
lines used with this port. This driver allows the selection of individual digital
input lines in any order. The number of elements defines the number of digital
lines used.
For example, to use all of the digital inputs for one port, enter
[1,2,3,4,5,6,7,8]
Number the lines beginning with 1 even if the board manufacturer starts
numbering the lines with 0.
Port - From the list choose either A, B, or C. The port name defines which port
is used for this driver block. Each port has a maximum of 8 digital lines that
can be configured as inputs. In each case, one block is needed for each port.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
Number the lines beginning with 1 even if the board manufacturer starts
numbering the lines with 0.
13
15 Real Time Devices
Port - From the list choose either A, B, or C. The port name defines which port
is used for this driver block. Each port has a maximum of 8 digital lines that
can be configured as outputs. In each case, one block is needed for each port.
Sampletime - Enter a base sample time or a multiple of the base sample time.
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
TTL double 0 to 1
14
DM6804
Initial Duty Cycle - Enter a value between 0 and 1 to set the initial duty cycle.
The Duty Cycle defines the duty cycle at the initialization phase of the driver
similar to a initial value of an integrator.
Initial Toggle State - From the list, choose high or low. The Initial Toggle
State sets the initial digital level (high or low) of the output. For example, if
the Initial Duty Cycle is 0.25 and the Initial Toggle State is High, the first 25%
of the period will have a high level and the last 75% will have a low level.
Sample Time - Enter the base sample time or a multiple of the base sample
time. The sample time indicates the update rate of registration on the input
(Duty Cycle)
BaseAddress -Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
15
15 Real Time Devices
DM6804 Counter FM
The DM6804 has one AM9513A chip with 5 counters.
The DM6804 FM driver programs the AM9513A for FM (Frequency
Modulation) signal generation (a square wave with fixed duty cycle and
variable frequency).
16
DM6804
TTL double 0 to 1
17
15 Real Time Devices
The DM6804 FM & ARM driver programs the AM9513A for FM (Frequency
Modulation) signal generation (a square wave with fixed duty cycle and
variable frequency). Additionally the driver allows to arm and disarm the
counter by the second block input.
18
DM6804
TTL double 0 to 1
19
15 Real Time Devices
BaseAddress - Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
DM6804 FM Capture
This block programs the AMD9513A for capturing FM signals.
There is one output for relative frequency compared to the base frequency. To
get the actual frequency, multiply the base frequency by the relative frequency.
TTL double 0 to 1
20
DM6814
DM6814
The DM6814 is a 16-bit counting board with 3 channels. This board typically
connects to incremental encoders. Incremental encoders convert physical
motion into electrical pulses than can be used to determine velocity, direction,
and distance.
xPC Target supports this board with one driver block:
• “DM6814 Incremental Encoder”
Note xPC Target does not support the 12 digital input lines on this board.
Board Characteristics
21
15 Real Time Devices
Sample Time — Base sample time or a multiple of the base sample time.
BaseAddress — Enter the base address of the board. This entry must
corresponds to the DIP-switch settings on the board. For example, if the base
address is 300 (hexadecimal), enter
0x300
22
DM7420
DM7420
The DM7420 is a PCI PC/104 I/O board with 16 single or 8 differential analog
input (A/D) channels (12-bit) with a maximum sample rate of 1.25 MHz, 8
independent digital I/O lines, 8 dependent digital I/O lines, and 9 counter/
timers.
xPC Target supports this board with three driver blocks:
Note xPC Target does not support the counter/timers on this board.
Board Characteristics
volts double 1
23
15 Real Time Devices
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
board allows the range of each channel to be different.
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5
For example, if the first channel is -10 to +10 volts, and the second channel is
0 to 10 volts, enter
[-10,10]
Gain Vector - Enter 1, 2, 4, 8, 16, or 32 for each of the channels in the channel
vector to choose the gain code of that channel. The gain vector must be the same
length as the channel vector. This driver allows the gain of each channel to be
different.
24
DM7420
The following table is a list of the ranges for this driver given the gain entered
in the gain vector.
1 0 to 10
2 0 to +5
4 0 to 2.5
8 0 to 1.25
16 0 to 0.625
32 0 to 0.312
Notice that by increasing the gain code the voltage range is decreased. The gain
divides the input voltage range.
For example, if the first channel has a gain code of 1 (10 volt range) and the
second and fifth channels have a gain code of 2 (5 volt range), enter
[1,2,2]
The driver selects a second differential input 8 channels higher than the first
channel. In the example above, the driver would select the thirteenth channel
as a differential input with the fifth channel.
Sample Time - Base sample time or a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
25
15 Real Time Devices
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
Number the lines beginning with 1 even if the board manufacturer starts
numbering the lines with 0.
Port - From the list choose either 0, or 1.
Sample Time - Base sample time of a multiple of the base sample time.
PCI Slot (-1:autosearch) - Enter a number between -1 and n.
If only one board of this type is physically present in the target PC, enter
-1
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
Number the lines beginning with 1 even if the board manufacturer starts
numbering the lines with 0.
26
DM7420
If two or more boards of this type are physically present in the target PC, enter
the PCI slot number of the board associated with this driver block.
27
15 Real Time Devices
28
16
Softing
16 Softing
16-2
CAN-AC2-ISA
CAN-AC2-ISA
For I/O-drivers to connect xPC Target-applications to the CAN-fieldbus xPC
Target CAN-AC2 is provided as an extension to the xPC Target basic package.
See the xPC Target User’s Guide for additional information.
16-3
16 Softing
Setup-block
Every SIMULINK-model which sends and receives CAN-messages over the
CAN-AC2 board has to contain exactly one setup-block. The setup-block does
not have any inputs or outputs.
The dialogue-box allows to define general settings for the CAN-AC2 board. The
corresponding code (initializing the board) is executed once during the
"initializing blocks"-phase after the xPC Target application has been
downloaded.
The first dialogue-field (popup) allows to specify the memory-address range
used to access the board. The CAN-AC2 can be mapped into memory between
D0000-EFFFF. See the CAN-AC2 user’s guide for further information. If used
with xPC Target memory mapped I/O-devices can only be mapped into a
subarea of the choosable memory range of the CAN-AC2.
We recommend to use the following configurations if using xPC Target Version
1.1
16-4
CAN-AC2-ISA
2: D4000-D7FFF
3: D8000-D8FFF
The second and third dialogue-field allows to choose the baudrate of CAN-port
1. If the baudrate within the popup menu is not set to "user defined" the entries
in the "user-defined" dialogue-field have no meaning. If it is set to "user
defined" a wide range of baudrates can be set by setting Prescaler, Width,
Tseg1, Tseg2 to appropriate values. Contact the CAN-AC2 manual for detailed
information how to set "user defined" baudrates.
With the fourth and fifth dialogue-field the baudrate for CAN-port 2 can be set.
The last 4 dialogue-entries are used to define the Identifiers of all
CAN-messages sent or received within the current SIMULINK-model. There is
one dialogue-field for send- and receive-identifiers for CAN-port 1 and 2. Each
entry can contain a row vector with a maximal number of 200 identifiers. Each
identifier can be in the range of 0..2031. In a vector each identifier can only be
set once.
16-5
16 Softing
Send-block
To send CAN-messages specified in the setup-block, a SIMULINK-model can
contain as many as needed send-blocks.
The first dialogue-entry specifies via which CAN-port the CAN-message should
be sent.
The second dialogue-entry specifies the identifiers for CAN-messages to be
sent. The identifiers entered here as a row-vector have to be a subset of the
send identifiers defined in the setup-block of either CAN-port 1 or 2. If an
identifier is specified which was not defined in the seup-block an error message
is output after downloading the xPC Target application. The block has as many
inputs as the row-vector has elements. The data (double / 8byte) of the first
input is sent as the CAN-message with the identifier of the first element of the
vector, the second input is sent with the identifier of the second element of the
vector and so on.
The third dialogue-field specifies at which sample time intervals the
CAN-messages are sent. By using more than one send-block it is possible to
send CAN-messages at different sample time intervals even with the same
identifiers by entering appropriate sample times for each send-block.
16-6
CAN-AC2-ISA
Receive-block
To receive CAN-messages specified in the setup-block, a SIMULINK-model can
contain as many as needed receive-blocks.
16-7
16 Softing
16-8
CAN-AC2-ISA
Setup-block
Every SIMULINK-model which sends and receives CAN-messages over the
CAN-AC2 board has to contain exactly one setup-block. The setup-block does
not have any inputs or outputs.
The dialogue-box allows to define general settings for the CAN-AC2 board. The
corresponding code (initializing the board) is executed once during the
"initializing blocks"-phase after the xPC Target application has been
downloaded.
The first dialogue-field (popup) allows to specify the memory-address range
used to access the board. The CAN-AC2 can be mapped into memory between
D0000-EFFFF. See the CAN-AC2 user’s guide for further information. If used
with xPC Target memory mapped I/O-devices can only be mapped into a
subarea of the choosable memory range of the CAN-AC2.
We recommend to use the following configurations if using xPC Target Version
1.1
2: D4000-D7FFF
3: D8000-D8FFF
16-9
16 Softing
The second and third dialogue-field allows to choose the baudrate of CAN-port
1. If the baudrate within the popup menu is not set to "user defined" the entries
in the "user-defined" dialogue-field have no meaning. If it is set to "user
defined" a wide range of baudrates can be set by setting Prescaler, Width,
Tseg1, Tseg2 to appropriate values. Contact the CAN-AC2 manual for detailed
information how to set "user defined" baudrates.
With the fourth and fifth dialogue-field the baudrate for CAN-port 2 can be set.
The last 4 dialogue-entries are used to define the Identifiers of all
CAN-messages sent or received within the current SIMULINK-model. There is
one dialogue-field for send- and receive-identifiers for CAN-port 1 and 2. Each
entry can contain a row vector with a maximal number of 200 identifiers. Each
identifier can be in the range of -2032..(2^29-1). Because CAN-specification
2.0B allows to send and receive messages with standard (11bit) and extended
identifiers (29bit) concurrently the following identifier numbering method has
been implemented:
16-10
CAN-AC2-ISA
Send-block
To send CAN-messages specified in the setup-block, a SIMULINK-model can
contain as many as needed send-blocks.
The first dialogue-entry specifies via which CAN-port the CAN-message should
be sent.
The second dialogue-entry specifies the identifiers for CAN-messages to be
sent. The identifiers entered here as a row-vector have to be a subset of the
send identifiers defined in the setup-block of either CAN-port 1 or 2. If an
identifier is specified which was not defined in the setup-block an error
message is output after downloading the xPC Target application. The block has
as many inputs as the row-vector has elements.
The data (double / 8byte) of the first input is sent as the CAN-message with the
identifier of the first element of the vector, the second input is sent with the
identifier of the second element of the vector and so on.
The third dialogue-field specifies at which sample time intervals the
CAN-messages are sent. By using more than one send-block it is possible to
send CAN-messages at different sample time intervals even with the same
identifiers by entering appropriate sample times for each send-block.
16-11
16 Softing
Receive-block
To receive CAN-messages specified in the setup-block, a SIMULINK-model can
contain as many as needed receive-blocks.
16-12
CAN-AC2-PCI
CAN-AC2-PCI
For I/O-drivers to connect xPC Target-applications to the CAN-fieldbus xPC
Target CAN-AC2 is provided as an extension to the xPC Target basic package.
See the xPC Target User’s Guide for additional information.
16-13
16 Softing
Setup-block
Every SIMULINK-model which sends and receives CAN-messages over the
CAN-AC2-PCI board has to contain exactly one setup-block. The setup-block
does not have any inputs or ouputs.
The dialogue-box allows to define general settings for the CAN-AC2-PCI board.
The corresponding code (initializing the board) is executed once during the
"initializing blocks"-phase after the xPC Target application has been
downloaded.
The first and second dialogue-field allows to choose the baudrate of CAN-port
1. If the baudrate within the popup menu is not set to "user defined" the entries
in the "user-defined" dialogue-field have no meaning. If it is set to "user
defined" a wide range of baudrates can be set by setting Prescaler, Width,
Tseg1, Tseg2 to appropriate values. Contact the CAN-AC2-PCI manual for
detailed information how to set "user defined" baudrates.
With the third and fourth dialogue-field the baudrate for CAN-port 2 can be
set.
16-14
CAN-AC2-PCI
16-15
16 Softing
Send-block
To send CAN-messages specified in the setup-block, a SIMULINK-model can contain as
many as needed send-blocks.
The first dialogue-entry specifies via which CAN-port the CAN-message should
be sent.
The second dialogue-entry specifies the identifiers for CAN-messages to be
sent. The identifiers entered here as a row-vector have to be a subset of the
send identifiers defined in the setup-block of either CAN-port 1 or 2. If an
identifier is specified which was not defined in the seup-block an error message
is output after downloading the xPC Target application. The block has as many
inputs as the row-vector has elements.
The data (double / 8byte) of the first input is sent as the CAN-message with the
identifier of the first element of the vector, the second input is sent with the
identifier of the second element of the vector and so on.
The third dialogue-field specifies at which sample time intervals the
CAN-messages are sent. By using more than one send-block it is possible to
send CAN-messages at different sample time intervals even with the same
identifiers by entering appropriate sample times for each send-block.
16-16
CAN-AC2-PCI
Receive-block
To receive CAN-messages specified in the setup-block, a SIMULINK-model can
contain as many as needed receive-blocks.
16-17
16 Softing
16-18
CAN-AC2 and CANopen devices
• synchronous
• asynchronous
In the synchronous mode the client transmits a remote frame to the server to
invoke an A/D-conversion of a specified channel. It then has to wait (poll) until
the converted value is received by an ordinary CAN data-message which will
contain the values. This mode leads to large latency times up to 20ms
(Tsmin=10ms). During this time period the xPC Target gets stucked and this
is inacceptable.
On the other hand the synchronious mode fits not well into the dynamic object
model implementation of the xPC Target CAN-drivers because remote frames
have to be transmitted.
In the asynchronous mode the AIC711 sends PDO’s automatically in a regular
manner to the client. A certain change of an analog input value invokes
automatically an A/D-conversion and after conversion a PDO-message is
constructed and sent automatically to the client. This mode fits very well into
the object model of the drivers. Therefore the CANopen devices should always
be used in asynchronous mode if used together with xPC Target.
Regarding to the information in the AIC711 CANopen manual (provided by
Selectron) the following initialization messages (SDO’s) and termination
messages (SDO’s) have to be invoked.
16-19
16 Softing
////////////////////////////////////////////////////////////////
// Identifier and constant section
////////////////////////////////////////////////////////////////
#define AIC711_node_111
#define AIC711_sdo_base1536
#define MAS_boot 0
////////////////////////////////////////////////////////////////
// Initialization section
////////////////////////////////////////////////////////////////
16-20
CAN-AC2 and CANopen devices
////////////////////////////////////////////////////////////////
// Termination section
////////////////////////////////////////////////////////////////
As soon as this file is placed into your project directory and the xPC Target
application is rebuilt the messages defined above will be sent during
initialization and termination phase of the setup driver block.
The SIMULINK-model could look as follows
16-21
16 Softing
The receive block will read continuously the object to which the AIC711 sends
the PDO’s (ie. the converted A/D-values).
Because the output of this block contains the 8 bytes of the received CAN-data
as a double value a conversion block (AIC711conversion) is necessary to split
the 8 bytes (double) into 4 doubles (output signals) which represent the A/
D-value in volts for each of the four analog input channels. The conversion is
made according to the data representation of object 6401. Use the
aselmasaic711.c file as a template to implement conversion blocks for other
CANopen devices. The third channel is then stored with an outport block which
can be visualized by the xPC Target scope functionality.
Because CAN-messages with id 0 (boot) and 1536+node_id (SDO) have to be
sent and CAN-message with id 640+node_id (PDO) have to be received over
CAN-port 1 the dialogue-box of the setup-block has to look as follows:
16-22
CAN-AC2 and CANopen devices
The receive block receives the data (PDO) over CAN-message 640+node-i and
has to look therefore as follows:
16-23
16 Softing
If more than one CANopen device is connected to the network the dialogue
boxes of the setup and receive block and the CANAC2_setup.c file has to be
extended accordingly. If you need for-loops in the CANAC2_setup.c use the
variable CANAC2_counter.
If an analog output device (or digital output device) is connected to the network
an additional send block has to be dragged into the model to send the PDO’s to
the newly connected CANopen server.
16-24
17
Versalogic
17 Versalogic
17-26
VSBC-6
VSBC-6
The VSBC-6 is a single board computer with 8 signal ended analog input (A/D)
channels, 16 digital I/O lines, and a watchdog timer.
xPC Target supports this board with four driver blocks:
Board Characteristics
Manufacturer Versalogic
Number the channels beginning with 1 even if the board manufacturer starts
numbering the channels with 0.
Range Vector - Enter a range code for each of the channels in the channel
vector. The range vector must be the same length as the channel vector. This
driver allows each channel to be different.
17-27
17 Versalogic
The following table is a list of the ranges for this driver and the corresponding
range codes.
Input range (V) Range code Input range (V) Range code
-5 to +5 -5 0 to +5 5
For example, if the first channel is -10 to + 10 volts and the second and fifth
channels are 0 to +5 volts, enter
[-10,5,5]
Sampletime - Model base sample time or a multiple of the base sample time.
Number the lines beginning with 1, even if the board manufacturer starts
numbering the lines with 0.
Sample Time - Enter the base sample time or a multiple of the base sample
time.
17-28
VSBC-6
Number the lines beginning with 1, even if the board manufacturer starts
numbering the lines with 0.
Sample Time - Enter the base sample time or a multiple of the base sample
time.
17-29
17 Versalogic
17-30
Index
I
I/O dirver
library 1-2
L
library
I/O dirver 1-2
I-1