MicroMod Qwiic Pro Kit Project Guide

Pages
Contributors: bboyho
Favorited Favorite 0

Introduction

Note: If you are looking for the previous version of this tutorial, head over to the Qwiic Pro Kit Project Guide.

The MicroMod Qwiic Pro Kit was designed to allow users to get started with Arduino without the need for soldering or a breadboard. We've included three inputs (a joystick, accelerometer, and proximity sensor) and one display that can be daisy chained to your Arduino. Hooking up a handful of inputs and outputs to an Arduino has never been so easy with the MicroMod and Qwiic ecosystems!

SparkFun MicroMod Qwiic Pro Kit

SparkFun MicroMod Qwiic Pro Kit

KIT-20407
$99.95 $74.95

Suggested Reading

If you aren't familiar with the MicroMod ecosystem, we recommend reading here for an overview. We recommend reading here for an overview if you decide to take advantage of the Qwiic connector.

MicroMod Logo Qwiic Connect System
MicroMod EcosystemQwiic Connect System

We would also recommend taking a look at the following tutorials to set up the RedBoard Turbo and get a feel for each Qwiic component.

Qwiic Carrier Board Hookup Guide

March 18, 2021

The Qwiic carrier board is the latest way to rapid prototype with the included M.2 socket to swap processor boards and Qwiic connectors to easily connect I2C devices.

MicroMod SAMD51 Processor Board Hookup Guide

October 21, 2020

This tutorial covers the basic functionality of the MicroMod SAMD51 and highlights the features of the ARM Cortex-M4F development board.

Qwiic Micro OLED Hookup Guide

Get started displaying things with the Qwiic Micro OLED.

Qwiic Joystick Hookup Guide

Looking for an easy way to implement a joystick to your next Arduino or Raspberry Pi project? This hookup guide will walk you through using the Qwiic Joystick with the Arduino IDE on a RedBoard Qwiic and in Python on a Raspberry Pi.

Qwiic Proximity Sensor (VCNL4040) Hookup Guide

The SparkFun Qwiic Proximity Sensor is a great, qualitative proximity (up to 20 cm) and light sensor. This hookup guide covers a few examples to retrieve basic sensor readings.

Qwiic 9DoF - ISM330DHCX, MMC5983MA Hookup Guide

Find all your degrees of freedom with this little Qwiic breakout board combining the ISM330DHCX 6Dof and the MMC5983MA Magnetometer!

Kit Contents

You will find the following parts in the kit.

Qwiic Pro Kit Contents

Note: Prior to MicroMod Qwiic Pro Kit was the Qwiic Pro Kit. Instead of the RedBoard Turbo with SAMD21 and USB micro-b cable , the MicroMod Qwiic Pro Kit includes the MicroMod SAMD51 Processor Board, Qwiic Carrier Board - Single, USB C Cable, and a MicroMod screwdriver. The Qwiic Triple Axis Accelerometer Breakout - MMA8452Q is also replaced by the 9DoF IMU Breakout - ISM330DHCX, MMC5983MA (Qwiic).

Hardware Hookup

If you have not already, make sure to check out the Getting Started with MicroMod: Hardware Hookup for information on inserting your Processor Board to your Carrier Board. The MicroMod Qwiic Carrier Board Hookup Guide also goes over how to connect the boards together as well!

Getting Started with MicroMod

October 21, 2020

Dive into the world of MicroMod - a compact interface to connect a microcontroller to various peripherals via the M.2 Connector!

Remove the screw across from the MicroMod Qwiic Carrier Board - Single. Then insert the MicroMod SAMD51 Processor Board into the M.2 socket. The Processor Board will stick up at an angle (at around 25°), as seen here.

MicroMod SAMD51 Processor Board Inserted M.2 Socket

Hold the board down and tighten the screw with a Philip's head.

Tighten Screw

Once connected, your board should be secured to the MicroMod Qwiic Carrier Board - Single like the image shown below.

SAMD51 Secure in MicroMod Qwiic Carrier Board's M.2 Socket

Insert the Qwiic cable of your choice between each to each of the boards. You can daisy chain the boards any way you like. However, we found it easier to control the 9DoF's accelerometer by having it at the end and connecting a longer Qwiic cable. Depending on the player, you will need to orient the 9DoF's accelerometer with respect to the paddle. The vertical and horizontal Qwiic connectors also connect to the same port so you can connect to either one. We also found it easier to connect the Qwiic Distance Sensor with VCNL4040 to the other end as well. Then connect the USB cable between your computer and MicroMod Qwiic Carrier Board - Single.

MicroMod Qwiic Pro Kit Connected

Mounting Qwiic Boards to the Standoffs

