Beruflich Dokumente
Kultur Dokumente
On-chip Analog Comparator. Gives you another • Keep yourself connected to earth via ground
way to work with analog inputs. This circuit will tell the wrist strap.
controller if the measured input is above or below a • Never work on plastic furniture.
preset analog voltage. • Keep your table free from unnecessary clutter.
• Keep your components inside ESD shielding
IRDA Encoder/decoder. The UPRC has an optional containers until the moment these are installed.
IRDA circuit that will allow you to communicate and Do not store your components inside ordinary
exchange data with similarly equipped devices. plastic bags and containers.
More on ESD :
ZDS II Development Environment. Zilog generously
http://www.e-gizmo.com/ARTICLES/ESD/ESD1.HTM
made this C and Assembly language development
software free to zilog Encore! Users. The download
package includes comprehensive manuals and Heatsink may be required on IC LB1847 if the
sample programs. Visit Zilog site www.zilog.com for motor driver is operated with heavy loads. Indica-
details. tion that heatsink is needed is when LB1847 runs
too hot to touch during operation, or if the driver
shuts down.
Page 2 Universal Programmable Robot Controller UPRC
JP1 JP4 JP2
+3.3v
+3.3v
+3.3v
PC3
PC1
PA3
PA1
PA7
PA5
* See text for a complete desciption of I/O ports
GND
GND
GND
PC2
PC0
PA2
PA0
PA6
PA4
DC INPUT
JP5
JP3
DEBUGGING CABLE INPUT
RESET BUTTON
R11- PWM
MOTOR CURRENT
OUTA
OUTA
OUTB
+5V OUT
GND
OUTB
+Vmotor
MGND
Figure 2. UPRC has 12 I/Os available for user applications. The I/Os are terminated by modular connec-
tors, making access to these ports fast and easy. Screw terminals are used for the motor drive circuit
because of the relatively large amount of current passing through these points.
PIN DESCIPTION
The Z8F082A Encore! XP has plenty of on-chip JP3 – Dongle (Programming Cable)
peripherals. Making these peripherals available to Pin 1 : +3.3V
users on a DIP package with only 20 pins obviously Pin 2 :GND
presents a design challenge. Zilog’s solution is for Pin 3 : OCD – On chip Debugger pin, used
each peripheral to share pins with the others. Hence by ZDS II PC development environment to
in the following pin descriptions, you will find most program and debug and program the chip in-
of the pins having two, three, or even four possible circuit.
functions. Take JP1 pin 2 pin as an example. It is
labeled as PC0/ANA4/CINP/LED. This means it JP1 – User I/O
can be configured take the function of a logic input Pin 1: +3.3V
or output PC0, or an ADC analog input ANA4, or a Pin 2: PC0/ANA4/CINP/LED
comparator input CINP, or a LED direct drive output Pin 3: PC1/ANA5/CINN/LED
PC0. This scheme, unfortunately, prevents us from Pin 4: PC2/ANA6/LED
using all available peripherals at the same time. Pin 5: PC3/COUT/LED
Pin 6: GND
PA4..PA7
General purpose logic input/output, 5V tolerant
(note 1)
RXD0
This guide assumes that you are already familiar with The UPRC requires two power supply, one that
Z8 Encore! Microcontroller chip. Detailed discussion powers the controller circuit, and a separate one that
of the chip’s architecture and programming is beyond powers the motor driver circuit. You can operate the
the scope of this document. Zilog’s site www.zilog.com controller without the motor driver power supply if you
contains a wealth of information detailing everything do not intend to use the motor circuit.
you need to know about this chip, from specifications
to application examples. Power to the controller is supplied via the DC jack. You
can use power supply or battery voltage ranging from
Highly recommended readings is
7.5V to 9V DC. Current consumption is low, it typically
a book entitled Designing with Z8
drains less than 100mA, but actual consumptions may
Encore! Microcontroller, written by
vary depending on the gadgets that you connect with
authors Dr. Luis Sison and Prof.
the board.
Osmonn Burgos of U.P. Diliman. This
book is written in tutorial style and
The motor driver can accept DC power input up to
contains numerous exercises that
24VDC. If you are using the driver circuit to control
will make it easy for you to learn and
DC motors, you should use a supply voltage slightly
master the Encore! chip. This book is published by
higher than the motor rating to compensate for losses
Alexan Commercial and is available through Alexan
on the driver circuitry. If you are to drive a stepping
chain of stores.
motor in PWM mode, then use 24VDC.
motor A
motor B
Figure 3. Wiring guide for the UPRC. The controller uses two separate supplies, one
feeds the controller, and the other powers the motor system.
© 2007 e-Gizmo Mechatronix Central Page 5
Connecting a Debugging Cable
x- don’t care
The motor can then be run by sequencing PB0 to PB3 Figure 8. Even six-wire unipolar stepping motors will work
as shown in table 3: with the motor driver circuit. Leave the center tap con-
nections of each motor coil unconnected.
COM Port
Debugging
Cable
PC running
Zilog’s ZDS II
development envi-
UPRC ronment
Universal Programmable
Robot Controller
PC with Microsoft Windows XP, Windows 2000 SP4 The programming and debugging setup is fairly
or Windows 98 SE/ME. Zilog recommends a PC host simple. Just connect the debugging cable PC end
running on a Pentium III or higher processor, with at to a PC COM port, and the other end to the UPRC
least 128MB RAM. UPRC debugging cable requires module, and you can immediately start programming
one serial port (COM port), make sure your PC have and debugging your Universal Programmable Robot
it. You can use a USB to COM converter cable if you Controller system.
need to, just ready yourself to the extra fiddling that
may be required to get your system to work with it. APPLICATION IDEAS
Zilog’s ZDS II development environment. This There are many things you can do with the UPRC,
freeware package contains everything you need to bounded only by your imagination. The following
program and debug the Encore! chip. This includes the pages illustrates some example applications you can
editor, C compiler and assembler. You can download work with your UPRC.
their latest version from www.zilog.com.
Note: Although the figures does not show the power
Debugging cable. This allows you to connect the supply connections of the UPRC, you are not smart if
UPRC to your PC during the programming and you omit these in your actual setup.
debugging session.
Figure 13. Suggested UART wiring scheme. Three GND lines shields
the signal lines Rx and Tx to keep the system resistant to externally
introduced noise.