Keithley Instruments, Inc. warrants that, for a period of one (1) year from the date of shipment (3 years for Models 2000, 2001, 2002, and 2010), the Keithley
Hardware product will be free from defects in materials or workmanship. This warranty will be honored provided the defect has not been caused by use of the
Keithley Hardware not in accordance with the instructions for the product. This warranty shall be null and void upon: (1) any modification of Keithley Hardware that is made by other than Keithley and not approved in writing by Keithley or (2) operation of the Keithley Hardware outside of the environmental specifications therefore.
Upon receiving notification of a defect in the Keithley Hardware during the warranty period, Keithley will, at its option, either repair or replace such Keithley
Hardware. During the first ninety days of the warranty period, Keithley will, at its option, supply the necessary on site labor to return the product to the condition prior to the notification of a defect. Failure to notify Keithley of a defect during the warranty shall relieve Keithley of its obligations and liabilities under
this warranty.
Other Hardware
The portion of the product that is not manufactured by Keithley (Other Hardware) shall not be covered by this w arranty, and Keithley shall hav e no duty of obligation to enforce any manufacturers' warranties on behalf of the customer. On those other manufacturers’ products that Keithley purchases for resale, Keithley
shall have no duty of obligation to enforce any manufacturers’ warranties on behalf of the customer.
Software
Keithley warrants that for a period of one (1) year from date of shipment, the Keithle y produced portion of the software or firmw are (Keithley Software) will conform in all material respects with the published specifications provided such Keithley Software is used on the product for which it is intended and otherwise in
accordance with the instructions therefore. Keithley does not warrant that operation of the Keithley Softw are will be uninterrupted or error-free and/or that the
Keithley Software will be adequate for the customer's intended application and/or use. This warranty shall be null and v oid upon an y modification of the K eithle y
Software that is made by other than Keithley and not approved in writing by Keithley.
If Keithley receiv es notification of a K eithle y Software nonconformity that is co v ered by this warranty during the w arranty period, K eithle y will review the conditions described in such notice. Such notice must state the published specification(s) to which the Keithley Software fails to conform and the manner in which
the Keithley Software fails to conform to such published specification(s) with sufficient specificity to permit K eithle y to correct such nonconformity. If Keithley
determines that the Keithley Software does not conform with the published specifications, Keithley will, at its option, provide either the programming services
necessary to correct such nonconformity or develop a program change to bypass such nonconformity in the Keithley Software. Failure to notify Keithley of a
nonconformity during the warranty shall relieve Keithley of its obligations and liabilities under this warranty.
Other Software
OEM software that is not produced by Keithley (Other Software) shall not be covered by this w arranty, and Keithley shall hav e no duty or obligation to enforce
any OEM's warranties on behalf of the customer.
Other Items
Keithley warrants the following items for 90 days from the date of shipment: probes, cables, rechar geable batteries, diskettes, and documentation.
Items not Covered under Warranty
This warranty does not apply to fuses, non-rechargeable batteries, damage from battery leakage, or problems arising from normal wear or failure to follow
instructions.
Limitation of Warranty
This warranty does not apply to defects resulting from product modification made by Purchaser without Keithley's express written consent, or by misuse of any
product or part.
Disclaimer of Warranties
EXCEPT FOR THE EXPRESS WARRANTIES ABOVE KEITHLEY DISCLAIMS ALL OTHER WARRANTIES, EXPRESS OR IMPLIED, INCLUDING
WITHOUT LIMIT ATION, ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A P ARTICULAR PURPOSE. KEITHLEY DISCLAIMS ALL WARRANTIES WITH RESPECT TO THE OTHER HARDWARE AND OTHER SOFTWARE.
Limitation of Liability
KEITHLEY INSTRUMENTS SHALL IN NO EVENT, REGARDLESS OF CAUSE, ASSUME RESPONSIBILITY FOR OR BE LIABLE FOR: (1) ECONOMICAL, INCIDENTAL, CONSEQUENTIAL, INDIRECT, SPECIAL, PUNITIVE OR EXEMPLARY DAMAGES, WHETHER CLAIMED UNDER
CONTRACT, TORT OR ANY OTHER LEGAL THEORY, (2) LOSS OF OR DAMAGE TO THE CUSTOMER'S DATA OR PROGRAMMING, OR (3) PENAL TIES OR PENALTY CLAUSES OF ANY DESCRIPTION OR INDEMNIFICATION OF THE CUST OMER OR O THERS FOR COSTS, DAMAGES, OR
EXPENSES RELATED TO THE GOODS OR SERVICES PROVIDED UNDER THIS WARRANTY.
The print history shown below lists the printing dates of all Revisions and Addenda created for this manual. The Revision
Level letter increases alphabetically as the manual undergoes subsequent updates. Addenda, which are released between Revisions, contain important change information that the user should incorporate immediately into the manual. Addenda are numbered sequentially. When a new Revision is created, all Addenda associated with the previous Revision of the manual are
incorporated into the new Revision of the manual. Each new Revision includes a revised copy of this print history page.
Revision A (Document Number 81830)................................................................................................... July 1996
Revision B (Document Number 81830).............................................................................................. August 1998
All Keithley product names are trademarks or registered trademarks of Keithley Instruments, Inc.
Other brand and product names are trademarks or registered trademarks of their respective holders.
Safety Precautions
The following safety precautions should be observed before using
this product and any associated instrumentation. Although some instruments and accessories would normally be used with non-hazardous voltages, there are situations where hazardous conditions
may be present.
This product is intended for use by qualified personnel who recognize shock hazards and are familiar with the safety precautions required to avoid possible injury. Read the operating information
carefully before using the product.
The types of product users are:
Responsible body is the individual or group responsible for the use
and maintenance of equipment, and for ensuring that operators are
adequately trained.
Operators use the product for its intended function. They must be
trained in electrical safety procedures and proper use of the instrument. They must be protected from electric shock and contact with
hazardous live circuits.
Maintenance personnel perform routine procedures on the product
to keep it operating, for example, setting the line voltage or replacing consumable materials. Maintenance procedures are described in
the manual. The procedures explicitly state if the operator may perform them. Otherwise, they should be performed only by service
personnel.
Service personnel are trained to work on live circuits, and perform
safe installations and repairs of products. Only properly trained service personnel may perform installation and service procedures.
Exercise extreme caution when a shock hazard is present. Lethal
voltage may be present on cable connector jacks or test fixtures. The
American National Standards Institute (ANSI) states that a shock
hazard exists when voltage levels greater than 30V RMS, 42.4V
peak, or 60VDC are present. A good safety practice is to expect
that hazardous voltage is present in any unknown circuit bef ore
measuring.
Users of this product must be protected from electric shock at all
times. The responsible body must ensure that users are prevented
access and/or insulated from every connection point. In some cases,
connections must be exposed to potential human contact. Product
users in these circumstances must be trained to protect themselves
from the risk of electric shock. If the circuit is capable of operating
at or above 1000 volts, no conductive part of the circuit may be
exposed.
As described in the International Electrotechnical Commission
(IEC) Standard IEC 664, digital multimeter measuring circuits
(e.g., Keithley Models 175A, 199, 2000, 2001, 2002, and 2010) are
Installation Category II. All other instruments’ signal terminals are
Installation Category I and must not be connected to mains.
Do not connect switching cards directly to unlimited power circuits.
They are intended to be used with impedance limited sources.
NEVER connect switching cards directly to AC mains. When connecting sources to switching cards, install protective devices to limit fault current and voltage to the card.
Before operating an instrument, make sure the line cord is connected to a properly grounded power receptacle. Inspect the connecting
cables, test leads, and jumpers for possible wear, cracks, or breaks
before each use.
For maximum safety, do not touch the product, test cables, or any
other instruments while power is applied to the circuit under test.
ALWAYS remove power from the entire test system and discharge
any capacitors before: connecting or disconnecting cables or jumpers, installing or removing switching cards, or making internal
changes, such as installing or removing jumpers.
Do not touch any object that could provide a current path to the
common side of the circuit under test or power line (earth) ground.
Always make measurements with dry hands while standing on a
dry, insulated surface capable of withstanding the voltage being
measured.
Do not exceed the maximum signal levels of the instruments and accessories, as defined in the specifications and operating information, and as shown on the instrument or test fixture panels, or
switching card.
When fuses are used in a product, replace with same type and rating
for continued protection against fire hazard.
Chassis connections must only be used as shield connections for
measuring circuits, NOT as safety earth ground connections.
If you are using a test fixture, keep the lid closed while power is applied to the device under test. Safe operation requires the use of a
lid interlock.
If a screw is present, connect it to safety earth ground using the
wire recommended in the user documentation.
!
The symbol on an instrument indicates that the user should refer to the operating instructions located in the manual.
The symbol on an instrument shows that it can source or measure 1000 volts or more, including the combined effect of normal
and common mode voltages. Use standard safety precautions to
avoid personal contact with these voltages.
The WARNING heading in a manual explains dangers that might
result in personal injury or death. Alw ays read the associated infor mation very carefully before performing the indicated procedure.
Instrumentation and accessories shall not be connected to humans.
Before performing any maintenance, disconnect the line cord and
all test cables.
To maintain protection from electric shock and fire, replacement
components in mains circuits, including the power transformer, test
leads, and input jacks, must be purchased from Keithley Instruments. Standard fuses, with applicable national safety approvals,
may be used if the rating and type are the same. Other components
that are not safety related may be purchased from other suppliers as
long as they are equivalent to the original component. (Note that selected parts should be purchased only through Keithley Instruments
to maintain accuracy and functionality of the product.) If you are
unsure about the applicability of a replacement component, call
technical support for information.
To clean the instrument, use a damp cloth or mild, water based
cleaner. Clean the exterior of the instrument only. Do not apply
cleaner directly to the instrument or allow liquids to enter or spill
on the instrument.
The CAUTION heading in a manual explains hazards that could
damage the instrument. Such damage may invalidate the warranty.
About this manual
Quality control
Keithley Instruments manufactures quality and versatile products, and we want our documentation to reflect that same quality. We take great pains to publish manuals that are informative and
well organized. We also strive to make our documentation easy to understand for the novice as
well as the expert.
If you have comments or suggestions about how to mak e this (or other) manuals easier to understand, or if you find an error or an omission, please fill out and mail the reader response card at
the end of this manual (postage is prepaid).
Conventions
Procedural
Keithley Instruments uses various conventions throughout this manual. You should become
familiar with these conventions as they are used to draw attention to items of importance and
items that will generally assist you in understanding a particular area.
WARNING
CAUTION
NOTE
When referring to pin numbering, pin 1 is always associated with a square solder pad on the
actual component footprint.
A warning is used to indicate that an action must be done with great
care. Otherwise, personal injury may result.
A caution is used to indicate that an action may cause minor equipment damage or the loss of data if not performed carefully.
A note is used to indicate important information needed to perform an
action or information that is nice-to-know.
Notational
A forward slash (/) preceding a signal name denotes an active LOW signal. This is a standard
Intel convention.
Caret brackets (<>) denote keystrokes. For instance <Enter> represents carriage-return-withline-feed keystroke, and <Esc> represents an escape keystroke.
Driver routine declarations are shown for C and BASIC (where applicable).
Hungarian notation is used for software parameters. In other words, the parameter type is
denoted by a one or two letter lower case prefix:
ccharacter, signed or unsigned
sshort integer, signed
wshort integer, unsigned
llong integer, signed
dwlong integer, unsigned
For example, wBoardAddr would be an unsigned short integer parameter.
An additional p prefix before the type prefix indicates that the parameter is being passed by reference instead of by value. (A pointer to the variable is being passed instead of the variable
itself).
For example, pwErr would be an unsigned short integer parameter passed by reference.
This notation is also used in BASIC although no distinction between signed and unsigned vari-
ables exists.
In BASIC, all parameters also have a type suffix:
$character, signed or unsigned
%integer, signed or unsigned
&long integer, signed or unsigned
Routine names are printed in bold font when they appear outside of function declarations, e.g.,
ReadStatus.
Parameter names are printed in italics when they appear outside of function declarations, e.g.
sControls.
Constants are defined with all caps, e.g., ALL_AXES. Underscores {_} must be replaced by
periods {.} for use with BASIC.
Combinational logic and hexadecimal notation is in C convention in many cases. For example,
the hexadecimal number 7Ch is shown as 0x7C.
C relational operators for OR and AND functions — “| |” and “&&” — are used to minimize the
confusion associated with grammar.
Table of Contents
1Introduction and Installation
Description of the 5000 ...................................................................................................................................... 1-2
Power .......................................................................................................................................................... 1-3
W7, board base address............................................................................................................................... 1-3
W9 to W11, clock speed select .................................................................................................................. 1-5
Theory of operation ............................................................................................................................................ 2-2
Loading the Axis A counter ....................................................................................................................... 2-2
Port locations ...................................................................................................................................................... 2-3
Addressing an onboard port ....................................................................................................................... 2-3
Reading from an onboard port ................................................................................................................... 2-4
Writing the controller internal registers ..................................................................................................... 2-4
Writing to an onboard port ......................................................................................................................... 2-4
Reading the stepper controller status port .................................................................................................. 2-5
Reading the state buffer .............................................................................................................................. 2-5
Control mode selection .............................................................................................................................. 2-8
Data register selection ................................................................................................................................ 2-9
Description of interrupt control ......................................................................................................................... 3-2
Completing an interrupt ............................................................................................................................. 3-5
Special mask mode .................................................................................................................................... 3-5
Specific rotation (specific priority) ........................................................................................................... 3-5
Setting speed data ............................................................................................................................................. A-3
High speed preset mode .................................................................................................................................... A-4
High speed return to home ............................................................................................................................... A-8
Constant speed return to home ......................................................................................................................... A-9
Speed change during operation ...................................................................................................................... A-10
Typical high speed preset mode calculations .................................................................................................... B-2
Determine R2 to R7 from given values ..................................................................................................... B-3
Example 1 .................................................................................................................................................. B-4
Example 2 .................................................................................................................................................. B-5
CPC I/O and Interrupt Mapping
PC I/O map ........................................................................................................................................................ C-2
Optimizing the scale factor, n ............................................................................................................................ E-2
Revision A .......................................................................................................................................................... F-2
Revision B .......................................................................................................................................................... F-2
Revision C .......................................................................................................................................................... F-2
Revision D .......................................................................................................................................................... F-2
Revision E .......................................................................................................................................................... F-3
Revision F .......................................................................................................................................................... F-3
Revision G .......................................................................................................................................................... F-3
Revision H .......................................................................................................................................................... F-3
GIntroduction to the Model 9011 Motion Simulator
Features ............................................................................................................................................................. G-2
General description ........................................................................................................................................... G-2
Servo systems ............................................................................................................................................ G-3
Stepper systems ......................................................................................................................................... G-3
Figure 1-5Opto power select jumpers ......................................................................................................................... 1-7
Figure 1-6Optoisolation on the 5000 .......................................................................................................................... 1-8
Figure 1-7J1 pins allocated by axis ............................................................................................................................. 1-9
Figure 3-3PIC ICW format ......................................................................................................................................... 3-7
Figure 3-4PIC OCW format ....................................................................................................................................... 3-8
GIntroduction to the Model 9011 Motion Simulator
Figure G-1Analog or ± PWM application .................................................................................................................. G-5
Figure G-2Pulse and direction .................................................................................................................................... G-6
Figure G-3Using the 9011 to isolate encoder problems ............................................................................................. G-6
Figure G-4Stepper system .......................................................................................................................................... G-7
Figure G-5Driving a servo amplifier .......................................................................................................................... G-7
Figure G-6Driving a stepper motor system ................................................................................................................ G-8
v
List of Tables
1Introduction and Installation
Table 1-1Voltage requirements for the 5000 ............................................................................................................. 1-3
Table 1-2Selecting the base addresss ........................................................................................................................ 1-3
Table 1-3Selecting the clock speed with W9 to W11 ................................................................................................ 1-5
Table 1-4Selecting the PC bus interrupt request........................................................................................................ 1-6
Table 1-5Selecting opto power .................................................................................................................................. 1-7
Table G-29011 Connections for common applications ............................................................................................. G-5
vii
1
Introduction and Installation
1-2Introduction and InstallationModel 5000 Hardware Guide
Description of the 5000
The 5000 Stepper Motor Controller card allows a PC/XT/AT compatible computer to control
three independent stepper motor drivers. This allows you to perform complex motion control
profiling routines.
Each axis of control provides five limit inputs — two stop limits, two deceleration limits, and
one home limit. Outputs include pulse/direction and hold. The pulse/direction output allows a
rate of up to 240,000 pulses per second. All inputs and outputs are optically isolated to minimize
noise at the card cage and protect the card from induced voltage transients.
Operation of the 5000 is controlled through user-accessible internal registers. Data registers
enable specification of the following values: number of steps, low speed rate, high speed rate,
acceleration rate, deceleration rate, and rampdown point. Intelligent controller chips (one per
axis) enable programmable velocity profiling, including direction. You may select from four programming modes and eight operating modes.
Figure 1-1 shows a functional block diagram of the Model 5000.
13.13 x 4.200 x 0.500 inches
0 degrees to 70 degrees C
Refer to Table 1-1
37 Pin D Sub (J1) Amp 206802-1
Ansley 609-37D
Berg 66167-237
MOTOR A PULSE & DIRECTION
MOTOR A LIMITS
MOTOR B PULSE & DIRECTION
MOTOR B LIMITS
MOTOR C PULSE & DIRECTION
MOTOR C LIMITS
I OR
I OW
RST DRV
CLK
AEN
Model 5000 Hardware GuideIntroduction and Installation1-3
Table 1-1
Voltage requirements for the 5000
VoltageNominal CurrentMaximum CurrentNotes
PC Bus: +5V
PC Bus: +12V
1.3A
0
2.5A
0
Using bus +5V to
power optos
Installation
Power
PC Bus: +5V
PC Bus: +12V
Auxiliary: +5V
Auxiliary: +12V
Auxiliary: +5V
Auxiliary: +12V
Figure 1-2 shows the 5000 layout with jumper and connector locations. Jumpers consist of
unshrouded headers and shorting connectors. The jumper options are explained below.
T o determine the correct jumper configuration for the system, follo w the guidelines gi ven belo w.
The † symbol indicates default jumper locations.
The 5000 requires +5 volts from the PC Bus. Motor power must come from an external supply
capable of supplying motor current plus approximately 300mA of opto current. Provisions are
made to supply opto current from the PC Bus. However, using voltage from the PC Bus to drive
the optoisolators eliminates isolation. Therefore, it is not recommended for permanent use.
1.0A
0.4A
0.4A
0
0
0.4A
2.0A
0.8A
0.8A
0
0
0.8A
Using bus +12V to
power optos
Using auxiliary +5V to
power optos
Using auxiliary +12V
to power optos
W7, board base address
Jumper W7 determines the upper 4-bit nibble of the board I/O address according to Table 1-2.
Hex switches SW1 and SW2 determine the lower 8 bits of the address, with SW2 representing
the most significant nibble (MSN) and SW1 representing the least significant nibble (LSN).
Since the card occupies two successive I/O ports, only the even settings of the LSN switch are
used.
Table 1-2
Selecting the base address
W7I/O Address
(1-2)
(2-3)
† Default setting.
Note: This jumper determines the upper 4-bit
nibble of the board I/O address.
3xxh†
2xxh
1-4Introduction and InstallationModel 5000 Hardware Guide
Figure 1-2
5000 board layout
J1
W1
W2
W3W5
W4
W6
123
U1
U2U3
U6U15
U21
U27
U7U16U12
U22
U8U17
U23
U28
W7
3
1
U4U5U25
W8
212
111
SW1SW2
U9U18U13
U10U19
U11U20U14
U24
U26U30
U29
U39
U33
U40
U34U41
U35U42
U36
U43
U31
U37
U32
U38
W11W9W10
Note: Passive devices are not shown to improve clarity.
Model 5000 Hardware GuideIntroduction and Installation1-5
W9 to W11, clock speed select
Figure 1-3
Clock speed select jumpers
U37
U38
W11
W10
U39
U40
U41
U42
Note: Jumpers are viewed with the bus edge connector down and to the right.
W9
U31
U32
U33
U34
U35
U36U43
Figure 1-3 shows the physical locations. W9 – W11 (W11 — Axis A, W10 — Axis B, and
W11 — Axis C) are used to select the base clock rate (f
troller. The f
rate supplied to each controller determines the available step rate. It is also
clock
) used by each stepper motor con-
clock
used in the formula in Appendix B to determine the actual pulse rate. Select a clock rate from
Table 1-3.
Table 1-3
Selecting the clock speed with W9 to W11
W9, W10, W11Frequency (MHz)
(1-2)
(3-4)
(5-6)
(7-8)
† Default setting.
Note: To obtain the maximum rate of 240,000 pulses per second, use the default clock
setting. These jumpers select the base clock rate used by axes A to C.
0.625
1.25
2.50
5.00†
The default setting, 5MHz, may be altered to allow slower step rates. Examples and formulas for
setting defaults are shown in Section 2 and Appendix E of this manual.
1-6Introduction and InstallationModel 5000 Hardware Guide
W8, interrupt select
Figure 1-4 shows the physical location. W8 selects the PC Bus interrupt request line used for
interrupt operation according to Table 1-4.
Figure 1-4
Interrupt select jumper
W6
W4
U6
U7
1
2
3
W2
W1W3W5
U8
U9
U10
U11
SW1SW2
W7
1
3
U2U3
U4U5
2
1
W8
U1
12
11
J1
Table 1-4
Selecting the PC bus interrupt request
W8Interrupt RequestDescription
(1-2)
(3-4)
(5-6)
(7-8)
(9-10)
(11-12)
† Default setting. For applications not requiring interrupts, you may remove the strap
from W8.
Note: The requests listed are defaults in most PC systems.
IRQ2
IRQ3
IRQ4
IRQ5
IRQ6
IRQ7
unused†
unused
Serial Port Card
unused
Diskette Adapter Card
Parallel Port Card
Model 5000 Hardware GuideIntroduction and Installation1-7
W1 to W6, opto power (bus)
Figure 1-5
Opto power select jumpers
W6
W4
W2
W5
W3
W1
W7
U2
Note: Jumpers are viewed with the bus edge connector down and to the right.
J1
Table 1-5
Selecting opto power
AxisJumperStrapDescription
W1
A
W2
W3
B
W4
W5
C
W6
Note: You can select from either internal or external opto power.
(1-2)
(2-3)
(1-2)
(1-2)
(2-3)
(1-2)
(1-2)
(2-3)
(1-2)
+12V
+5V
Ground
+12V
+5V
Ground
+12V
+5V
Ground
Figure 1-5 shows the physical locations. W1 through W6 are pro vided for customer con v enience
during development (W1, W2 — Axis A; W3, W4 — Axis B; W5, W6 — Axis C). They enable
the use of bus power for the optoisolators according to Table 1-5.
These jumpers allow the bus to supply voltage required by the output side of the optoisolators on
all lines interfacing with the connector at the rear of the card. Howev er, this is not recommended
because damaging spikes can be induced on the output interface and will conduct through the
computer power supply. These jumpers should be removed. Use an external voltage source to
power the output side of the optos. To use voltage supplied by the motor, connect the positive
connection to the power pins on the I/O connector and the negative connection to the ground
pins on the I/O connector.
1-8Introduction and InstallationModel 5000 Hardware Guide
Current limiting resistors protect the output side of the optoisolators. Resistors must be calculated as follows:
V 1.5–
Rn
-----------------=
I
where: I = 10mA
The 5000 is set up at the factory to run at 5V. To run at 12V (assuming 12V is really 13V, worst
case), Rn will be:
13 1.5–
-------------------1150Ω=
0.010
The next standard 10% value is 2.2K. R3–R12 are all ready at 2.2K, so they can be held at that
value.
Change RP3, RP5, and RP7 from 680 ohms to at least 1.2K. Use at least
1
W resistors to reduce
/
4
Mean Time Between Failures (MTBF).
Connector pinouts
The following subsection contains connector pinout information. Suggested mating connector
part numbers are listed in paragraph technical specifications . Table 1-6 shows the pin definitions
for connector J1.
These are active low inputs for use with normally open switches. To use normally closed
switches or optointerrupter modules, ICs — U22, U24, and U26 — must be changed from
74LS244 to 74LS240 . These ICs are socketed to make this change easy. Figure 1-6 shows the
optoisolation method used on the 5000. Figure 1-7, partitioned by axis, and Tables 1-6 and 1-7
show the pinout of connector J1.
Figure 1-6
Optoisolation on the 5000
AXIS A. PINS 4, 5, 6, 22, 23, 24
B. PINS 10, 11, 12, 28, 29, 30
C. PINS 16, 17, 18, 34, 35, 36
Note: Limits, Home, Rampdown, and INS are optoisolated.
AUXILIARY POWER
AUXILIARY GROUNDAUXILIARY GROUND
Model 5000 Hardware GuideIntroduction and Installation1-9
Figure 1-7
J1 pins allocated by axis
AXIS
A
1
19
3720
AXIS
C
Note: The view is looking into the connector.
AXIS
B
Table 1-6
Connector J1 pin definitions
Pins
NameDescriptionAxis AAxis BAxis C
1713Auxiliary +12V12V input optoisolator supply
unless W1, W3, and W5 are
jumpered to use PC Bus power (this
is not recommended)
2814DirectionDirection output
/3/9/15User definableOTS signal output (see output Data
Register Selection)
/4/10/16+LimitLimit input (+) direction
/5/11/17HomeHome input
/6/12/18–LimitLimit input (–) direction
202632Pulse
Pulse output (approx. 50% duty
cycle)
212733HoldActive output when motor stopped
/22/28/34Input/ExternalINS signal (see Controller Status
Port)
/23, /24 /29, /30 /35, /36 ±RampdownWhen activated during a mo ve in the
(±) direction, respectively , the motor
ramps down to starting velocity.
Continues to run at starting velocity
until deactivated or move complete.
253137Auxiliary GroundGround input optoisolator supply
unless W2, W4, and W6 are
jumpered to use PC Bus power (this
is not recommended).
Note: A forward slash (/) preceding a signal name denotes an active LOW signal.
2
Operation and
Programming
2-2Operation and ProgrammingModel 5000 Hardware Guide
Theory of operation
The 5000 is intended for use with a pulse and direction input stepper motor driver. The 5000 is
capable of a step rate of 240,000 pulses per second, which makes it ideal for microstepping
applications.
Three independent intelligent stepper controllers produce profiled outputs optimized for each
axis. All parameters can be changed on the fly , and the up and down ramps can be programmed
independently. Each controller handles a full complement of limit inputs. The controllers can be
operated in either a polled or an interrupt configuration. In a polled configuration, the status of
each controller is read to determine when the motion is complete. In an interrupt configuration,
each controller generates an interrupt when the end of the motion is complete. Complex profiles
are possible by varying the profile parameters during operation.
T o minimize the use of PC port space, the 5000 uses an indirect addressing scheme. Only two I/O
addresses are occupied by the 5000 on the PC Bus. The location of these ports is determined by
W7 (see Section 1) and the two rotary hex switches — SW2 and SW1. The address port is the
even, or lowest port, while the data port is the odd, or highest.
To write to a port, you must first write to the indirect port address at the even I/O port and either
read or write the odd (data) port. See Table 2-1 for port definitions.
Each controller occupies four indirect ports as indicated in the indirect address list. In addition,
each controller has eight internal registers (R0 through R7). Table 2-2 describes the function of
each register . Each register is accessed by first writing a Data Re gister Selection command to the
command buffer of the respective controller. Register data are then written to the indirect
address. The example below shows the steps necessary to access a typical register.
Loading the Axis A counter
1. Write the indirect address of the Axis A command register (00h) to the board indirect address
port ( x 00h).
2. Write the Data Register selection command for the counter register (80h) to the indirect data
port ( x 01h).
3. Write the indirect address of Axis A register bits (0-7) buffer (01h) to the board indirect
address port.
4. Write the least significant byte of the 24-bit counter value to the indirect data port.
5. Write the indirect address of Axis A register bits (8-15) buffer (02h) to the board indirect
address port.
6. Write the next significant byte of the 24-bit counter value to the indirect data port.
7. Write the indirect address of Axis A register bits (16-23) buffer (03h) to the board indirect
address port.
8. Write the most significant byte of the 24-bit counter value to the indirect data port.
While this procedure may seem complicated, you can reduce the number of steps by using the
supplied driver functions on the companion software disk.
The status of each controller can be accessed by reading from the indicated indirect address
using the bit assignments explained below. Additional status information is available by reading
the state buffer at the indicated indirect address.
Register values can be calculated using the formula in paragraph User-accessible registers . If
you have already installed the software into a working subdirectory, this is a trivial task. Use
program PRO5000.EXE located in the subdirectory where you loaded the software utilities.
Model 5000 Hardware GuideOperation and Programming2-3
The operation of each controller is determined by the values loaded into its internal registers and
the commands sent to the command register. For an explanation of these commands see paragraph Command buffer .
Port locations
The 5000 uses indirect addressing. Two consecutive I/O addresses are used, and read and write
access to different ports onboard the 5000 requires a write/read or a write/write sequence. This
procedure may be simplified if the supplied drivers are used. Bus ports occupied by the 5000 are
as follows:
A0Port
01Address
Data
Addressing an onboard port
1. Write the address of the desired onboard port to the address port.
2. Write a byte to, or read a byte from the data port. For register assignments, see Table 2-1.
Table 2-1
Onboard port map
Indirect AddressI/O ReadI/O Write
00hAxis A StatusAxis A Command Buffer
01hAxis A Counter (0-7)Axis A Register (0-7)
02hAxis A Counter (8-15)Axis A Register (8-15)
03hAxis A Counter (16-23)Axis A Register (16-23)
04h-07hAxis A ImageAxis A Images
08hAxis B StatusAxis B Command Buffer
09hAxis B Counter (0-7)Axis B Register (0-7)
0AhAxis B Counter (8-15)Axis B Register (8-15)
0BhAxis B Counter (16-23)Axis B Register (16-23)
0Ch-0FhAxis B ImageAxis B Images
10hAxis C StatusAxis C Command Buffer
11hAxis C Counter (0-7)Axis C Register (0-7)
12hAxis C Counter (8-15)Axis C Register (8-15)
13hAxis C Counter (16-23)Axis C Register (16-23)
14h-17hAxis C ImageAxis C Images
18hnot usedSync Latch (responds to all)
19h-1Fhnot usedSync Latch Images
20hnot usedReset Latch
2-4Operation and ProgrammingModel 5000 Hardware Guide
Table 2-1
Onboard port map (cont.)
Indirect AddressI/O ReadI/O Write
21h-27hnot usedReset Latch Images
28hPIC 1 A0 ReadPIC 1 A0 Write
29hPIC 1 A1 ReadPIC 1 A1 Write
2Ah-2FhPIC 1 ImagesPIC 1 Images
30hAxis A State Buffernot used
31h-37hAxis A State Buffer Imagesnot used
38hAxis B State Buffernot used
39h-3FhAxis B State Buffer Imagesnot used
40hAxis C State Buffernot used
41h-47hAxis C State Buffer Imagesnot used
Note: Write the desired register address through the address port, and read or write the data through the data port.
Programming
Reading from an onboard port
Writing the controller internal registers
This section explains how to access the controller registers, how to read the status port, how to
simultaneously start the controllers, and how to execute a hard reset.
1. Write the address from Table 2-1 for the desired onboard register to the address port.
2. Read the data from the data port.
1. Write the address from Table 2-1 for the desired controller command buffer to the address
port.
2. Write the register select command (8
data register selection in paragraph Command buffer .
3. Write the address from Table 2-1 for the register bits to be written for the selected controller to
the address port.
4. Write the data to be loaded into the internal register to the data port.
×
h for the desired internal register to the data port (see
Writing to an onboard port
1. Write the address from Table 2-1 for the desired onboard register to the address port.
2. Write the data to be written to the data port.
Model 5000 Hardware GuideOperation and Programming2-5
Reading the stepper controller status port
Reading the controller status port gives the following information: (INT = interrupt output,
INS = general purpose input signal).
Status Port
D6D2D4D0D7D3D5D1
1: -LIMIT ACTIVE
1: +LIMIT ACTIVE
1: HOME ACTIVE
1: R0 (COUNTER)=0
0: INS SIGNAL=HIGH
1: INS SIGNAL=LOW
1: CONSTANT PULSE RATE
1: DURING PULSE OUTPUT
1: DURING INT SIGNAL ACTIVE
(END OF MOTION)
Reading the state buffer
Sync latch
Reading the auxiliary status gives the following information:
State Buffer
D6D2D4D0D7D3D5D1
1: R0 (COUNTER)=0
1: DECELERATING
1: SLEW OR CONSTANT PULSE RATE
1: ACCELERATING
NOT USED
The Sync Latch provides a means of synchronizing the start of motion on all three axes at the
same time. Under normal conditions, the motion starts as soon as the output mode selection
command is issued. If you want to start all three axes simultaneously, Sync Latch can first be
used to disable all three axes. All three controllers, or any combination of the three, can then be
programmed for the desired motion and given the desired output mode selection command.
Motion will not begin until the Sync Latch value is written to enable the desired controllers. By
doing this, all three controllers can be started by writing a single bit. The Sync Latch is defined
as follows:
Sync Latch
D6D2D4D0D7D3D5D1
AXIS A
AXIS B
AXIS C
NOT USED
MASTER CLOCK ENABLE
For each bit of the Sync Latch, 0 = enabled, and 1 = disabled. Master Clock Enable (bit D7)
must be LOW for any clock to operate. This enables a one-bit change to synchronize all controllers. On power-up, all clocks are enabled.
2-6Operation and ProgrammingModel 5000 Hardware Guide
Reset latch
This latch gives you the ability to hard reset any controller on the 5000. Individual bits are
defined as follows:
Reset Latch
D6D2D4D0D7D3D5D1
AXIS A RESET
AXIS B RESET
AXIS C RESET
NOT USED
For all bits, 0 = Reset, 1 = Enabled.
Command buffer
Data bits — D6 and D7 — select 1 of 4 different command modes from the Command Buffer.
Command Buffer
D6D2D4D0D7D3D5D1
Table 2-2
Command mode selection
D7 D6Command Mode
0 0
0 1
1 0
1 1
Note: Command modes are selected from the
command buffer.
Operating Mode
Control Mode
Data Register
Output Pulse Mode
Operating mode selection
COMMAND
COMMAND MODE SELECT
(SEE TABLE 2-2)
The operating mode initiates motion and selects the registers used to determine speed (FL, FH1,
FH2), the type of profile (ramp or constant speed), and the motor stopping position.
Operating Mode
0D2D4D00D3D5D1
COMMAND (SEE TABLE 2-3)
0: INT OUTPUT INACTIVE
1: INT ACTIVE AT END OF MOTION
Model 5000 Hardware GuideOperation and Programming2-7
† Causes motion to begin.
Note: This mode initiates motions and selects the register used.
Soft Reset
Constant FL Speed†
Constant FH1 Speed†
Constant FH2 Speed†
High FH1 Speed†
High FH2 Speed†
Rampdown
Stop Immediately
Ramp Down and Stop
Bit D5 enables/disables INT which occurs at the end of motion. When D5 = 1, INT output will
go active at the end of motion, and could cause PIC 0 to interrupt the CPU. When D5 = 0, INT
output will remain inactive.
Soft Reset. This command must be issued at the beginning of every profile routine.
Constant FL Speed. This command will cause the controller to generate pulses at a constant
rate determined by the value in the R1 Register. The other two constant speed commands (FH1
and FH2) operate identically with FH1 or R2 and FH2 or R3 registers to determine the pulse
rate.
High FH1/FH2 Speed Command Register. The High FH1/FH2 speed command will cause the
controller to generate pulses starting at the FL rate and will accelerate to the FH1/FH2 rate.
Rampdown. This command will cause the pulses out of the controller to decelerate from the
FH1(R2) or FH2(R3) pulse rate (depending on which pulse rate command was active prior to the
Ramp-Down Command) to the FL(R1) pulse rate.
Stop Immediately. This command will cause the pulses out of the controller to stop immediately.
Ramp Down and Stop. This command will cause the pulses out of the controller to decelerate as
described in the rampdown command, then once FL(R1) pulse rate is reached, the pulses out of
the controller will stop.
2-8Operation and ProgrammingModel 5000 Hardware Guide
Control mode selection
Enables and disables Home, ±Rampdown.
Enables and disables preset rampdown mode.
Sets the direction of motion.
Control Mode
1D20D00D30D1
0: MASK HOME INPUT
1: ENABLE HOME INPUT
0: MASK BOTH
0: MASK BOTH ± RAMP - DOWN INPUTS
1: ENABLE BOTH ± RAMP - DOWN INPUTS
Home. When enabled (D0 = 1), and when Home input goes LOW, the pulses from the pulse out-
put will stop.
±Rampdown Inputs. When enabled (D1=1), pulses out of the controller pulse out line will
decelerate to the constant FL (R1) speed rate.
While operating in the constant xx speed mode, and with preset rampdown enabled, the pulses
out of the controller will stop when the number of pulses out equals the value in register R0.
Preset Rampdown. While operating in the high xx speed mode, and with preset rampdown
enabled, the pulse out of the controller will begin to decelerate when the number of pulses out
equals the value in register R6. The pulse out rate will remain constant when the rate of the
pulses equals the value in register FL or R1. It will stay this way until the number of pulses
equals the value in register R0, in which case the pulses will stop.
Model 5000 Hardware GuideOperation and Programming2-9
Data register selection
Data Register
0D2XD01D3XD1
REGISTER SELECT (SEE TABLE 2-4)
OTS CONTROL
OTS Control. This is a general purpose output bit. To set this output low, write D3 = 1. To set
this output HIGH, write D3 = 0.
Table 2-4
Data register selection
D2 D1 D0Data RegisterFunction
0 0 0
0 0 1
0 1 0
0 1 1
1 0 0
1 0 1
1 1 0
1 1 1
Note: You can select any of 8 profile generation registers.
2-10Operation and ProgrammingModel 5000 Hardware Guide
Output mode selection
Operating Mode
0D2D4D00D3D5D1
COMMAND (SEE TABLE 2-3)
0: INT OUTPUT INACTIVE
1: INT ACTIVE AT END OF MOTION
The output mode selects the output type, enabling of ramp up/down halfway, and enabling of the
digital filter for 3 limit inputs.
Output type can be either pulse and direction type or +Pulse, –Pulse type.
When ramp up/down is disabled, the pulse-out will not accelerate or decelerate from its present
pulse-out rate. This holds true even if a slow-down limit switch is activated.
For each axis, a digital filter can be activated for the ±limits (±EL) and the Home inputs. When
the filters are enabled, the input signals must be active LOW for at least four clock periods
before the controller reacts to the inputs. This way noise, with short time periods, can not cause
false triggering of the controller inputs.
Model 5000 Hardware GuideOperation and Programming2-11
User-accessible registers
The profile of each stepper controller is controlled through eight user-accessible internal registers of varying lengths. See Table 2-5.
Note: The profile of each axis is controlled by 8 internal registers.
FH 2
All13W
High Speed Cont
High Speed Home Ret
High Speed Cont
High Speed Home Ret
24R/W
13W
14W
14W
Register descriptions
The registers listed below are used in all control modes.
R0 - Down Counter: 24 Bits, Read/Write. This register decrements with every pulse-out sig-
nal. When operating in the preset rampdown mode (see control mode selection in paragraph
Command buffer ), R0 must be loaded with the value of the total number of pulses for the entire
profile routine. When the register decrements to zero, the controller will stop sending pulses.
When not operating in the preset rampdown mode, R0 will continue to decrement for every
pulse-out but will not effect any operation. When it reaches a zero value, the next pulse-out will
cause it to roll over to FFFFFFh. The range of R0 is 000001h to FFFFFFh (1 to 16,777,215d).
R1 - Low Speed (FL) Register: 13 Bits, Write Only. This register is loaded with a value that
determines the pulse-out rate or frequency. Typically, this register is used to set the low operating frequency.
The frequency of a pulse-out is a function of the rate multiplier and the value of R1. See R7
below for further details in determining the rate multiplier value n . The range of R1 is 0001h to
1FFFh (1 to 8191d).
f
where f
pout
nR1Hz=
pout
is the pulse out frequency.
2-12Operation and ProgrammingModel 5000 Hardware Guide
R2 - FH1, High Speed 1 Register: 13 Bits, Write Only. This register is loaded with a value
that determines the pulse-out rate or frequency. Typically, this register is used to set one of two
high operating frequencies. The range of R2 is 0001h to 1FFFh (1 to 8191d).
f
pout
nR2Hz=
R3 - FH2, High Speed 2 Register: 13 Bits, Write Only. This register is loaded with a value
that determines the pulse-out rate or frequency . The range of R3 is 0001h to 1FFFh (1 to 8191d).
pout
nR3Hz=
f
R4 - Acceleration Rate Register: 14 Bits, Write Only. This register is loaded with a value that
determines the acceleration rate of the pulse-out signal. Any time a command causes an acceleration, the rate will always be determined by the acceleration rate register.
–
f
pout2fpout1
Acceleration Rate
The acceleration rate is a function of the value in R4, the rate multiplier n , and f
Acceleration Rate
---------------------------------- -=
t
–
2t1
nf
clock
-----------------=pulses per second
R4
.
clock
2
The range of R4 is 0002h to 3FFFh (2 to 16,383d).
Figure 2-1
Acceleration profile
ƒ
Pout H
z
ƒ
Pout
(R2 OR R3)
ƒ
Pout (R1)
1
2
T1T2
T
Model 5000 Hardware GuideOperation and Programming2-13
R5 - Deceleration Rate Register: 14 Bits, Write Only. This register is loaded with a value that
determines the deceleration rate of the pulse-out signal. An y time a command or a limit switch, ±
rampdown causes a deceleration, the rate of deceleration will always be determined by this register. The range of R5 is 0002h to 3FFFh (2 to 16,383d).
f
–
pout2fpout1
Deceleration Rate
---------------------------------- -=
t
–
2t1
The deceleration rate is a function of the value in R5, the rate multiplier n, and f
Deceleration Rate
nf
clock
-----------------=pulses per second
R5
2
clock
.
Figure 2-2
Deceleration profile
ƒ
Pout H
z
ƒ
Pout
2
(R2 OR R3)
ƒ
Pout (R1)
1
T1T2
T
R6 - Ramping Down Point Register: 20 Bits, Write Only. The rampdown point register is
used internally in the controller while operating only in the preset rampdown mode. When the
value in register R6 is greater than the value in R0 (down counter), the pulse-out rate will begin
to decelerate at the rate determined by the deceleration rate register . Deceleration will occur only
if the pulse-out rate is within the high speed rate determined by register R2(FH1) or R3(FH2).
Once the pulse-out rate is equal to the low speed rate, deceleration will stop and the pulse-out
rate will remain at the low speed rate until the down counter equals zero, in which case pulse-out
will stop. When using the Rampdown Point Register (while in preset rampdown mode), it is
desirable to set the rampdown point so that the count-down register equals a small v alue once the
low speed rate is reached. (This is sometimes referred to as a porch .) The formula below determines the value of R6 for a given profile so that the count-down register will have a value of 10
when the Low Speed Rate is reached during the deceleration.
The range of R6 is 00001h to FFFFFh (1 to 1,048,575d).
2-14Operation and ProgrammingModel 5000 Hardware Guide
R7 - Rate Multiplier Register: 10 Bits, Write Only. This register is loaded with a value that
determines the multiplier value of the speed registers R1, R2, and R3. The rate multiplication
factor n which is typically set to 1.0 is given as:
f
clock
-------------------=
n
8192 R7
The range of R7 is 002h to 3FFh (2 to 1023d).
If:
f
clock
R7
------------- -=
8192
then n is equal to 1.0, and the values loaded into R1, R2, and R3 are in pulses per second. In
addition, because n = 1, many of the formulas are simplified.
3
Interrupt Control
3-2Interrupt ControlModel 5000 Hardware Guide
Description of interrupt control
The 5000 uses an 8259A Programmable Interrupt Controller (PIC) to handle the interrupt
sources on the board. Each axis can generate two interrupts. The first is an end-of-motion
(EOM) issued when a programmed move is completed. The second interrupt is generated from
INS, a user-defined signal available at J1 (22, 28, and 34) for axes A, B, and C, respectively.
The PIC may only be used in a nonvectored mode (polled). When a board-level interrupt is generated, the PIC must be polled to determine which interrupt was triggered. The PIC may be disabled by removing jumper W8.
Only the features of the 8259A PIC that are used by 5000 are discussed below. For complete
information on the 8259A PIC refer to Intel's Peripheral Components Manual.
Figure 3-1 shows a functional block diagram of the 8259A PIC. On the 5000, the PIC is connected directly to the PC Bus through jumper W8.
Figure 3-1
PIC block level diagram
INTAINT
CONTROL LOGIC
D7-D0
RD
RD
WR
WR
AO
AO
CS
CAS0
CAS0
CAS1
CAS1
CAS2
CAS2
SP/EN
Note: The 5000 uses an Intel 8259A and is directly connected to the PC Bus through jumper W8.
DATA BUS
BUFFER
READ/WRITE
LOGIC
CASCADE BUFFER/
COMPARITOR
IN
IN
SERVICE
SERVICE
REGISTER
REGISTER
(ISR)
(ISR)
INTERRUPT MASK REGISTER (1MR)
INTERNAL BUS
PRIORITY
PRIORITY
RESOLVER
RESOLVER
INTERRUPT
INTERRUPT
REQUEST
REQUEST
REGISTER
REGISTER
(1RR)
(1RR)
AXIS A EOM
AXIS A EXT
AXIS B EOM
AXIS B EXT
AXIS C EOM
AXIS C EXT
The interrupts at the interrupt request input lines (IR0-IR5) are handled by the IRR and the ISR.
The IRR is used to store the interrupts requesting service, and the ISR is used to store the interrupts being serviced. Interrupts and IRR/ISR bits correspond to the format below.
Interrupt Request Register
IR6IR2IR4IR0IR7IR3IR5IR1
AXIS A EOM
AXIS A EXTERNAL (J1-J22)
AXIS B EOM
AXIS B EXTERNAL (J1-J28)
AXIS C EOM
AXIS C EXTERNAL (J1-J34)
NOT USED
Priority Resolver (PR)
The Priority Resolver (PR) block determines the priority of the bits set in the IRR. The highest
priority bit is selected and strobed into the corresponding ISR bit at the time of the poll command.
Interrupt Mask Register (IMR)
The Interrupt Mask Register stores the bits that determine the interrupt lines to be masked. The
IMR operates on the IRR. Masking a higher priority input will not affect the interrupt request
lines of lower priority. Masking disables the interrupt for the masked input.
Interrupt Output (INT)
The Interrupt Output (INT) signal indicates that the PIC has an interrupt request pending. This
signal can be routed to PC Bus interrupt IRQ2 through IRQ7 (IRQ2 default) via W8. The poll
command causes interrupt status to be placed on the bus during the next read of the PIC.
3-4Interrupt ControlModel 5000 Hardware Guide
PIC operation
Interrupt sequence, 80
The sequence of events during an interrupt when using an 80
1. One or more of the interrupt request lines (IR0-IR7) are raised high setting the corresponding
IRR bit(s).
2. The PIC evaluates these requests and sends an interrupt request to the CPU provided that
jumper W8 is installed.
3. The interrupt is acknowledged by your program interrupt service routine by writing a poll
command (OCW3) to the PIC.
4. The CPU reads the PIC to obtain the priority level as shown below. After the read, the high
ISR bit is set, and the corresponding IRR bit is reset.
Operating Mode
0D20D0D7 00D1
Table 3-1
Interrupt code
x
86/80
x
88 mode
x
86/80
x
INTERRUPT CODE
(SEE TABLE 3-1)
1: INTERRUPT HAS OCCURED
88 CPU is as follows:
D2 D1 D0Interrupt Request
0 0 0
0 0 1
0 1 0
0 1 1
1 0 0
1 0 1
1 1 0
1 1 1
Note: The interrupt code returns the highest priority
interrupt and sets the corresponding ISR bit.
5. The previous step completes the interrupt cycle. In the Automatic End-Of-Interrupt (AEOI)
mode, the ISR bit is reset on the read following the poll command. Otherwise, the ISR bit
remains set until an appropriate End-Of-Interrupt (EOI) command is issued.
End-of-Interrupt command
After the priority level is read, the ISR bit must be reset. This is done with EOI command from
the host PC, or it can be done automatically in the AEOI mode. There are two forms of the EOI
command — Specific and Non-Specific. A Non-Specific EOI command resets the highest ISR
bit of those that were set, and a Specific EOI command can be issued to reset a specified ISR bit.
IRQ0
IRQ1
IRQ2
IRQ3
IRQ4
IRQ5
IRQ6
IRQ7
Model 5000 Hardware GuideInterrupt Control3-5
Completing an interrupt
You have to provide an interrupt routine to trap IR7 interrupt glitches that appear as interrupt 7
requests. In the AEOI mode, the ISR bit for the interrupt being serviced is reset automatically at
the interrupt return in your interrupt routine.
Operating modes
Fully nested mode
This is the default mode entered after initialization unless another mode is programmed. In this
mode, interrupt requests are ordered in priority from 0 through 7 with 0 being the highest priority.
When a poll command is received and the priority level is read, the highest priority request is
placed on the data bus. The corresponding bit in the ISR is also set. It stays set until the CPU
issues an EOI command, or, if in AEOI mode, until the priority level is read. While the ISR bit is
set, all further interrupts of equal or lower priority are inhibited. Interrupts of higher priority will
issue an interrupt request (which will be acknowledged only if the PC has unmasked the interrupt).
Special mask mode
This mode is similar to the fully nested mode except that when a bit in the ISR is set, it only
inhibits interrupt requests at that level. All other unmasked interrupt requests (lower as well as
higher) are enabled.
Specific rotation (specific priority)
The default priority of interrupts is IR0 (highest) through IR7 (lowest). This can be changed
using the set priority command. This command specifies one input as having the lowest priority
and fixing all other priorities. For example, if IR2 is specified as having the lowest priority, the
priority of interrupts will be: IR3 (highest), IR4, IR5, IR6, IR7, IR0, IR1, IR2 (lowest).
Automatic rotation (equal priority)
In this mode, a device, after being serviced, receives the lowest priority. Such a device requesting an interrupt would have to wait until all other devices have been serviced.
Non-vectored mode (poll command)
The PIC must be polled for interrupt status. To do this, the poll command is written to the PIC,
and then the status is read. The PIC treats the read pulse as an INTA pulse. The interrupt is frozen from the write to the read.
3-6Interrupt ControlModel 5000 Hardware Guide
PIC programming
The PIC accepts two types of command words from the CPU — Initialization Command Words
(ICW) and Operational Command Words (OCW).
Initialization Command W ords (ICW)
Before normal operation can begin, the PIC must be brought to a starting point by a sequence of
three bytes. Figure 3-2 shows the initialization sequence. Whene v er a command is written to the
PIC low port with bit D4 = 1, it is interpreted as ICW1. Register ICW1 starts the initialization
sequence during which the following automatically occur:
1. The IMR is cleared.
2. IR7 is assigned the lowest priority.
3. The slave mode address is set to 7.
4. Special Mask Mode is cleared.
5. Status Read is set to IRR.
6. If IC4 = 0, then all functions selected in ICW4 are set.
ICW2 is not used by the 5000. However, a value must be written to it to properly initialize the
PIC. Any value may be written since the value will have no effect on PIC operation.
ICW3 is not used by the 5000.
Writing to the ICW4 completes the initialization sequence.
Figure 3-2
PIC initialization sequence
ICW1
NO
(IC4-0)
NEED
ICW4
YES
(IC4-1)
ICW4
READY TO ACCEPT
INTERRUPT REQUESTS
Note: Bit D4 set assumes the next word issued will be ICW4.
Model 5000 Hardware GuideInterrupt Control3-7
ICW1 format and description
Figure 3-3 shows the format for ICW1 and ICW4. Set the bits for the 5000 to the PIC low port in
the following manner:
D5-D7 (A7-A5): May be set or cleared. This bit has no impact on the operation of the 5000.
D2 (ADI): May be set or cleared. This bit has no impact on the operation of the 5000.
D1 (SNGL): Set this bit.
DO (IC4): If ICW4 is needed, set this bit. ICW4 is needed if the CPU is an 80
A7-A5 OF INTERRUPT VECTOR
ADDRESS (8080/8085 MODE ONLY)
ICW4 (WRITTEN TO THE PIC HIGH PORT)
D7 D6 D5 D4 D3 D2 D1
000UPM000AEOI
D0
1: 8086/8088 MODE
0: 8080/8085 MODE
×
86/80
×
88 or if
Note: Write ICW1 to the PIC low port and ICW4 to the PIC high port depending on how
you initialize.
ICW4 format and description
ICW4, written to the PIC high port, is read only if D4 of ICW1 is set. Set the data bits in the following manner:
D0 (UPM): Set this bit for operation in 8086 or 8088 mode. Clear this bit for operation in 8080
or 8085 mode.
D1 (AEOI): Set this bit for AEOI mode, and clear it for normal EOI.
1: AUTO EOI
0: NORMAL EOI
3-8Interrupt ControlModel 5000 Hardware Guide
Operation Command W ords (OCW)
These are the words that command the PIC to operate in various interrupt modes. The OCW can
be written to the PIC anytime after initialization. Figure 3-4 shows the format for OCW.
Figure 3-4
PIC OCW format
OCW1 (WRITTEN TO THE PIC HIGH PORT)
D7 D6 D5 D4 D3 D2 D1 D0
M5
M6
M7
OCW2 (WRITTEN TO THE PIC LOW PORT)
D7 D6 D5 D4 D3 D2 D1 D0
SL
H
EOI
H
EOI
SL
1 NON-SPECIFIC EOI COMMANDEND OF INTERRUPT
00
1 1 SPECIFIC EOI COMMANDEND OF INTERRUPT
0
0 0 ROTATE ON NON-SPECIFIC EOIAUTOMATIC ROTATION
1
1
0 0 ROTATE IN AUTOMATIC EOI MODE (SET)
0 0 0 ROTATE IN AUTOMATIC EOI MODE (CLEAR)
1 1 1 ROTATE ON SPECIFIC EOI COMMANDSPECIFIC ROTATION
11
0 SET PRIORITY COMMAND
0 NO OPERATION
1
0
M3
M4
0
FUNCTIONACTION
M1
M2
0
L2
M0
INTERRUPT MASK
1: MASK SET
0: MASK CLEARED
L0
LI
L0
L2 LI
0
0
0
0
IR LEVEL
0
0
0
1
1
0
1
0
1
1
1
1
11
0
1
1
2
0
3
1
4
0
5
1
6
0
7
AUTOMATIC ROTATION
AUTOMATIC ROTATION
SPECIFIC ROTATION
OCW3 (WRITTEN TO THE PIC LOW PORT)
D7 D6 D5 D4 D3 D2 D1 D0
SMM
ESMM
0
Note: Write to the OCW at any time after initialization.
1
RR
0
P
ESMM
0
1
1
RIS
RR
RIS
0
X
NO ACTION
1
0
READ IR RGTR ON NEXT RD PULSE
1
1
READ IS RGTR ON NEXT RD PULSE
SMM
SPECIAL MASK MODE
X
NO ACTION
0
RESET SPECIAL MASK
1
SET SPECIAL MASK
READ REGISTER COMMAND
1: POLL COMMAND
0: NO POLL COMMAND
Model 5000 Hardware GuideInterrupt Control3-9
OCW1 format and description
Written to the PIC high port, OCW1 sets and clears the mask bits in the Interrupt Mask Register
(IMR). M7-M0 represent the eight mask bits for IR7-IR0, respectively. M = 1 means that the
input is masked (inhibited), while M = 0 means that the input is enabled. Since IR6 and IR7 are
not used by the PIC, set M6 and M7. Reading OCW1 through the PIC high port returns the interrupts that are masked.
OCW2 format and description
The bits in OCW2, written to the PIC low port, are defined as follows:
D7 (R): Used to control all PIC rotation operations. If R is set, a form of priority rotation will be
executed depending on the operation selected.
D6 (SL): Used to select a specific level for a given operation. If set, L0-L2 are enabled, and the
operation selected will be executed on the specified interrupt level.
D5 (EOI): Used for all EOI commands (except AEOI). If set, a form of EOI will be executed.
D0-D2 (L0-L2): Designates an interrupt level (0-7) to be acted upon for the operation selected
by the EOI, SL, and R bits. L0-L2 are enabled or disabled by the SL bit.
All the possible operations by OCW2 are shown in Figure 3-4. A brief description of each is
given below.
OCW2 commands
Non-Specific EOI Command: Of the ISR bits that are set, the one with the highest priority is
cleared.
Specific EOI Command: The ISR bit specified by LO-L2 is cleared.
Rotate on Non-Specific EOI Command: Same as Non-Specific EOI, except that when an ISR
bit is cleared, its corresponding IR is assigned the lowest priority.
Rotate in AEOI: Same as Rotate on Non-Specific EOI command, except that priority rotation is
done automatically after the last INTA pulse. Setting the bit enters this mode, and clearing the
bit exits this mode.
Rotate on Specific EOI: Same as Specific EOI, except that after the specified ISR bit is cleared,
its corresponding IR is assigned the lowest priority.
Set Priority Command: The specified bit is assigned the lowest priority.
3-10Interrupt ControlModel 5000 Hardware Guide
OCW3 format and description
The bits in OCW3, written to the PIC low port, are defined according to the following:
D6 (ESMM): Enable Special Mask Mode. When set, it enables the SMM bit (see below) to set
or reset the Special Mask Mode. When ESMM is cleared, the SMM bit becomes a don't care.
D5 (SMM): Special Mask Mode. If ESMM and SMM are set, the PIC will enter the Special
Mask mode. If ESMM is set and SMM is cleared, then, the PIC will revert to normal mask
mode.
ESMMSMMMode
1
1
D2 (P): Polled Mode. If set, the next read of the PIC low port will return the highest priority
level requesting the interrupt if an interrupt has occurred. See Figure 3-3.
D1 (RR): Read Register. If set, the next read of the PIC low port will return IIR and ISR status,
depending on the RIS bit (see below). If RR is cleared, the RIS bit becomes a don't care.
1
0
Special Mask Mode
Normal Mask Mode
D0 (RIS): If P = 0, RR = 1, and RIS = 0, the next read of the PIC low port will return the IRR
status. If P = 0, RR = 1, and RIS = 1, the next read of the PIC low port will return the ISR status.
The 5000 allows the operator to change speeds during operation. By entering an appropriate
operating mode selection command involving registers FH1 or FH2, the operator can cause the
pulse output to ramp up or down to a rate different from the current rate. The contents of FH1 or
FH2 may be changed during an operation without influencing that operation and later used to
change speeds. The velocity rate may be changed on the fly an unlimited number of times.
HIGH SPEED OPERATION
WITH FH1
CHANGING FH2 DATA
HIGH SPEED OPERATION
WITH FH2
CHANGING FH1 DATA
To let the pulse-out ramp up or down to another rate after starting in the constant speed mode,
change D2 of the start command to a '1'. Enter the command before changing rate.
COMMAND BUFFER: 15h
COMMAND BUFFER: 17h
Model 5000 Hardware GuideTypical Operation ProceduresA-11
Additional operating parameters
f
f
f
DUAL RATE MODE (1)
STARTS RAMPING UP WITH RAMPING UP COMMAND
START AT CONSTANT SPEED
DUAL RATE MODE (2)
RAMPING UP/DOWN AND INTERRUPTING MODE
t
STARTS RAMPING DOWN WITH RAMP DOWN COMMAND
t
RAMPS AND INTERRUPTS
RAMPS AND CANCELS INTERRUPTS
FH1
FH2
FH1
RAMPING DOWN COMMAND
RAMPING UP COMMAND
SWITCH OF FREQUENCY REGISTER
f
HIGH SPEED BEGINNING WITH FH1
CHANGING FH1 DATA
SWITCHED TO FH1
SWITCHED TO FH2
t
t
B
Typical High Speed
Preset Mode Calculations
B-2Typical High Speed Preset Mode CalculationsModel 5000 Hardware Guide
Model 5000 Hardware GuideTypical High Speed Preset Mode CalculationsB-5
Example 2
R2 R3,
R4T
2R0
---------------- -
nT
------------------------------ -
up
R2 R3,R1–
total
f
clock
R1–
2()750()
------------------------ -
1.0()0.2()
5.0 10
-------------------------- -
0.1()
7000 500–
500–7000FH1 FH2,====
6
×
77===
R5R477==
R0
== ==
R6
------ -375P
2
f
clock
-------------- -
R7
8192n
sdPup
5.0 10
-----------------------------610===
8192()1.0()
6
×
C
PC I/O and
Interrupt Mapping
C-2PC I/O and Interrupt MappingModel 5000 Hardware Guide
PC I/O map
Table C-1 shows how the PC is typically mapped. Obviously, this list does not include every
possible type of board available. You should check the boards in your system to be certain
which addresses are used.
Table C-1
PC I/O map
Address# of BytesPCXTAT
100h to 1EFh
1F0h to 1F8h
1F9h to 1FFh
200h to 20Fh
210h to 217h
218h to 21Eh
21Fh
220h to 257h
258h to 25Fh
260h to 277h
278h to 27Fh
280h to 2AFh
2B0h to 2DFh
2E0h
2E1h
2E2h to 2E3h
2E4h to 2F7h
2F8h to 2FFh
300h to 31Fh
320h to 32Fh16.00Fixed DiskFixed DiskOpen
330h to 347h
348h to 357h
358h to 35Fh
360h to 36Fh
370h to 377h
378h to 37Fh
380h to 38Fh
390h to 393h
394h to 39Fh
3A0h to 3AFh
3B0h to 3BFh
3C0h to 3CFh
3D0h to 3DFh
3E0h to 3EFh
3F0h to 3F7h
3F8h to 3FFh
240
9
7
16
8
7
1
56
8
24
8
48
48
1
1
2
20
8
32
24
16
8
16
8
8
16
4
12
16
16
16
16
16
8
8
Write Only
Write Only
Write Only
Game Controller
Open
Open
Open
Open
Intel Above Board
Open
LPT2
Open
Alternate EGA
Open
GPIB
Data Acquisition
Open
COM2
Prototype Area
Open
DCA 3270
Open
PC Network
Open
LPT1
SDLC; Binary Synchronous Communications
Cluster
Open
Binary Synchronous Communications
Monochrome Display Adapter
Enhanced Graphics Adapter
Color Graphics Adapter
Open
Diskette Controller
COM1
Open
Open
Open
Game Controller
Expansion Unit
Open
Reserved
Open
Fixed Disk
Open
Game Controller
Open
Open
Open
Model 5000 Hardware GuidePC I/O and Interrupt MappingC-3
Table C-2 shows how interrupts are typically mapped in a PC. Check the boards in the PC to
determine exactly which interrupts are being used. The printer ports LPT1 and LPT2 hav e inter rupts available to them, but under normal operation these interrupts are not used.
Table C-2
PC interrupt map
IRQPCXTAT
IRQ2ReservedReservedIRQ9
EGA Display Adapter
PC Network
IRQ3COM2
PC Network
Binary Synchronous Communications
Cluster
SLDC
IRQ4COM1
Binary Synchronous Communications
SDLC
IRQ5Fixed DiskFixed DiskLPT2
IRQ6Floppy Disk
IRQ7LPT1
R0 = 20,000(move distance in pulses)
R1 = 200(starting speed in pulses per second)
R2 = 2,000(slew speed in pulses per second)
TR4= 0.2(acceleration time in seconds)
TR5= 0.3(deceleration time in seconds)
n = 1(1 pulse per second multiplier)
"porch"5 pulses
TR
t
5
Using the determined value n , you then calculate the values for R7, R4, R5, and R6. F or e xample,
referring to the figure above:
Model 5000 Hardware GuideSoftware Read/Write TechniqueD-3
Therefore:
R0 = 20,000(total move in pulses)
R1 = 200(base speed in pulses per second)
R2 = 2,000(top speed in pulses per second)
R3 = xxxx
(not used)
R4 = 556(acceleration in pulses per second2)
R5 = 833(deceleration in pulses per second2)
R6 = 3,323(ramp down preset in pulses)
R7 = 610(multiplier)
The value of n is derived by comparing each of the desired values of R1, R2, and R3 (if applicable) with the maximum allowable value (8,192d) for these re gisters. If an y of the desired values
exceed the maximum allowed, then the multiplier becomes:
desired value
----------------------------------------------------------maximum allowed value
For example, if you want:
R1 = 300 pps
R2 = 7,936 pps
R3 = 12,287 pps
then the multiplier is calculated as:
12287
n
-------------- -1.4998==
8192
However, it is always better to allow a little cushion and set the multiplier to a slightly higher
value — in this case, say 1.75.
The adjusted values for R1, R2, and R3 then become:
The following C code segment shows how to program the example profile using the outp() and
inp() functions for axis B.
outp (0x300, 0x20);/*access the reset register*/
outp (0x301, 0x07);/*reset axis A, B, and C*/
outp (0x300, 0x18);/*access the sync latch register*/
outp (0x301, 0x00);/*enables all axis and clocks*/
outp (0x300, 0x08);/*access the command buffer*/
outp (0x301, 0x08);/*perform a soft reset*/
B axis:
Note that the same routine is used over and over. Thus a preformatted subroutine should be used instead (a driver). However,
this was done to example the method of entering values in the
various registers using the inp() and outp() commands - not to
show software expertise.
outp (0x300, 0x08);/*access the command buffer*/
outp (0x301, 0x44);/*+ direction / preset mode*/
outp (0x300, 0x08);/*access the command buffer*/
outp (0x301, 0x80);/*point to the R0 register*/
outp (0x300, 0x09);/*get set to load LO byte*/
outp (0x301, 0x20);/*20000d = 004E20h*/
outp (0x300, 0x0A);/*get set to load MD byte*/
outp (0x301, 0x4E);
outp (0x300, 0x0B);/*get set to load HI byte*/
outp (0x301, 0x07);
outp (0x300, 0x08);/*access the command buffer*/
outp (0x301, 0x81);/*point to the R1 register*/
outp (0x300, 0x09);/*get set to load LO byte*/
outp (0x301, 0xC8);/*200d = 0000C8h*/
outp (0x300, 0x0A);/*get set to load MD byte*/
outp (0x301, 0x00);
outp (0x300, 0x0B);/*get set to load HI byte*/
outp (0x301, 0x00);
outp (0x300, 0x08);/*access the command buffer*/
outp (0x301, 0x82);/*point to the R2 register*/
outp (0x300, 0x09);/*get set to load LO byte*/
outp (0x301, 0xD0);/*2000d = 0007D0h*/
Model 5000 Hardware GuideSoftware Read/Write TechniqueD-5
outp (0x300, 0x0A);/*get set to load MD byte*/
outp (0x301, 0x07);
outp (0x300, 0x0B);/*get set to load HI byte*/
outp (0x301, 0x00);
outp (0x300, 0x08);/*access the command buffer*/
outp (0x301, 0x84);/*point to the R4 register*/
outp (0x300, 0x09);/*get set to load LO byte*/
outp (0x301, 0x0D);/*13d = 00000Dh*/
outp (0x300, 0x0A);/*get set to load MD byte*/
outp (0x301, 0x00);
outp (0x300, 0x0B);/*get set to load HI byte*/
outp (0x301, 0x00);
outp (0x300, 0x08);/*access the command buffer*/
outp (0x301, 0x85);/*point to the R5 register*/
outp (0x300, 0x09);/*get set to load LO byte*/
outp (0x301, 0xC8);/*19d = 000013h*/
outp (0x300, 0x0A);/*get set to load MD byte*/
outp (0x301, 0x00);
outp (0x300, 0x0B);/*get set to load HI byte*/
outp (0x301, 0x00);
outp (0x300, 0x08);/*access the command buffer*/
outp (0x301, 0x86);/*point to the R6 register*/
outp (0x300, 0x09);/*get set to load LO byte*/
outp (0x301, 0x51);/*81d = 000051h*/
outp (0x300, 0x0A);/*get set to load MD byte*/
outp (0x301, 0x00);
outp (0x300, 0x0B);/*get set to load HI byte*/
outp (0x301, 0x00);
outp (0x300, 0x08);/*access the command buffer*/
outp (0x301, 0x87);/*point to the R7 register*/
outp (0x300, 0x09);/*get set to load LO byte*/
outp (0x301, 0x62);/*610d = 000262h*/
outp (0x300, 0x0A);/*get set to load MD byte*/
outp (0x301, 0x02);
outp (0x300, 0x0B);/*get set to load HI byte*/
outp (0x301, 0x00);
outp (0x300, 0x08);/*access command buffer*/
outp (0x301, 0x15);/*start with FH1 SPD SEL*/
outp (0x300, 0x08);/*access the command buffer*/
CheckMoveDone:
if (inp(0x301) & 0x40) goto CheckOtherAxis;
goto NextRoutine;
CheckOtherAxis:
goto CheckMoveDone;
NextRoutine:
/*other C code here*/
/*
NOTE: if it is not required to jump to specific locations then
while (!(inp(0x300) & 0x40)) {;}
may be used
*/
E
Tech Bulletins and
Application Notes
E-2Tech Bulletins and Application NotesModel 5000 Hardware Guide
Optimizing the scale factor ,
Multiplier register R7 determines the resolution of the slew velocity registers — R2 and R3.
When the multiplier factor n is tuned properly, at maximum velocity, register R2 (and R3 if
used) is at 1FFFh.
velocity
slew
1.
Generally, stepper systems are specified with:
Total DistanceP
T otal TimeT
Acceleration TimeT
Deceleration TimeT
Start V elocityV
From these specifications, you can obtain an optimized scale factor n .
V
---------------------------- -=
n
SL
8191
PULSES
PER
SECOND
P
UP
n
tot
tot
up
dn
st
P
P
SLEW
TOT
P
DN
V
ST
T
UP
T
SLEW
T
TOT
Refer to the above figure. First, solve for total distance P
2.
P
PupP
stTup
++=
slewPdn
VsiVst–()T
----------------------------------- -+
up
V
2
++=
–T
siTtotTup
–()()VstT
dn
tot
3.
V
After simplifying and collecting like terms, you get:
1
1
-- -
4.
VsiT
P
tot
tot
-- -
Tup–
2
2
V
si
-------- -
Tdn–()
TupTdn+()–=
2
TIME SECONDS
T
DN
by finding the area under the curve:
tot
dn
VsiVst–()T
----------------------------------- -+
dn
2
Model 5000 Hardware GuideTech Bulletins and Application NotesE-3
Next, solve for Vsl , and simplify by factoring out the (
R5 (Deceleration)
R6 (Down Point)
R7 (Multiplier)
MOVE MONITORS
Pulses Left
Status / State
The actual profile will look like:
PULSES
PER
SECOND
16666.7516666.75
116661.37
AXIS A
150000
1.4
.2
.2
50000
14.53
116664.3
333306.8
333306.8
14.53218
150000
116666.5
150880
3441
8028
218
218
16665
42
AXIS B
10000
10
SINGLE AXIS MENU
.1
Active Axis: A
.15
Enter parameters
1.0
Execute single axis move
Revise Parameters
1009.581
Move Direction: UP
10045.94
RampDown Inputs: DISABLED
10045.94
Main Menu (Esc)
1.000576
10000
5
1009
498
498
51
610
AXIS C
10000
10
.1.15
1.0
1009.581
10045.94
10045.94
1.000576
10000
5
1009
498
498
51
610
49997.73
0.199950.19995
1.00005
1.39995
TIME SECONDS
E-6Tech Bulletins and Application NotesModel 5000 Hardware Guide
Using PRO5000 to back-calculate the actual physical values, we see that the actual numbers do
not exactly agree with the calculated parameter values.
CLOCK
SPEED
5 MHz
MOVE
DIRECTION
A UP
B UP
C UP
GLOBAL
CONTROL
A ENABLED
B ENABLED
C ENABLED
RAMPDOWN
INPUTS
A DISABLED
B DISABLED
C DISABLED
PROFILE ENTRY
Number of Steps
t_total
t_up
t_down
Start Rate
Multiplier
CALCULATED VALUES
Slew Rate
Acceleration
Deceleration
Multiplier
R0 (Pulse Count)
R1 (Low Speed)
R2 (High Speed)
R4 (Acceleration)
R5 (Deceleration)
R6 (Down Point)
R7 (Multiplier)
MOVE MONITORS
Pulses Left
Status / State
AXIS A
150000
1.480011062
0.199993000
0.199993000
50005.23000
14.53218000
116664.3
333306.8
333306.8
14.53218
150880
16665
AXIS B
10000
10
.1
SINGLE AXIS MENU
.1
Active Axis: A
5
Enter parameters
1.0
Execute single axis move
Revise parameters
1009.581
Move Direction: UP
10045.94
Ramp Down Inputs: DISABLED
10045.94
Main Menu (Esc)
1.000576
3441
8028
218
218
42
10000
5
1009
498
498
51
610
AXIS C
10000
10
.1.15
1.0
1009.581
10045.94
10045.94
1.000576
10000
5
1009
498
498
51
610
The differences in actual versus desired profile values are due to the floating point to inte ger conversion necessary for the registers. Also, stepper motors are only as precise as the detent resolution, and theoretical profiles may not correspond with this resolution. The only exceptions are
microstepper and nanostepper motors whose resolution approach servo precision.
The returned values in the PRO5000 Revised Parameter screen do not exactly agree with the
profile figure above due to rounding error. The optimum value for n will depend largely on the
amount of precision you need. T ypically, you will only need to calculate n to 3 decimal points of
precision, but PRO5000 will calculate to the computing precision of your computer.
For more on PRO5000, see Appendix B of the Model 5000 Software Developer's Guide.
Date:1/25/88
Schematic Revision:400088A
Board Revision: 800048A
Document Number:
Description of Change:Bypass U3-C inverter and replace U36 with 74F32. This will
improve data setup time during writes to prevent problems in
slower PCs.
Revision B
Revision C
Revision D
Date:2/19/88
Schematic Revision:400088B
Board Revision: 800048B
Document Number:
Description of Change: Corrected errors in the part list.
Date:7/20/88
Schematic Revision:400088C
Board Revision: 800048C
Document Number:
Description of Change:Replaced RP1 10Kohm resistor pack with 470 ohm pack to
increase noise immunity in address decoding.
Date:3/28/89
Schematic Revision:400088D
Board Revision: 800048D
Document Number:
Description of Change:Added 0.1uF capacitor between pins 5 and 8 of U15, U17, and
U19.
Model 5000 Hardware GuideRevision HistoryF-3
Revision E
Date:4/24/89
Schematic Revision:400088E
Board Revision: 800048E
Document Number:
Description of Change:Changed resistors R3, R4, R7, R8, R11, and
R12 to 2.2K,
1
W, 5%.
/
4
Revision F
Date:2/20/90
Schematic Revision:400088F
Board Revision: 800048F
Document Number:
Description of Change:PC board re-layed out. Removed all BUS CAP strips from
PC board. Added 19-0.1uF capacitors between +5V and
ground. Added 3-1.0uF capacitors C32 to C34. Other
miscellaneous resistor changes.
Revision G
Revision H
Date:11/12/90
Schematic Revision:400088G
Board Revision: 800048G
Document Number:
Description of Change:Miscellaneous part number change.
Description of Change:Changed connector J1 from plastic Dsub to metal Dsub.
G
Introduction to
the Model 9011
Motion Simulator
•
•
•
•
•
G-2Introduction to the Model 9011 Motion SimulatorModel 5000 Hardware Guide
Features
Powered by an external or internal supply.
Simulates:
Analog ±10VDC servo motor/amplifier packages with or without encoder feedback
Pulse Width Modulated ±PWM servo motor/amplifier packages with or without encoder
feedback.
+PWM with Direction bit servo motor/amplifier packages with or without encoder feedback.
Stepper motor translator packages using step and direction with or without encoder feedback.
Single ended or differential quadrature encoders with index pulse.
Operates in open or closed loop fashion.
Functions as a battery box to drive analog and PWM servo systems or stepper motor control
packages.
Visual representation of encoder signals and motor rotation.
Compact size: 6 × 4 × 2 inches.
Screw terminals for easy connection.
Application
The Model 9011 Motion Simulator is a tool designed to assist you in the development, debugging, or troubleshooting of motion control systems.
General description
The 9011 allows you to test system software and/or motion control hardware (controller, motor/
amplifier, encoder). It is designed to be a fully functional and integral part of your test and
debug operations. Its usefulness is limited only by your imagination. An important point to
consider is that, by using the 9011, motion control software can be tested off line. Testing software off line can prevent the prospect of machine catastrophes due to software bugs. Also, the
9011 gives you the flexibility of writing and testing your software prior to receiving the motor,
amplifier, and encoder hardware. In many cases, it is not possible to test the motor hardware in
the confines of your lab. Using the 9011 simulator box just once in the dev elopment, deb ugging,
or troubleshooting of your system will generally justify your investment in this product.
T echnical specifications
Power:External +5VDC to +15VDC (from the unit under test)
Internal +6VDC (4 AA cells)
50mA current draw, maximum
Bandwidth:488Hz
Encoder:256 counts-per-revolution
Index located at the zero count position
A/D threshold:50mVDC
Dimensions:6 × 4x2 inches
Inertia (J):Can be controlled by use of RLC networking
Model 5000 Hardware GuideIntroduction to the Model 9011 Motion SimulatorG-3
Operation
The unit is operated by a four position function switch. The ENCODER OUTPUT control (right
hand control) adjusts the encoder signal frequency when the function switch is in the
ENCODER position. Sixteen LEDs arranged in a circle, will light in a clockwise or counterclockwise manner to simulate motor rotation. The quadrature encoder output is annunciated by
three LEDs labeled A, B, and Z (Index), corresponding to the phase assignments of each.
A Phoenix screw-terminal connector is provided to allow you to connect the 9011 to your system as your application dictates. You may connect external power to the 9011 ranging from
+5VDC to +15VDC, or for portability you may jumper the BAT OUT terminal to the +5V IN
terminal.
You may connect the 9011 simulator to your system in a variety of ways (refer to the connection
figures).
Servo systems
With the function switch in the ± SIGNAL position, the 9011 will accept analog or ±PWM signals. In the PULSE/DIRECTION position, the simulator will accept a +PWM or –PWM signal
with a direction bit. When using –PWM signals with a direction bit, the high inactive state voltage of the –PWM signal must be connected to REF PWR on the screw terminal.
To close the loop, the internal encoder provides differential quadrature feedback available at the
screw terminal. Motor rotation and encoder pulsing will be displayed directly on the 9011. Figures G-1 through G-6 show various ways to connect the 9011 into a system.
Stepper systems
To simulate a stepper system, place the function switch in the PULSE/DIRECTION position.
Connect the stepper pulse to either the active high or active low pulse terminal and connect the
direction input to DIR IN. (See Figures G-1 to G-6.) To close the loop, connect the differential
quadrature feedback from the 9011 to the controller.
Encoders
Selecting ENCODER on the function switch allows you either to simulate an encoder or to operate the 9011 as a battery box . Using the 9011 as a battery box enables you to drive external analog, PWM, or stepper motor systems open loop. To simulate analog, obtain the analog signal
from the ANA OUT terminal. Rotating ENCODER OUTPUT will cause the analog output voltage to change accordingly. DIR O and encoder outputs — A, B, and Z — provide pulse and
direction signal information for stepper and some restricted PWM operations. When testing
encoders, place the function switch to the PULSE/DIRECTION position, and apply each
encoder signal (one at a time) to the stepper pulse inputs, active high to pulse high and active
low to pulse low.
Pulse High Pulse Low
When the encoder under test is rotated, the simulator LEDs will also rotate.
G-4Introduction to the Model 9011 Motion SimulatorModel 5000 Hardware Guide
Pin assignments
Table G-1 describes the connections to the 9011 through a 24-terminal Phoenix connector. The
connector assignments are shown in table G-1.
T able G-2 and figures G-1 to G-6 show how to hook the 9011 in a variety of applications. In the
following figures, dotted lines show alternate connections.
Table G-1
Model 9011 connector definitions
NameDefinition
+5V IN5VDC from external source
+15V IN5-15VDC from external source
BAT OUTInternal 6VDC for portable operation
PWR RETExternal power supply return or COM
±SIG INAnalog or ± PWM signal input
REF PWR/WOM ref (active low state voltage)
/PWM IN–PWM input signal
PWM IN+PWM input signal
DIR INDirection signal input for PWM or stepper
COM†Signal common
Active LOW stepper pulse input signal
Active HIGH stepper pulse input signal
COM†Signal common
DIR ODirection signal output (TTL)
ANA OUTAnalog output (0 to 5VDC)
A OUTEncoder phase A output (TTL)
/A OUTEncoder phase /A output (TTL)
COM†Signal common
B OUTEncoder phase B output (TTL)
/B OUTEncoder phase /B output (TTL)
COM†Signal common
Z OUTEncoder phase Z output (TTL)
/ZOUTEncoder phase /Z output (TTL)
COM†Signal common
†All COM signals are electrically equivalent.
Model 5000 Hardware GuideIntroduction to the Model 9011 Motion SimulatorG-5
Signal Connect SignalConnectSignalConnectSignalConnectSignal Connect
+DAC±SIG IN +PWM ± SIG IN PWMPWM IN PULSE IN A A
–DACCOM-PWM COM/PWM/PWM IN /PULSE IN/A/A
PWMCOMBB
COMDIR INDIRECT'NDIR IN/B/B
DIRECT'NCOMCOMMONCOMZZ
DIR COM/Z/Z
Figure G-1
Analog or ±PWM application
SERVO CONTROLLER
Z
AB
+
COM
DIR O
A OUT
ANA OUT
CWCWW
ENCODER OUTPUT
ENCODER
IN
COM
COM
B OUT
Z OUT
/B OUT
/A OUT
MODEL 9011
MOTION SIMULATOR
CCW
/Z OUT
OFF
CW
COM
ANALOG or-PWM
COMMAND
SIGNAL
OUT
JUMPER FOR
INTERNAL
EXT.
POWER
Note: This configuration simulates a closed loop system (amplifier/motor/encoder).
POWER
+5V IN
+15V IN
PWR RET
BAT OUT
+/- SIG IN
TECHNOLOGY 80 INC.
OFF
+/-SIGNAL
PULSE/DIRECTION
ENCODER
PWM IN
REF PWR
/PWM IN
COM
DIR IN
G-6Introduction to the Model 9011 Motion SimulatorModel 5000 Hardware Guide
Figure G-2
Pulse and direction
SERVO CONTROLLER
PWM w/DIRECTION BIT
JUMPER FOR
INTERNAL
EXT.
POWER
POWER
+5V IN
TECHNOLOGY 80 INC.
+15V IN
PWR RET
BAT OUT
OFF
+/-SIGNAL
PULSE/DIRECTION
ENCODER
COMMAND SIGNAL
+ DIR
COM
DIR IN
PWM IN
REF PWR
/PWM IN
+/- SIG IN
COM
Z
A
B
ENCODER
DIR O
COM
A OUT
/A OUT
ANA OUT
MODEL 9011
MOTION SIMULATOR
CWCWW
CCW
ENCODER OUTPUT
IN
B OUT
COM
/B OUT
OFF
Z OUT
/Z OUT
CW
COM
Note: You can simulate a pulse and direction closed loop system.
Figure G-3
Using the 9011 to isolate encoder problems
OFF
CCW
CW
COUNTER
JUMPER FOR
INTERNAL
EXT.
POWER
POWER
+5V IN
+15V IN
PWR RET
BAT OUT
+/- SIG IN
TECHNOLOGY 80 INC.
OFF
+/-SIGNAL
PULSE/DIRECTION
ENCODER
PWM IN
REF PWR
/PWM IN
COM
DIR IN
COM
DIR O
Z
A
B
COM
B OUT
A OUT
/A OUT
ANA OUT
MODEL 9011
MOTION SIMULATOR
CWCWW
CCW
ENCODER OUTPUT
COM
/B OUT
OFF
Z OUT
/Z OUT
CW
COM
Note: You can substitute the 9011 for an encoder. The ENCODER OUTPUT control varies the rate of count.
Model 5000 Hardware GuideIntroduction to the Model 9011 Motion SimulatorG-7
Figure G-4
Stepper system
STEPPER MOTOR
CONTROLLER
ENCODER FEEDBACK
COM
DIR O
A OUT
ANA OUT
CWCWW
ENCODER OUTPUT
COM
COM
Z OUT
/Z OUT
CW
COM
B OUT
/B OUT
/A OUT
MODEL 9011
MOTION SIMULATOR
OFF
CCW
JUMPER FOR
INTERNAL
POWER
+5V IN
+15V IN
PWR RET
BAT OUT
+/- SIG IN
TECHNOLOGY 80 INC.
OFF
+/-SIGNAL
PULSE/DIRECTION
ENCODER
PULSE DIRECTION
PWM IN
REF PWR
/PWM IN
COM
DIR IN
Z
A
B
Note: This configuration shows a 9011 closing the loop in a stepper motor system.
Figure G-5
Driving a servo amplifier
JUMPER FOR
INTERNAL
EXT.
POWER
POWER
TECHNOLOGY 80 INC.
+5V IN
+15V IN
REF PWR
PWR RET
BAT OUT
+/- SIG IN
OFF
+/-SIGNAL
PULSE/DIRECTION
ENCODER
SERVO DRIVE
ANALOG
- +
COM
COM
DIR IN
PWM IN
/PWM IN
DIR O
Z
AB
D5-VDC
COM
A OUT
/A OUT
ANA OUT
MODEL 9011
MOTION SIMULATOR
CWCWW
CCW
ENCODER OUTPUT
TO
MOTOR
COM
B OUT
Z OUT
/B OUT
OFF
CW
COM
/Z OUT
Note: The 9011 can be used (as a battery box ) to provide the command to a servo system.
G-8Introduction to the Model 9011 Motion SimulatorModel 5000 Hardware Guide
Figure G-6
Driving a stepper motor system
BI-DIRECTIONAL
MOTOR
COM
/Z OUT
TO
JUMPER FOR
INTERNAL
EXT.
POWER
POWER
+5V IN
TECHNOLOGY 80 INC.
+15V IN
PWR RET
BAT OUT
OFF
+/-SIGNAL
PULSE/DIRECTION
ENCODER
REF PWR
/PWM IN
+/- SIG IN
STEPPER MOTOR
TRANSLATOR
COM
COM
Z
AB
DIR O
A OUT
ANA OUT
CWCWW
ENCODER OUTPUT
DIR IN
PWM IN
COM
COM
B OUT
Z OUT
/B OUT
/A OUT
MODEL 9011
MOTION SIMULATOR
OFF
CCW
CW
Note: The 9011 can be used to provide the bi-directional command for a stepper motor system.
H
Circuit Diagrams
H-2Circuit DiagramsModel 5000 Hardware Guide
Index
A
Additional operating parameters A-11
Addressing an onboard port 2-3
Application G-2
Automatic rotation (equal priority) 3-5
C
Circuit diagrams H-1
Command buffer 2-6
Common applications for the Model 9011 G-5
Completing an interrupt 3-5
Connector pinouts 1-8
Constant speed continuous mode A-7
Constant speed preset mode A-5
Constant speed return to home A-9
Control mode selection 2-8
D
Data register selection 2-9
Description of interrupt control 3-2
Description of the 5000 1-2
Determine R2 to R7 from given values B-3
G
General description G-2
H
High speed continous mode A-6
High speed preset mode A-4
High speed return to home A-8
I
ICW1 format and description 3-7
ICW4 format and description 3-7
Initialization Command Words (ICW) 3-6
Initialization flow chart A-2
Installation 1-3
Interrupt control 3-1
Interrupt Mask Register (IMR) 3-3
Interrupt Output (INT) 3-3
Interrupt Request Rgtr (IRR), In-Service Rgtr (ISR) 3-3
x
86/80
x
Interrupt sequence, 80
Introduction and installation 1-1
Introduction to the Model 9011 motion simulator G-1
88 mode 3-4
E
Encoders G-3
End-of-Interrupt command 3-4
Example 1 B-4
Example 2 B-5
F
Features G-2
Fully nested mode 3-5
L
Loading the Axis A counter 2-2
N
Non-vectored mode (poll command) 3-5
i-1
O
OCW1 format and description 3-9
OCW2 format and description 3-9
OCW2 commands 3-9
OCW3 format and description 3-10
Operating mode selection 2-6
Operating modes 3-5
Operation G-3
Operation and programming 2-1
Operation Command Words (OCW) 3-8
Optimizing the scale factor, n E-2
Output mode selection 2-10
P
PC I/O and interrupt mapping C-1
PC I/O map C-2
PIC operation 3-4
PIC programming 3-6
Pin assignments G-4
Port locations 2-3
Power 1-3
Priority Resolver (PR) 3-3
Programming 2-4
T
Tech bulletins and application notes E-1
Technical specifications 1-2, G-2
Theory of operation 2-2
Typical high speed preset mode calculations B-1, B-2
Typical operation procedures A-1
U
User-accessible registers 2-11
W
W7, board base address 1-3
W9 to W11, clock speed select 1-5
W8, interrupt select 1-6
W1 to W6, opto power (bus) 1-7
Writing the controller internal registers 2-4
Writing to an onboard port 2-4
R
Reading from an onboard port 2-4
Reading the state buffer 2-5
Reading the stepper controller status port 2-5
Register descriptions 2-11
Reset latch 2-6
Revision/ F-2
Revision A F-2
Revision B F-2
Revision C F-2
Revision D F-2
Revision E F-3
Revision F F-3
Revision G F-3
Revision H F-3
Revision history F-1
S
Servo systems G-3
Setting speed data A-3
Software read/write technique D-1, D2
Special mask mode 3-5
Specific rotation (specific priority) 3-5
Speed change during operation A-10
Stepper systems G-3
Sync latch 2-5
i-2
Service Form
Model No.Serial No.Date
Name and Telephone No.
Company
List all control settings, describe problem and check boxes that apply to problem.
Intermittent
❏
❏
IEEE failure
Front panel operational
❏
Display or output (check one)
Drifts
❏
Unstable
❏
❏
Overload
❏
Calibration only
Data required
❏
(attach any additional sheets as necessary)
Show a block diagram of your measurement system including all instruments connected (whether power is turned on or not).
Also, describe signal source.
Analog output follows display
❏
❏
Obvious problem on power-up
All ranges or functions are bad
❏
Unable to zero
❏
Will not read applied input
❏
❏
CertiÞcate of calibration required
Particular range or function bad; specify
❏
❏
Batteries and fuses are OK
Checked all cables
❏
Where is the measurement being performed? (factory, controlled laboratory, out-of-doors, etc.)
What power line voltage is used?Ambient temperature?¡F
Relative humidity?Other?
Any additional information. (If special modiÞcations have been made by the user, please describe.)
Be sure to include your name and phone number on this service form
.
Keithley Instruments, Inc.
28775 Aurora Road
Cleveland, Ohio 44139
Printed in the U.S.A.
Loading...
+ hidden pages
You need points to download manuals.
1 point = 1 manual.
You can buy points or you can get point for every manual you upload.