User manual

Code Mercenaries
9
II
II
OO
OO
--
--
WW
WW
aa
aa
rr
rr
rr
rr
ii
ii
oo
oo
rr
rr
4.2 Pin descriptions
D+, D-
Differential data lines of USB. Connect these
signals direct to a USB cable. D- requires a pull up
resistor, see application circuit for details.
For a PCB layout make sure to run these two
signals next to each other. USB data is a
differential signal that produces best signal quality
and lowest RF emission if the two lines are close to
each other.
P0.0..P0.7
First I/O port of the chip. These pins correspond
with the lowest 8 bits of the input or output (bits
0..7).
On IOW40 P0.0 serves the double purpose of
determining the power mode of the chip. To set the
desired power mode P0.0 must be pulled high or
low using a 100k resistor (or less). IO-Warrior40
reads the status on this pin after a reset prior to
enabling the internal pull up resistor.
A high on P0.0 on reset sets the high power mode,
this means the IO-Warrior40 will report as a high
power, bus powered device drawing up to 500mA.
Pulling P0.0 low on reset sets the low power mode
specifying 100mA maximum power draw.
P1.0..P1.7
Second I/O Port. Corresponds to the bits 8..15.
P2.0..P2.7 (IOW40 only)
Third I/O Port. Corresponds to the bits 16..23.
P3.0..P3.7 (IOW40 only)
Fourth I/O Port. Corresponds to the bits 24..31.
P3.7 does need to be pulled high with a
100kresistor on power up. This is necessary for
proper function of the chip.
P3.0..P3.7 have sufficient current sinking
capability to directly drive LEDs.
Pull to GND
This pin is used during production of the IO-
Warrior chips, connect to GND.
XOut, XIn (IOW40 only)
Connection for external oscillator. A 6MHz
ceramic resonator should be connected here, no
additional components necessary.
Using a crystal results in unstable operation as the
oscillator is optimized for use with ceramic
resonators.
An external 6MHz clock may be connected to XIn,
XOut has to be left floating in this case.
GND
Power supply ground.
Vcc
Supply voltage.
A 100nF ceramic capacitor is required to be
connected directly to the power supply pins. The
two ground pins of IO-Warrior have to be
connected in the shortest possible way, no other
considerations may have any precedence over this.
Vreg (IOW24 only)
Regulated 3V output, to be used only for the
purpose of powering the USB D- pull up resistor.
Do not use this pin as a supply for any other circuit
than the pull up resistor.
Power (IOW24 only)
Input to set the power mode. The status of the pin
is checked only at power up and bus reset. Pulling
this pin to high sets high power mode, this means
the IO-Warrior24 will report as a high power, bus
powered device drawing up to 500mA. Pulling
Power low on reset sets the low power mode
specifying 100mA maximum power draw.
4.3 Special mode pin functions
IO-Warrior supports driving IIC compatible chips
and HD44780 compatible display modules and
some other display modules direct. IO-Warrior24
does also have a SPI interface. Handling IIC via
the normal generic I/O would be very slow as each
edge of data and clock would have to be
transmitted separately. At a rate of 125 such
transactions per second (which is about the
maximum IO-Warrior is allowed by USB
specifications) the maximum bit rate would be
around 30 bits/sec.
To make IIC and other devices usable IO-Warrior
implements the special mode functions. By
handling the IIC inside IO-Warrior the actual data
rate is increased to about 6000 bits/sec or 750
bytes/sec.
When any of the special mode functions is
activated a couple pins will no longer respond as
generic I/O pins but are under control of the
activated special mode function.
V 1.1.0, December 2nd 2013, for chip revision V1.0.3.0 and up