Skip to main content

Posts

Showing posts from October, 2016

Arduino Beginner Experiments: Arduino and Linear Hall Sensor

HELLO THERE!!!       How are you,guys? I hope everyone is fine and in a good mood always. This week I wanted to share with you guys a simple experiment I did over the weekend. The objective of this week's experiment is to receive basic feedback from the linear hall sensor. What is a Linear Hall Sensor?   Basically a linear hall sensor is a magnetic module with a digital interface. The sensor also has a built in LED in it.The sensor can detect magnetic field, thus making it useful in many projects (magnetic door lock to name a few). HARDWARE: 1.Arduino UNO ( you can use other Arduino) 2.Linear Hall Sensor SOFTWARE: 1.Arduino IDE CIRCUIT ASSEMBLY Referring to the sensor image below: SENSOR                     ARDUINO G               ---------->  GND +               -----------> 5V D0            -----------> Digital pin 8 (any digital pin) CODING THE ARDUINO int led=13; //initializing led pin in digital pin 13(built

Arduino Beginner Experiments: Arduino and Joystick Module part 2

HELLO THERE!!!     How are you guys? I hope everyone is fine and in a good mood always. So, I decided to continue my post last week by implementing the Joystick module as a mouse. In this experiment, the joystick will control the mouse movement and left button click. HARDWARE: 1.Arduino Leonardo 2.Joystick Module SOFTWARE: 1.Arduino IDE CIRCUIT ASSEMBLY  The assembly of the circuit is similar with what we did last week: Joystick Module --------------->Arduino GND                                            GND 5V                                                  5V VRx                                              (any analog pin) VRy                                              (any analog pin) SW                                                (any digital pin) The schematic of the circuit   CODING THE ARDUINO     The code below is taken from the Arduino website. I also added a piece of code which enables the function of the b

Arduino Beginner Experiments: Arduino and Joystick module

HELLO THERE!!!   How are you guys? I hope everyone is fine and in a good mood always. Sorry for the late this week guys as i am a bit busy with my work. So, this week, I would like to share with you guys a simple experiment on arduino and joystick module, In this experiment, our objective is to read the analog and digital values from the joystick. Without wasting any time, let's jump into it. HARDWARE: 1.Arduino UNO 2.Joystick Module SOFTWARE: 1. Arduino IDE CIRCUIT ASSEMBLY There are 5 pins on the joystick module. The pins are GND,5V,VRx(x movement),VRy(y movement), and SW(button). The connections of these pins to the Arduino is depicted as below: Joystick Module ---------------> Arduino GND                                             GND 5V                                                  5V VRx                                                A0 (or any analog pin) VRy                                                A1 (or any anal

Arduino Beginner Experiments: Reading from The SD Card

HELLO THERE!!!!       How are you,guys? I hope everyone is fine and in good mood always. Last week, I had shown you guys on how to write sensor data to a text file in a SD Card. This week, I will be showing you guys on how to read the data that is stored in the text file in the SD Card. Without wasting time, let's get into the experiment. HARDWARE: 1.Arduino UNO  2.Ethernet Shield/Micro SD shield/ Any board with Micro SD slot ( I used the ethernet shield for this weekend)  3.Micro SD card. SOFTWARE: 1.Arduino IDE CIRCUIT ASSEMBLY: The circuit assembly is fairly simple. Just plug in the Ethernet shield on top the Arduino board and insert the micro SD card into the shield. BEFORE CODING:  Make sure there is a text file in the SD card name bgsound (or any name that you like actually).  CODING THE ARDUINO:  The code to read the text file in the SD card is shown below: #include <SPI.h> #include <SD.h> void setup() {   // O