MATRIX Using a IR Sensor

by Aniana01 in Circuits > Arduino

717 Views, 0 Favorites, 0 Comments

MATRIX Using a IR Sensor

IMG_8237.jpeg
IMG_8230.jpeg
IMG_8241.jpeg
IMG_8234.jpeg
IMG_8233.jpeg
IMG_8231.jpeg
IMG_8232.jpeg
IMG_8238.jpeg

In this Arduino project I wanted to use an IR object avoidance sensor and the Matrix LED's. My goal was for the sensor to detect an object and the Matrix LED's to display a message that an object was detected. Finding the supplies is fairly easy so is the setup for this Instructable. The only struggle that I dealt with was trying to figure out how the Matrix LED's operated.

Supplies

Getting Connected

IMG_8247.jpeg
IMG_8246.jpeg

Connecting the wires to the right spot can be a little tricky.

IR SENSOR

Lets start simple. Starting with the IR sensor connect 3 Female-to-Male wires using the female part of the cable to the OUT, GND, and VCC. Once the female part is connected to the sensor we're going to place the male parts on the Arduino UNO. The wire that is connected to the VCC connect the male part to the 3.3V. The wire that is connected to the GND place the male part to the GND portion the Arduino UNO. Finally place the wire that is connected to the OUT plug the male part to pin 6.

Into the Matrix

IMG_8248.jpeg
IMG_8249.jpeg

Locate the Breadboard jumper wire adapter on the Matrix LED's. Connect the wires to the 5V, GND, and DIN with the Breadboard jumper wires. We are going to connect the Matrix LED's directly to the Breadboard. Connect the DIN wire to the middle of the Breadboard (I chose 30a). Connect the GND wire to the negative side (blue line) of the Breadboard. Connect the 5V wire to the positive side of the Breadboard.

TIP

  • When placing the wires to the negative positive side on the Breadboard stick to one side.
  • Make sure that the wires are long enough to reach.
  • Make sure to color code your wires and remember the location they are connected to.

I Got the Power

IMG_8254.jpeg
IMG_8253.jpeg

I used the power supply component in order to protect the Breadboard from overproducing electricity. Grab two Female-to-Male wires and connect the female portion of the wire to the GND and VCC. Connect the GND wire to the negative side (blue line) of the Breadboard. Connect the VCC wire to the positive side (red line) of the Breadboard.

Connecting the Breadboard to the Arduino UNO

IMG_8258.jpeg
IMG_8259.jpeg

In order to connect the Breadboard to the Arduino UNO is really simple. We are going to need two Breadboard jumper wires. Place one jumper wire to pin 7 on the Arduino UNO on the same lines as the Matrix DIN wire. For example, if the Matrix DIN wire was connected to line 30a connect the pin 7 jumper wire to line 30c. For the second wire place one end in the 5V slot on the Arduino and the other end on the positive side (red line) of the Breadboard.

CODE BLUE

The coding is fairly simple and can easily be altered to ones liking.

The code is basically two commands that powers the whole thing. The first command states the settings on the Matrix LED's and the second part of the code explains if the IR sensor is activated the power the Matrix LED.

Downloads