Arduino - Arduino Tutorial

Arduino  - arduino tutorial

Arduino is a computer hardware and software company, project, and user community that designs and manufactures microcontroller-based kits for building digital devices and interactive objects that can sense and control objects in the physical world. The project is based on open-source hardware and software, under the GNU Lesser General Public License (LGPL) or GNU General Public License (GPL).

The project is based on microcontroller board designs, manufactured by several vendors, using various microcontrollers. These systems provide sets of digital and analog input/output (I/O) pins that can be interfaced to various expansion boards ("shields") and other circuits. The boards feature serial communications interfaces, including Universal Serial Bus (USB) on some models, for loading programs from personal computers. The microcontrollers are mainly programmed using a dialect of features from the programming languages C and C++. In addition to using traditional compiler toolchains, the Arduino project provides an integrated development environment (IDE) based on the Processing language project.

The Arduino project started in 2005 as a program for students at the Interaction Design Institute Ivrea in Ivrea, Italy, aiming to provide a low-cost and easy way for novices and professionals to create devices that interact with their environment using sensors and actuators. Common examples of such devices intended for beginner hobbyists include simple robots, thermostats, and motion detectors.

Arduino boards are available commercially in preassembled form, or as do-it-yourself kits. The hardware design specifications are openly available, allowing the Arduino boards to be manufactured by anyone. Adafruit Industries estimated in mid-2011 that over 300,000 official Arduinos had been commercially produced, and in 2013 that 700,000 official boards were in users' hands.

Arduino  - arduino tutorial
History

The origin of the Arduino project started at the Interaction Design Institute Ivrea in Ivrea, Italy. At that time students used a BASIC Stamp at a cost of $100, considered costly for students. In 2004, Colombian student Hernando Barragán created the development platform Wiring as a Master's thesis project at the Interaction Design Institute Ivrea (IDII) in Ivrea, Italy. Massimo Banzi and Casey Reas, who are known for work on the Processing language were supervisors for his thesis. The project goal was to create low cost, simple tools for non-engineers to create digital projects. The Wiring platform consisted of a hardware PCB with an ATmega168 microcontroller, an IDE based on Processing and library functions to easily program the microcontroller.

In 2005, Massimo Banzi, with David Mellis, an IDII , and David Cuartielles, added support for the cheaper ATmega8 microcontroller to Wiring. But instead of continuing the work on Wiring, they forked (or copied) the Wiring source code and started running it as a separate project, called Arduino.

The Arduino's initial core team consisted of Massimo Banzi, David Cuartielles, Tom Igoe, Gianluca Martino, and David Mellis.

The name Arduino comes from a bar in Ivrea, where some of the founders of the project used to meet. The bar was named after Arduin of Ivrea, who was the margrave of the March of Ivrea and King of Italy from 1002 to 1014.

Following the completion of the Wiring platform, lighter and lower cost versions were distributed in the open-source community.

Arduino  - arduino tutorial
Hardware

Arduino is open-source hardware. The hardware reference designs are distributed under a Creative Commons Attribution Share-Alike 2.5 license and are available on the Arduino website. Layout and production files for some versions of the hardware are also available. The source code for the IDE is released under the GNU General Public License, version 2. Nevertheless an official Bill of Materials of Arduino boards has never been released by the staff of Arduino.

Although the hardware and software designs are freely available under copyleft licenses, the developers have requested that the name "Arduino" be exclusive to the official product and not be used for derived works without permission. The official policy document on use of the Arduino name emphasizes that the project is open to incorporating work by others into the official product. Several Arduino-compatible products commercially released have avoided the Arduino name by using -duino name variants.

