Hardware Overview
In this section, we will highlight the hardware and pins that are broken out on the SparkFun Qwiic Directional Pad. For more information, check out our Resources and Going Further on the components used on the breakout board.
Power
To power the board, you will need 3.3V. You can connect a Qwiic cable to Qwiic connector on either side of the board or you can solder directly to the PTHs. Below are the power pins that are broken out on the edge of the board.
- 3V3 — This pin is the voltage input for the board. The recommended input voltage for this pin is 3.3V.
- GND — Of course, is the common, ground voltage (0V reference) for the system.
Power and Ground Highlighted - Top View | Power, Ground, and Qwiic Connector Highlighted - Bottom View |
5-Way Directional Pad
A low profile 5-way directional pad is populated on the top side of the board. These buttons are small! We recommend using your fingernail when pressing down on a button. Each pad includes a momentary push button that is read by the PCA9554 8-bit I2C I/O expander that is populated on the bottom of the board.
Note
We recommend pressing only one button at a time! For example, if the UP button is pressed down, it will register the UP button being pressed down first due to the way the condition statements are written in the Arduino code. Once the UP button is released, the board will be able to read another button press. However, if the LEFT button is pressed and then the UP button is pressed, the Qwiic Directional Pad will register the UP button.
PCA9554 8-bit I2C I/O Expander
The TI PCA9554 that is populated on the bottom side of the board is an 8-bit I2C I/O expander that enables users to read and write to the following GPIO pins through I2C. It is used to read the 5-way directional pad or write to the non-addressable RGB LED. The I2C address of the PCA9554 is set to 0x20 by default. By adjusting the jumpers on the back of the board, the alternative address can be any value between 0x21 to 0x27.
- GPIO0 — GPIO0 is connected to the 5-way directional pad's UP button. A 10kΩ pull-up resistor is connected.
- GPIO1 — GPIO1 is connected to the 5-way directional pad's DOWN button. A 10kΩ pull-up resistor is connected.
- GPIO2 — GPIO3 is connected to the 5-way directional pad's RIGHT button. A 10kΩ pull-up resistor is connected.
- GPIO3 — GPIO4 is connected to the 5-way directional pad's LEFT button. A 10kΩ pull-up resistor is connected.
- GPIO4 — GPIO4 is connected to the 5-way directional pad's CENTER button. A 10kΩ pull-up resistor is connected.
- GPIO5 — GPIO5 is connected to the blue LED. The LED can be disconnected if users decide to use a different input to the GPIO5's PTH.
- GPIO6 — GPIO6 is connected to the green LED. The LED can be disconnected if users decide to use a different input to the GPIO6's PTH.
- GPIO7 — GPIO7 is connected to the red LED. The LED can be disconnected if users decide to use a different input to the GPIO7's PTH.
Qwiic and I2C
The board includes two horizontal Qwiic connectors to connect to other Qwiic-enabled I2C devices. However, the board still breaks out 0.1"-spaced pins for users who prefer a soldered connection.
- SCL — I2C clock on the PCA9554.
- SDA — I2C data on the PCA9554.
As explained in the previous section, the I2C address of the PCA9554 is set to 0x20 by default. By adjusting the jumpers on the back of the board, the alternative address can be any value between 0x21 to 0x27. Make sure to check the Jumpers section below for more information.
Interrupt
The interrupt pin labeled as INT is for users that want to notify a microcontroller that there is a button being pressed down on the 5-way directional pad. This pin is active low.
LEDs
The board includes two LEDs on the top and bottom of the board. Both can be disabled with the jumpers on the back of the board.
- PWR — On the bottom side of the board, the power LED indicates when power is available on 3.3V.
- STAT — The status LED is a non-addressable RGB LED that is used to indicate which button is being pressed on the 5-way directional pad. While this is populated on the bottom of the board, it will light up through the hole toward the top side of the board. Each channel can be disabled with the jumper on the back for users that want to connect them to some other input. Note that two colors were not used since there were only 5 buttons available on the directional pad.
Button Press | Color | Red (GPIO7) |
Green (GPIO6) |
Blue (GPIO5) |
---|---|---|---|---|
Up | Red | 1 | 0 | 0 |
Down | Green | 0 | 1 | 0 |
Left | Magenta | 1 | 0 | 1 |
Right | Cyan | 0 | 1 | 1 |
Center | White | 1 | 1 | 1 |
No Button Press | OFF | 0 | 0 | 0 |
Not Assigned | Blue | 0 | 0 | 1 |
Not Assigned | Yellow | 1 | 1 | 0 |
Jumpers
Note
If this is your first time working with jumpers, check out the How to Work with Jumper Pads and PCB Traces tutorial for more information.
The back of the board includes jumpers to configure the board.
- PWR — By default, the power jumper connects the LED to the output's 3.3V pin. Cutting this trace disables the LED.
- 7 — By default, this jumper is closed. Cutting this jumper will disconnect GPIO7 and the red channel from the RGB LED. One disabled, GPIO7 is available for users that want to connect them to some other input.
- 6 — By default, this jumper is closed. Cutting this jumper will disconnect GPIO6 and the green channel from the RGB LED. One disabled, GPIO6 is available for users that want to connect them to some other input.
- 5 — By default, this jumper is closed. Cutting this jumper will disconnect GPIO5 and the blue channel from the RGB LED. One disabled, GPIO5 is available for users that want to connect them to some other input.
- I2C — By default, this three-pad jumper is closed. The three way jumper labeled I2C connects 3.3V to two 2.2kΩ pull-up resistors and to the I2C data and clock lines. If multiple devices are connected to the bus with the pull-up resistors enabled, the parallel equivalent resistance will create too strong of a pull-up for the bus to operate correctly. As a general rule of thumb, disable all but one pair of pull-up resistors if multiple devices are connected to the bus.
- ADR — By default, the three jumpers 0, 1, and 2 are open. These set the I2C address of the Qwiic Directional Pad. Adding a solder blob will close the jumper and set the jumper as a
1
. Below shows the table needed to configure the three jumpers to achieve the desired I2C address.
I2C Address | ADR2 (Jumper 2) |
ADR1 (Jumper 1) |
ADR0 (Jumper 0) |
---|---|---|---|
0x20 | 0 | 0 | 0 |
0x21 | 0 | 0 | 1 |
0x22 | 0 | 1 | 0 |
0x23 | 0 | 1 | 1 |
0x24 | 1 | 0 | 0 |
0x25 | 1 | 0 | 1 |
0x26 | 1 | 1 | 0 |
0x27 | 1 | 1 | 1 |
3D Model
A 3D model of the board and components was exported to a STEP file using KiCad.
Board Dimensions
The board is 1.0" x 1.0" (25.4mm x 25.4mm). There are 2x mounting holes. You can use 4-40 standoffs to mount the board to a panel or enclosure.