In this document, we'll take a close look at the heart of the Experiential Robotics Platform (XRP) Kit, the XRP Controller. This document outlines all of the parts on this board you'll interact with while building and using the XRP Kit.
Let's take a broad look at the major components on the XRP Controller. The photo below points them out along with their names:
You'll notice that along with the arrows showing the name of some of the smaller components, the board uses what's called silkscreen to label all the connectors, buttons, LEDs and other parts you'll interact with while building and using the XRP Robotics Kit.
The Raspberry Pi Pico W microcontroller acts as the brain of this board. It combines a RP2040 processor with a wireless module for both 2.4GHz 802.11n wireless LAN and Bluetooth™ 5.2. The RP2040 communicates with the motor controllers, IMU and other components to control the robotics kit's behavior. The photo below highlights the Pico W on the Controller Board:
Think of the Pico W as a brain sending signals to other parts of the "body" to tell them what to do. It has several General Purpose Input/Output (GPIO) pins that connect to the other major parts on this board so it can send and receive data from them and return it to you visually (such as seeing the motors move) or virtually (such as watching data on a computer monitor).
The pair of DRV8835 H-Bridge motor drivers from Texas Instruments™ on the XRP Controller Board control the direction and speed of the Robotics Kit's motors.
The term H-bridge comes from how this circuit design looks on a schematic diagram. It has four internal switches that control whether the motor spins Clockwise (CW), Counter Clockwise (CCW), Coasts (no drive power), and Stops. When going through the XRP Kit curriculum you'll learn how to program the robot to tell the motor drivers to control the motors' speed and direction.
The LSM6DSO 6-DoF (Degrees of Freedom) IMU (Inertial Measurement Unit) from STMicroelectronics™ combines an accelerometer and gyroscope into a single IC (integrated circuit). This sensor lets you measure the robot's acceleration in three dimensions and also measure the orientation and angle of the robot.
The accelerometer in this chip has four measurement ranges of ±2/±4/±8/±16 g. These ranges allow you to customize the limits of the acceleration forces measured. The gyroscope has five selectable measurement ranges of ±125/±250/±500/±1000/±2000 DPS (degrees per second).
Now let's take a closer look at the parts on this board used for providing power to it.
The barrel jack connector is the primary power input for the entire XRP Kit. This connector mates with the cable from the XRP Kit's battery pack for battery-powered operation. Take note that the maximum safe voltage that can be applied to this connector is 11V and the minimum to run the system is 5V. The 4-AA battery pack included with the kit supplies a maximum of 6V so most users will have no issues exceeding the max voltage.
The Pico W has a Micro-USB connector that can be used to power the Controller Board with 5V from a USB cable. It also is the primary interface you'll use to initially set up the Pico W with a computer and program the Pico W over a USB cable.
The power switch highlighted above controls the voltage input to the Controller Board. This two-way switch turns the kit's power on and off. You can use this to turn the robot off while keeping the battery pack plugged in. The switch does not affect the Pico W's power when a USB cable is plugged in.
The Controller Board has four six-pin connectors labeled Motor L, Motor R, Motor 3, and Motor 4 and two three-pin connectors labeled Servo 1 and Servo 2.
The DC Motor connectors are where you'll plug in the left and right motors while assembling the kit. These connectors include the power connections for the motor as well as the encoders on the motors. The board routes these connections through the motor drivers to GPIO pins on the Pico W. You'll use these pins to monitor how many rotations the motor completes and use that data to determine how far the robot has traveled. Refer to the Pinout table at the end of this document for the specific GPIO pins each motor connects to on the Pico W. The Controller Board has two extra motor connectors for expansion projects using more than two motors.
The two three-pin connectors on either side of the board labeled Servo 1 and Servo 2 mate with servo motors. You'll use the Servo 2 connector to hook up the servo included in the XRP kit. Servo 1 connector is an extra one for expansion projects. These connectors have power pins (5V and Ground) and a signal pin to control the motion of the servo motor. Servo motors use a communication method called pulse width modulation (PWM) that tells the motor to move and with some motors, where to move to. If you're interested in learning more about how servo motors work, you may want to check out SparkFun's Servos Explained page for information and tutorials on how to use them.
The Controller Board has four four-pin connectors labeled (from left to right when looking at the labels upright) Line, Extra, Qwiic, and Range. Their labels indicate their use as well as which GPIO pins they connect to on the Pico W. These connectors provide an easy plug-in connection for the line follower and distance sensor as well as two extra connectors for expansion projects. These connectors are polarized meaning they only work when connected properly but they are keyed and there is only one way to plug a cable into them.
The Line connector is where you'll plug the cable for the line follower sensor into. This connects the sensor's two signal lines, Left and Right, to the Pico W's GPIO27 (Right) and GPIO26 (Left) pins. You'll use these pins to monitor whenever the sensor detects the robot has gone past the left or right threshold when performing line-following experiments.
The Range connector is where you'll plug the cable for the ultrasonic range sensor into. It connects the distance sensor's Echo and Trigger lines to the Pico W's GPIO21 (Echo) and GPIO20 (Trig). You'll use these pins to receive distance data from the ultrasonic range sensor.
The Qwiic connector works with SparkFun's Qwiic ecosystem of sensors that communicate over I2C. This is a two-wire communication protocol that works with a large variety of sensors and other electronics. With this, you can customize the XRP Kit to add things like environmental sensing, OLED screens, data logging, and more!
The Extra connector has pins for both power and ground as well as pins that connect to the Pico W's GPIO28 and GPIO22. Note, these pins are shared with other functionality on the XRP Controller Board. GPIO28 is shared with the VIN Measure pin which lets you measure the voltage level on VIN so you can monitor the remaining battery charge. GPIO22 is shared with the User Button. Both pins' primary functions can be disabled with the solder jumpers, refer to the Solder Jumpers section below for more information.
The Controller Board has three push buttons labeled USER, RESET, and BOOTSEL (on the Pico W). The USER button connects to GPIO22 on the Pico W which allows it to be programmed for various purposes. The RESET button does just what its name suggests and resets the entire board when pressed. This can help to reboot the robot or to restart a sequence you want the Robotics Kit to perform. Holding the BOOTSEL button either when plugging in a USB cable or when pressing the RESET button sets the Pico W to behave as a mass storage device when connected to a computer for uploading firmware.
There are three LEDs on the Controller Board labeled MOT, SYS, and LED.
These LEDs provide a visual indication to the user. The LEDs labeled MOT and SYS turn on when their respective power rails are powered. The MOT LED turns on when the motors have power available. The SYS LED turns on when the 3.3V/System circuit is powered. This circuit powers the Pico W, sensors, and the expansion connectos. The LED on the Pico W labeled LED is a user-programmable status LED you can program for whatever behavior you prefer. For example, you can have it turn on when the distance sensor reports a certain distance.
These solder jumpers can change the behavior of the board in a lasting way. Using these requires extra tools not included in the XRP Kit along with knowledge of how to use and interact with solder jumpers. We recommend that only advanced users adjust and change the solder jumpers. If you'd like to learn more about how to use solder jumpers, check out SparkFun's How to Work with Jumper Pads and PCB Traces tutorial.
Lastly, this Controller Board has nine solder jumpers. A solder jumper provides a customization option for advanced users to control the behavior of the pins and components they connect to. The solder jumpers on this board are labeled (from top-to-bottom when looking at the photo below): VIN_MEAS, MOT_MODE_R/4, MOT_MODE_L/3, USER_BTN, I2C, IMU_ADR, SYS, MOT, and VUSB.
|VIN_MEAS||CLOSED||Completes the VIN circuit.||Open to disrupt the VIN circuit to measure voltage on VIN with a multimeter.|
|MOT_MODE_R/4||CLOSED||Pulls the Right DRV8835's MODE pin to 3.3V.||This sets the DRV8835 to run in PH/EN mode by default. Open to switch the DRV8835 to operate in IN/IN mode.|
|MOT_MODE_L/3||CLOSED||Pulls the Left DRV8835's MODE pin to 3.3V.||This sets the DRV8835 to run in PH/EN mode by default. Open to switch the DRV8835 to operate in IN/IN mode.|
|USER_BTN||CLOSED||Completes the User Button circuit to tie it to GPIO22.||Open to disconnect the button from GPIO22.|
|I2C||CLOSED||Pulls the SDA/SCL lines to 3.3V through two 2.2kΩ.||Open completely to disable the pull up resistors on the I2C bus.|
|IMU_ADR||CLOSED||Sets the IMU's I2C address to 0x6B.||Open to switch the I2C address to 0x6A.|
|SYS||CLOSED||Completes the SYS Power LED circuit.||Open to disable the SYS Power LED.|
|MOT||CLOSED||Completes the MOT Power LED circuit.||Open to disable the MOT Power LED.|
|VUSB||CLOSED||Completes the V_USB circuit to provide 5V and 3.3V to the board from USB.||Open to prevent motors and servos from being powered by USB.|
The table below offers a quick reference for the complete pinout on the XRP Controller Board and which pins they connect to on the Pico W.
|Pico W GPIO Pin||Connector Label||Pin Function|
|GPIO0||Motor 3||Motor 3 Encoder A|
|GPIO1||Motor 3||Motor 3 Encoder B|
|GPIO2||Motor 3||Motor 3 Phase Pin|
|GPIO3||Motor 3||Motor 3 Enable Pin|
|GPIO4||Motor L||Left Motor Encoder A|
|GPIO5||Motor L||Left Motor Encoder B|
|GPIO6||Motor L||Left Motor Phase Pin|
|GPIO7||Motor L||Left Motor Enable Pin|
|GPIO8||Motor 4||Motor 4 Encoder A|
|GPIO9||Motor 4||Motor 4 Encoder B|
|GPIO10||Motor 4||Motor 4 Phase Pin|
|GPIO11||Motor 4||Motor 4 Enable Pin|
|GPIO12||Motor R||Right Motor Encoder A|
|GPIO13||Motor R||Right Motor Encoder B|
|GPIO14||Motor R||Right Motor Phase Pin|
|GPIO15||Motor R||Right Motor Enable Pin|
|GPIO16||Servo 1||Servo 1 Signal Pin|
|GPIO17||Servo 2||Servo 2 Signal Pin|
|GPIO18||Qwiic||Qwiic Data Signal for the IMU & Qwiic Connector|
|GPIO19||Qwiic||Qwiic Clock Signal for the IMU & Qwiic Connector|
|GPIO20||Range||Range Trigger Pin|
|GPIO21||Range||Range Echo Pin|
|GPIO26||Line||Line Follower Left Signal|
|GPIO27||Line||Line Follower Right Signal|