MIKROE-415 mikroElektronika, MIKROE-415 Datasheet - Page 25

Development Boards & Kits - AVR EASYAVR6 DEVELOPMENT SYSTEM

MIKROE-415

Manufacturer Part Number
MIKROE-415
Description
Development Boards & Kits - AVR EASYAVR6 DEVELOPMENT SYSTEM
Manufacturer
mikroElektronika
Datasheet

Specifications of MIKROE-415

Tool Type
AVR Development Board
Interface Type
RS-232, USB, JTAG UART
Dimensions
265 mm x 220 mm
Operating Supply Voltage
9 V to 32 V
Lead Free Status / Rohs Status
 Details
EasyAVR6 Development System
EasyAVR6 Development System
20.0.
20.0. Port Expander
The SPI communication lines and MCP23S17 circuit provide the EasyAVR6 development system with a means of increasing the
number of available I/O ports by two. If the port expander communicates to the microcontroller over the DIP switches SW6 and SW7,
then the microcontroller pins used for SPI communication cannot be used as I/O pins. Switches INTA and INTB on the DIP switch
SW9 enable interrupt used by MCP23S17.
The microcontroller communicates to the port expander (MCP23S17 circuit) using serial communicaion (SPI). The advantage of such
communication is that only four lines are used for transmitting and receiving data simultaneously:
MOSI
MISO
SCK
CS
Data transfer is performed in both directions simultaneously by means of MOSI and MISO lines. The MOSI line is used for transferring
data from the microcontroller to the port expander, whereas the MISO line transfers data from the port expander to the microcontroller.
The microcontroller initializes data transfer when the CS pin is driven low (0V). It causes the microcontroller to send clock signal (SCK)
and therefore starts data exchange.
Figure 20-3: SPI communication block diagram
The principle of operation of the port expander’s ports 0 and 1 is almost identical to the operation of other ports on the development
system. The only difference here is that port signals are received in parallel format. The MCP23S17 converts such signals into serial
format and sends them to the microcontroller. The result is a reduced number of lines used for sending signals from ports 0 and 1 to
the microcontroller.
Jumper for selecting
pull-up/pull-down resistor
DIP switch connecting port
expander to the microcon-
troller
AVR MCU
Port Expander (Additional Input/Output Ports)
Master
- Master Output, Slave Input (microcontroller output, MCP23S17 input)
- Master Input, Slave Output (microcontroller input, MCP23S17 output)
- Serial Clock (microcontroller clock signal)
- Chip Select (enables data transfer)
SPI
MOSI
MISO
SCK
CS
output
Serial
Figure 20-1: Port expander
(Additional Input/Output Ports)
MOSI
MISO
SCK
CS
EXPANDER
MCP23S17
SPI Slave
PORT
Parallel
input
8bit
8bit
PORT0
PORT1
PORT0
PORT1
Jumpers J19 are used to determine the port expander’s
hardware address. They are also used to provide the port
expander’s pins A2, A1 and A0 with a logic 1 or a logic
0. Jumpers J19 are set in the Down position (logic 0) by
default.
Figure 20-2: DIP switches SW6 and SW7
when port expander is enabled
MikroElektronika
25

Related parts for MIKROE-415