Skip to content

4.2.12. Joystick Controlled RGB Matrix Palette

| Description In Project 102, learners will construct an expert interactive system titled 'Joystick Controlled RGB Matrix Palette'. This manual details the complete synthesis of XY Joystick Module + RGB 3-Color Module + 8x8 Dot Matrix Display into an intuitive, high-performance automated control platform.|------------------|----------------------------------------------------------------| | Use case |This project connects to real-world industrial and IoT applications such as: Project 102 equips students with professional skills in embedded human-machine interface (HMI) design and automated motion control.|

Components (Things You will need)

Arduino Uno Arduino USB Cable Bread Board Jumper Wires RGB Module Resistor Joystick 8x8 Dot Matrix

Building the circuit

Things Needed:

  • Arduino Uno Core Board
  • XY Joystick Module
  • RGB 3-Color Module
  • 8x8 Dot Matrix Display
  • USB Cable & Jumper Wires
  • Bread Board
  • Resistor

Mounting the component on the breadboard and wiring the circuit

Step 1: Connect the Arduino 5V pin to the breadboard's positive (+) power rail and the Arduino GND pin to the negative (-) power rail.

Step 2: Place the XY Joystick Module on the breadboard. - Connect the VCC pin to the 5V power rail on the breadboard - Connect the GND pin to the ground rail on the breadboard - Connect the VRx pin to Analog Pin A0 - Connect the VRy pin to Analog Pin A1 - Connect the SW (switch) pin to Digital Pin 2

Step 3: Place the RGB 3-Color Module on the breadboard. - Connect the Red, Green, and Blue pins to Digital Pins 5, 6, and 9 respectively through 220Ω resistors - Connect the common pin to the ground rail on the breadboard (Common Cathode) or the 5V power rail on the breadboard (Common Anode)

Step 4: Place the 8x8 Dot Matrix Display on the breadboard. - Connect the VCC pin to the 5V power rail on the breadboard - Connect the GND pin to the ground rail on the breadboard - Connect the DIN pin to Digital Pin 11 - Connect the CS pin to Digital Pin 10 - Connect the CLK pin to Digital Pin 13

Step 5: Ensure all components share a common GND connection, then verify all wiring before connecting the Arduino Uno to your computer using the USB cable.

Components on breadboard

Step 6: After confirming that all connections are correct, connect the USB cable to the Arduino Uno board and the computer to power the circuit.

Make sure to connect the Arduino USB cable to the Arduino board.

PROGRAMMING

Step 1: Open your Arduino IDE. See how to set up here: Getting Started.

Step 2: Write the complete program implementing the system logic with appropriate pin definitions, setup configuration, and the main control loop.

// Project 102: Joystick Controlled RGB Matrix Palette
// Define pins
const int VRx = A0;
const int VRy = A1;
const int SW = 2;
const int redPin = 5;
const int greenPin = 6;
const int bluePin = 9;

void setup() {
  pinMode(VRx, INPUT);
  pinMode(VRy, INPUT);
  pinMode(SW, INPUT_PULLUP);
  pinMode(redPin, OUTPUT);
  pinMode(greenPin, OUTPUT);
  pinMode(bluePin, OUTPUT);
  Serial.begin(9600);
  Serial.println("Project 102: Joystick Controlled RGB Matrix Palette Hardware Online");
}

void loop() {
  // Read joystick values
  int xVal = analogRead(VRx);
  int yVal = analogRead(VRy);
  int swVal = digitalRead(SW);

  // Interactive logic and display updates here
  delay(100);
}

Step 7: Save your code. See the Getting Started section

Step 8: Select the arduino board and port See the Getting Started section:Selecting Arduino Board Type and Uploading your code.

Step 9: Upload your code. See the Getting Started section:Selecting Arduino Board Type and Uploading your code

CONCLUSION

Operating physical input devices instantly modifies actuator behavior and updates visual indicators in real time.