You can also mount the Qwiic Micro OLED breakout to the end of the two standoffs as shown below. Remove the yellow tape that is covering the mounting holes. Align the mounting hole with the standoffs. Insert a 4-40 screw between the Qwiic Micro OLED's mounting hole and tighten. You'll need to use some elbow grease to drive each 4-40 screw into the standoffs since they are slightly offset. Make sure to be careful with the Qwiic connector that is closest to the mounting holes. The height of the standoffs and the position of the connector can make the connector push against the end of the Qwiic Carrier Board - Single. However, it was enough to hold the display down.

MicroMod Qwiic Pro Kit Connected with Micro OLED Breakout Mounted

We recommend not mounting the Qwiic Distance Sensor, Qwiic Joystick, and Qwiic 9DoF so that users that are sitting across from each other are able to control their paddle on their side without getting in the way of the display.

Installing the Board Add-Ons and Drivers

Note: This code/library has been written and tested on Arduino IDE version v1.8.12. Otherwise, make sure you are using the latest stable version of the Arduino IDE on your desktop. If this is your first time using Arduino, please review our tutorial on installing the Arduino IDE.

There are a few board add-ons to install before you are able to upload code to your MicroMod SAMD51 Processor Board. If you have not already, make sure to check out the MicroMod SAMD51 Processor Board hookup guide to install the SAMD51 and SparkFun board add-ons.

Drivers

The MicroMod SAMD51 Processor Board is now easier than ever to program, thanks the UF2 bootloader. With this bootloader, the MicroMod SAMD51 Processor Board shows up on your computer as a USB storage device without having to install drivers for Windows 10, Mac, and Linux!

Installing the Libraries

Note: If you have not previously installed an Arduino library, please check out our installation guide.

SparkFun has written a library for the Qwiic enabled joystick, 9DoF IMU (ISM330DHCX, MMC5983MA), proximity sensor (VCNL4040), and 64x48 micro OLED. You can obtain these libraries through the Arduino Library Manager. Search for the following terms to automatically install the latest versions of each library. If you have issues compiling, you may need to download the respective library versions listed below.

If you prefer downloading the libraries manually, you can grab them from each of the respective GitHub repositories.

Note: The demo code currently just uses the accelerometer to control the paddle. We have linked the library in this section in case you use the magnetometer in case you decide to use it as well!

Example Code

We recommend grabbing the code from its the GitHub repository. Otherwise, you can download the zipped file from the link below.

After downloading, unzip the files and open the MicroModQwiicStarterExample.ino sketch. It should be located in the downloads folder similar to this path: .../Firmware/Arduino/MicroModQwiicStarterExample/MicroModQwiicStarterExample.ino. Open the code up in the Arduino IDE, select the board (i.e. the SparkFun SAMD51 MicroMod), and the COM port that the board enumerated on. Then hit the upload button.

With a friend, try rocking the 9DoF back and forth along the x-axis or moving your hand above the proximity sensor to control each paddle. You can also take a PCB or flat object as shown in the GIF below to make it easier to control. Remember, you will need to orient the 9DoF's accelerometer with respect to the paddle (if you notice in the GIF, player 1 had the board oriented in a way that had the paddle controls were reversed). You will need to orient the micro OLED so that the paddle is on the side of the player's Qwiic board. The game will continue as long as the ball hits the paddle and bounces to the other side. A player will win a round as soon as the other player fails to bounce the ball back to the other side. The current score will be briefly displayed before the next game. Try to rack up more points than your opponent!

MicroPong Demo with MicroMod Qwiic Pro Kit

The default code uses the 9DoF's accelerometer as player 1 and the proximity sensor as player 2. Try adjusting the code to use the joystick for one of the players by adding and removing the single line comments. The joystick will control the paddle along the "vertical" y-axis. Each board can only have one player assigned. See if you can try to remove the unused Qwiic board from the daisy chain and commenting out each instance of the related board. Or try adjusting the code to control the paddle with the magnetometer and a magnet!

Troubleshooting

Resources and Going Further

Now that you've successfully got your MicroMod Qwiic Pro Kit up and running, what will else will you build? For more information, check out the resource below:

Need some inspiration for your next project? Check out some of these related tutorials:

Qwiic Scale Hookup Guide

Create your own digital scale quickly and easily using the Qwiic Scale!

Keyboard Shortcut, Qwiic Keypad

A simple project using the Qwiic Keypad and the RedBoard Turbo to create your own custom hotkey-pad.

SparkFun Qwiic Quad Solid State Relay Kit Hookup Guide

A Hookup Guide to get you started with the SparkFun Qwiic Quad Solid State Relay Kit (say that five times fast!).

MicroMod Main Board Hookup Guide

The MicroMod Main Board - Single and Double are specialized carrier boards that allow you to interface a Processor Board with a Function Board(s). The modular system allows you to add an additional feature(s) to a Processor Board with the help of a Function Board(s). In this tutorial, we will focus on the basic functionality of the Main Board - Single and Main Board - Double.