Showing posts with label idea. Show all posts
Showing posts with label idea. Show all posts

Tuesday, 27 January 2015

Arduino LED

Arduino LED

       There is no border to do samething with Arduino. Everything is about over dreams. But, however we cannot run when we born, we should start to try with Arduino from the beginning. The first project with other development boards  and Arduino is LED lighting process. Even though being a simple project, it is very helpful to learn basics about coding and electronics. We will write our codes and make our circuit. After that, we will see the code in Arduino Library. One of the reasons what makes Arduino the most popular development board is its library. We can use codes from the library directly and we can learn how to code from there.
       We need the Arduino interface program to use Arduino. We will load our codes to it with this program which is called as IDE(Integrated Development Environment). You can download it from this 

connection

 .  When we download this IDE, we get the library. Theese codes are developed inspiring from C/C++ language. Knowing basics about this language has advantages. This is basic screen of IDE.





     
       Different versions of software are available. Older versions screen is empty but in the new versions Setup and Loop functions are writed by IDE with small explanations.

When we click on the FOLDER, we can choose the NEW to open a new folder. If we want to open an older file, we can use the OPEN for this. Also, we can choose Examples to reach the library. We use USB cable to connect Arduino with the PC. We use B type USB for this. Lights will be on after connection. We can see the port number when we open the IDE.

       Our first step is LED lighting with Arduino. We need basic electronical information for this. We will use red LED and we should know its voltage and current border to decide our resistor's ohm. LED means Lighting Emitting Diode. It is used to understand current existence. In addition, it is used for the illumination.

       There is a sketch for the connection.


       We should connect the anode(+) pin to digital I/O pin and cathode(-) pin to ground. We will get 5V as a digital output from the 8th pin. But this voltage is high for the LED. So we should use a resistor. Theoretically LED 's current border is 20mA but mostly it is not same in real. So we will choose the resistor for 10mA. Red LED's voltage is 1.7V. To calculate the resistor, 5-1.7=3.3V 3.3:0.01=330 ohm. We get the valeu of the resistor with basic formula V=IR. Resistor's value is 330 ohm. we can connect it to anode or cathode, it does not matter. Now we can write our code. We choose 8th pin for the connectionto cathode.
     

void setup() {

  // we make the 8th pin as output

  pinMode(8, OUTPUT);

}

// the code in loop function repeats during Arduino power on.

void loop() {

  digitalWrite(8, HIGH);   // Make 8th pin HIGH to get digital HIGH
                           // It gives 5V output to turn LED on

  delay(1000);             // To decide LED's working time
                           

  digitalWrite(8, LOW);    // Gives 0V output to turn LED off.

  delay(1000);              // To decide LED'S off time

}

       Our code is ready but we should load it to Arduino. We will use the right sided arrow on the upper left corner of the screen.




       We made our first project with Arduino. You can make a project with more LED. You can change their on/off time to get something interesting. We will meet with next project again. Keep in touch!

Thursday, 16 October 2014

Arduino

Arduino

       With the developments in technology, just not only being user, people wanted to be a part of this. As a result of this, companies started to produce new products, which are smaller and simpler to use for personal hobby applications, intercalarily to industrial ones. There is an interest especially about the robotics. There is a famous and common product by its easy usage, ARDUINO. Arduino was designed by Massimo Banzi, David Cuartielles, Tom Igoe, Gianluca Martino and David Mellis. It is the most common development board. Being published as open source, with contributions of users, Arduino came to higher stage. Number of users is too much and this helps to increase the number of projects which are developed with Arduino.
       Price of original Arduino is about 20-25$ on the Arduino website. Clon Arduino is cheaper than original. You can buy from the China websites. Its price starts from 7-8$.
      Arduino family is produced with options about RAM, memory, mikrocontroller's cpu speed and physical properties. Most common type of Arduino is Arduino Uno. There are many projects can be improved with Arduino. Your dreams make the borders.
      In my opinion, Arduino is very easy to use and the best platorm for a person who does not have a big knowledge about electronics. Arduino does the most of it for you. You should just care about the idea and software. Also, Arduino has a code library ready to use.

       There are many artical, website and writing about Arduino but most of them does not mention about everything and they needed a knowledge at higher level than starter. We will help you to get over problems. We will show you sample projects to make it easier. We are here for your suggestions and questions. Keep in touch!