An Arduino board consists of an Atmel 8-, 16- or 32-bit AVR microcontroller (although since 2015 other makers' microcontrollers have been used) with complementary components that facilitate programming and incorporation into other circuits. An important aspect of the Arduino is its standard connectors, which let users connect the CPU board to a variety of interchangeable add-on modules termed shields. Some shields communicate with the Arduino board directly over various pins, but many shields are individually addressable via an I²C serial busâ€"so many shields can be stacked and used in parallel. Before 2015, Official Arduinos had used the Atmel megaAVR series of chips, specifically the ATmega8, ATmega168, ATmega328, ATmega1280, and ATmega2560. In 2015, units by other producers were added. A handful of other processors have also been used by Arduino compatible devices. Most boards include a 5 V linear regulator and a 16 MHz crystal oscillator (or ceramic resonator in some variants), although some designs such as the LilyPad run at 8 MHz and dispense with the onboard voltage regulator due to specific form-factor restrictions. An Arduino's microcontroller is also pre-programmed with a boot loader that simplifies uploading of programs to the on-chip flash memory, compared with other devices that typically need an external chip programmer. This makes using an Arduino more straightforward by allowing the use of an ordinary computer as the programmer. Currently, optiboot bootloader is the default bootloader installed on Arduino UNO.

At a conceptual level, when using the Arduino integrated development environment, all boards are programmed over a serial connection. Its implementation varies with the hardware version. Some serial Arduino boards contain a level shifter circuit to convert between RS-232 logic levels and transistorâ€"transistor logic (TTL) level signals. Current Arduino boards are programmed via Universal Serial Bus (USB), implemented using USB-to-serial adapter chips such as the FTDI FT232. Some boards, such as later-model Uno boards, substitute the FTDI chip with a separate AVR chip containing USB-to-serial firmware, which is reprogrammable via its own ICSP header. Other variants, such as the Arduino Mini and the unofficial Boarduino, use a detachable USB-to-serial adapter board or cable, Bluetooth or other methods, when used with traditional microcontroller tools instead of the Arduino IDE, standard AVR in-system programming (ISP) programming is used.

The Arduino board exposes most of the microcontroller's I/O pins for use by other circuits. The Diecimila, Duemilanove, and current Uno provide 14 digital I/O pins, six of which can produce pulse-width modulated signals, and six analog inputs, which can also be used as six digital I/O pins. These pins are on the top of the board, via female 0.1-inch (2.54 mm) headers. Several plug-in application shields are also commercially available. The Arduino Nano, and Arduino-compatible Bare Bones Board and Boarduino boards may provide male header pins on the underside of the board that can plug into solderless breadboards.

Many Arduino-compatible and Arduino-derived boards exist. Some are functionally equivalent to an Arduino and can be used interchangeably. Many enhance the basic Arduino by adding output drivers, often for use in school-level education, to simplify making buggies and small robots. Others are electrically equivalent but change the form factor, sometimes retaining compatibility with shields, sometimes not. Some variants use different processors, of varying compatibility.

Official boards

The original Arduino hardware was produced by the Italian company Smart Projects. Some Arduino-branded boards have been designed by the American companies SparkFun Electronics and Adafruit Industries. As of 2016, 17 versions of the Arduino hardware have been commercially produced.

Shields

Arduino and Arduino-compatible boards use printed circuit expansion boards called shields, which plug into the normally supplied Arduino pin headers. Shields can provide motor controls for 3D printing and other applications, Global Positioning System (GPS), Ethernet, liquid crystal display (LCD), or breadboarding (prototyping). Several shields can also be made do it yourself (DIY).

Arduino  - arduino tutorial
Software development

Arduino programs may be written in any programming language with a compiler that produces binary machine code. Atmel provides a development environment for their microcontrollers, AVR Studio and the newer Atmel Studio, which can be used for programming Arduino.

The Arduino project provides the Arduino integrated development environment (IDE), which is a cross-platform application written in the programming language Java. It originated from the IDE for the languages Processing and Wiring. It was created for people with no profound knowledge of electronics. It includes a code editor with features such as syntax highlighting, brace matching, cutting-pasting and searching-replacing text, and automatic indenting, and provides simple one-click mechanism to compile and upload programs to an Arduino board. It also contains a message area, a text console, a toolbar with buttons for common functions and a series of menus.

A program written with the IDE for Arduino is called a "sketch". Sketches are saved on the development computer as files with the file extension .ino. Arduino Software (IDE) pre-1.0 saved sketches with the extension .pde.

The Arduino IDE supports the languages C and C++ using special rules to organize code. The Arduino IDE supplies a software library from the Wiring project, which provides many common input and output procedures. User-written code only requires two functions, for starting the sketch and the main programs loop, that are compiled and linked with a program stub main() into an executable cyclic executive program with the GNU toolchain, also included with the IDE distribution. The Arduino IDE employs the program avrdude to convert the executable code into a text file in hexadecimal coding that is loaded into the Arduino board by a loader program in the board's firmware.

Arduino  - arduino tutorial
Software

A minimal Arduino C/C++ sketch consist of only two functions:

  • setup(): This function is called once when a sketch starts after power-up or reset. It is used to initialize variables and pin modes, and to initialize any other libraries.
  • loop(): After setup() is called, this function is called repeatedly. It controls the board until it is powered off or is reset.

Most Arduino boards contain a light-emitting diode (LED) and a load resistor connected between pin 13 and ground, which is a convenient feature for many tests and program functions. A typical program for a beginning Arduino programmer blinks an LED repeatedly. This program is usually loaded in the Arduino by the manufacturer. In the Arduino environment, a user might write such a program as shown:

  #define LED_PIN 13                  // Pin number attached to LED.    void setup() {      pinMode(LED_PIN, OUTPUT);       // Configure pin 13 to be a digital output.  }    void loop() {      digitalWrite(LED_PIN, HIGH);    // Turn on the LED.      delay(1000);                    // Wait 1 second (1000 milliseconds).      digitalWrite(LED_PIN, LOW);     // Turn off the LED.      delay(1000);                    // Wait 1 second.  }  

This program uses the functions pinMode(), digitalWrite(), and delay(), which are provided by the internal libraries included in the IDE environment.

Arduino  - arduino tutorial
Applications

  • Xoscillo, an open-source oscilloscope
  • Scientific equipment such as the Chemduino
  • Arduinome, a MIDI controller device that mimics the Monome
  • OBDuino, a trip computer that uses the on-board diagnostics interface found in most modern cars
  • Ardupilot, drone software and hardware
  • ArduinoPhone, a do-it-yourself cellphone
  • GertDuino, an Arduino mate for the Raspberry Pi
  • Water quality testing platform
  • Homemade CNC using Arduino and DC motors with close loop control by Homofaciens
  • DC motor control using Arduino and H-Bridge

Arduino  - arduino tutorial
Recognitions

The Arduino project received an honorary mention in the Digital Communities category at the 2006 Prix Ars Electronica.

Arduino  - arduino tutorial
Trademark dispute

In early 2008, the five cofounders of the Arduino project created a company, Arduino LLC, to hold the trademarks associated with Arduino. The manufacture and sale of the boards was to be done by external companies, and Arduino LLC would get a royalty from them. The founding bylaws of Arduino LLC specified that each of the five founders transfer ownership of the Arduino brand to the newly formed company.

At the end of 2008, Gianluca Martino's company, Smart Projects, along with Microsoft, registered the Arduino trademark in Italy and kept this a secret from the other cofounders for about two years. This was revealed when the Arduino company tried to register the trademark in other areas of the world (they originally registered only in the US), and discovered that it was already registered in Italy. Negotiations with Gianluca and his firm to bring the trademark under control of the original Arduino company failed. In 2014, Smart Projects began refusing to pay royalties. They then appointed a new CEO, Mr. Musto, who renamed the company to Arduino SRL and created a website named arduino.org, copying the graphics and layout of the original Arduino.cc. This resulted in a rift in the Arduino development team. All Arduino boards are still available to consumers so the implications of this are uncertain.

In May 2015, "Genuino" was created around the world as another trademark, held by Arduino LLC, and is currently being used as Arduino LLC's brand name outside of the US.

At the World Maker Faire in New York on October 1, 2016, Arduino LLC co-founder and CEO Massimo Banzi and Arduino SRL CEO Federico Musto announced that the 2 Arduino companies will join and become one. From the Arduino Website: "At the end of 2016, the newly created “Arduino Holding” will become the single point of contact for the wholesale distribution of all current and future products, and will continue to bring tremendous innovations to the market."

0 komentar: