The Intel® Galileo is an increasingly popular embedded development board, which is rich in digital and analog I/O interfaces including I2C, SPI, PWM, ADC and up to 20 GPIO pins. For applications requiring more GPIO pins, we have designed and produced the Emutex 56-pin GPIO Expander Shield.

 

Creator: Dan O'Donovan

 

1. Introduction

The GPIO expander is based on a pair of MAX9657 GPIO expander chips from Maxim Integrated. It takes the form of a standard Arduino Uno shield, and plugs directly onto an Intel® Galileo or a number of Arduino base boards.  A 4-wire SPI interface is used for communication between the main board and the shield.  Using a standard Arduino sketch application, the user can toggle any or all of the output pins on the expander on and off.  Since only 4 of the 20 pins on the Arduino shield interface are needed to control the shield, 16 pins are available for use as GPIO thus allowing a combined total of 72 GPIO pins. This allows for a versatile set of uses, such as controlling an 8x8x8 LED cube.

 

2. The Hardware

The expander shield was designed in-house at Emutex using the excellent FreePCB application.  The board is a 2-layer PCB, with the following features:

  • 2 MAX9657 ICs (36-pin SSOP package) connected in a daisy-chain configuration
  • Standard Arduino Uno shield pin layout, allowing the shield to plug directly onto an Intel Galileo or Arduino Uno or any other Arduino-style board with this interface
  • 2 banks of double-row 0.1"-spaced pin headers for the GPIO outputs, conveniently designed to allow standard ribbon cables to be used to connect the GPIO outputs to an external board. (Hint: this a great use for old IDE hard-drive cables)
  • selectable 3.3V or 5V voltage source. This allows it to be connected to 3.3V or 5V Arduino boards, and also allows the user to choose to have 3.3V or 5V logic voltage levels on the GPIO outputs

 

2.1 PCB Layout

The PCB layout is shown below:

 

2.2 PCB Layout source file

The PCB design is available to download from here:
https://github.com/emutex/Emutex_MAX6957_Library/blob/master/PCB/gpio-expand-shield.fpc

 

3. The Software

An Arduino software library was created to simplify the usage of the GPIO Expander Shield.  Designed to be imported easily into the Arduino IDE, and written to work with the Intel Galileo or any standard Arduino board, the library allows the user to get up and running with the shield in minutes.

The source code is made freely available by Emutex on GitHub:
https://github.com/emutex/Emutex_MAX6957_Library

Some notable features of the library include:

  • An option to set each pin immediately, or defer to allow batching of pin updates to maximise efficiency
  • Support for either of the 2 output driver modes available on the MAX6957, which are:
    • GPIO Output mode
    • Constant-Current LED Display Driver mode

  • Allows the user to disable the MAX6957 outputs when not in use, to reduce power consumption

Support for GPIO Input modes is not currently included in the library.  However, the API is designed to accommodate this easily in the future, if needed.

 

4. Bringing it together

A small volume batch of initial PCBs were created using the excellent OSH Park PCB manufacturing service. Two MAX6957s were hand-soldered to the PCB in our lab at Emutex, along with the other passive components required. The full Bill-Of-Materials is as follows:

 

 Item  Quantity  Source
 Emutex 56-Pin GPIO Expander PCB  1  Emutex / OSH Park
 MAX6957 SSOP-36 package  2  Mouser
 47nF ceramic capacitor (through-hole)  2  Maplin
 39k 0.25W resistor (through-hole)  2  Maplin
 Arduino stackable header kit  1  Sparkfun
 40-pin break-away headers  2  Sparkfun

 

As part of the initial testing, two PCB design issues were found:

  1. One of the GPIO outputs from the MAX6957’s was left unconnected.  We soldered a wire on the board to join up that output to the corresponding header pin.
  2. Two trace lines were intersecting.  We cut one of these and re-routed with a wire on the board.
  3. Also, it was observed that using the IOREF pin would be a more optimal choice to provide the source voltage for the board, to avoid possible mismatch in the configuration of the main board and the shield.

All of these points have been addressed in the final PCB design version shown earlier.

 

5. The Result

5.1 Emutex 56-Pin GPIO Expander installed on Intel Galileo

The image below shows the completed Emutex 56-Pin GPIO Expander installed on Intel® Galileo:

 

5.2 Gallery

 

6. Conclusion

This expander board was developed as a proof-of-concept for a particular application we were working on.  Depending on the level of interest in this particular board, the following enhancements may be considered for a future revision:

  • Extend the Arduino library to support GPIO input modes
  • Optimise performance of the library for faster GPIO toggle rates
  • Create a stackable design to allow multiple GPIO expanders to be stacked for even more I/Os
  • Improve the PCB layout to re-order the output pins in a linear arrangement according to pin number

The PCB design and the Arduino library are made available under an open source license.  Please feel free to use them and enhance them.  If you find them useful, please let us know - we’d love to hear from you!

1 1 1 1 1 1 1 1 1 1 Rating 0.50 (1 Vote)

Comments  

HP Drivers
0 #1 HP Drivers 2015-02-07 14:05
Hɑving read this ӏ believed it was very enlightening.

I appreciate you spending some time and effort to put thіs informatіve article together.
I once again find myself personally spending a lot of time both reading and commenting.
But so what, it was still worth it!
Quote

Add comment