00 Introduction

BECOME EXTRAORDINARY

Everyone, every day, uses technology. Most of us leave the programming to engineers because we think coding and electronics are complicated and difficult; actually, they can be fun and exciting activities. Thanks to Arduino, designers, artists, hobbyists and students of all ages are learning to create things that light up, move, and respond to people, animals, plants, and the rest of the world.
Over the years Arduino has been used as the “brain” in thousands of projects, one more creative than the last. A worldwide community of makers has gathered around this open-source platform, moving from personal computing to personal fabrication, and contributing to a new world of participation, cooperation and sharing.
Arduino is open and simple. It’s founded on lessons we’ve learned teaching our own classes: if you start with the assumption that learning to make digital technologies is simple and accessible, you can make it so. Suddenly electronics and code become creative tools that anyone can use – like brushes and paint. This book walks you through the basics in a hands-on way, with creative projects you build by learning. Once you’ve mastered the basics, you’ll have a palette of software and circuits that you can use to create something beautiful, and make someone smile with what you invent.

Welcome to Arduino!

ARDUINO MAKES IT AS EASY AS POSSIBLE TO PROGRAM TINY COMPUTERS CALLED MICROCONTROLLERS, WHICH ARE WHAT MAKE OBJECTS INTERACTIVE

You are surrounded by dozens of them every day: they are embedded in timers, thermostats, toys, remote controls, microwave ovens, even some toothbrushes. They just do one specific task, and if you hardly notice them – which is often the case – it’s because they are doing it well. They have been programmed to sense and control activity using sensors and actuators.
Sensors listen to the physical world. They convert energy that you give off when you press buttons, or wave your arms, or shout, into electrical signals. Buttons and knobs are sensors that you touch with your fingers, but there are many other kinds of sensors.
Actuators take action in the physical world. They convert electrical energy back into physical energy, like light and heat and movement.
Microcontrollers listen to sensors and talk to actuators. They decide what to do based on a program that you write.
Microcontrollers and the electronics you attach to them are just the skeleton of your projects, though. You’ll need to bring skills you probably already have to put some flesh on the bones.
For example, in one of the projects we suggest, you’ll make an arrow and attach it to a motor, and put them both in a box with a knob, so you can make a meter to tell people whether you’re busy or not. In another, you’ll put some lights and a tilt switch on a cardboard frame to make an hourglass.
Arduino can make your projects responsive, but only you can make them beautiful. We’ll provide some suggestions along the way as to how you might do that.
Arduino was designed to help you get things done. To make that happen, we kept the background material on programming and electronics to a minimum. If you decide you want to know more about these aspects, there are lots of good guides available. We’ll provide a couple of references, and you can find more online at: arduino.cc/starterkit

PARTS IN YOUR KIT

Arduino Uno - The microcontroller develop-ment board that will be at the heart of your projects. It’s a simple computer, but one that has no way for you to interact with it yet. You will be building the circuits and interfaces for interaction, and telling the microcontroller how to interface with other components.
Battery Snap - Used to connect a 9V battery to power leads that can be easily plugged into a breadboard or your Arduino.
Breadboard - A board on which you can build electronic circuits. It’s like a patch panel, with rows of holes that allow you to connect wires and components together. Versions that re-quire soldering are available, as well as the sol-der-less type used here.
Capacitors - These components store and re-lease electrical energy in a circuit. When the circuit’s voltage is higher than what is stored in the capacitor, it allows current to flow in, giv-ing the capacitor a charge. When the circuit’s voltage is lower, the stored charge is released. Often placed across power and ground close to a sensor or motor to help smooth fluctuations in voltage.
DC motor - Converts electrical energy into me-chanical energy when electricity is applied to its leads. Coils of wire inside the motor become magnetized when current flows through them.These magnetic fields attract and repel mag-nets, causing the shaft to spin. If the direction of the electricity is reversed, the motor will spin in the opposite direction.
Diode - Ensures electricity only flows in one di-rection. Useful when you have a motor or other high current/voltage load in your circuit. Di-odes are polarized, meaning that the direction that they’re placed in a circuit matters. Placed one way, they allow current to pass through. Placed the other way, they block it. The anode side generally connects to the point of higher energy in your circuit. The cathode typically connects to the point of lower energy, or to ground. The cathode is usually marked with a band on one side of the component’s body.
Gels (red, green, blue) - These filter out differ-ent wavelengths of light. When used in con-junction with photoresistors, they cause the sensor to only react to the amount of light in the filtered color.
H-bridge - A circuit that allows you to control the polarity of the voltage applied to a load, usually a motor. The H-bridge in the kit is an in-tegrated circuit, but it could also be construct-ed with a number of discrete components.
Jumper wires - Use these to connect compo-nents to each other on the breadboard, and to the Arduino.
Light Emitting Diodes (LEDs) - A type of diode that illuminates when electricity passes through it. Like all diodes, electricity only flows in one direction through these components. You’re probably familiar with these as indicators on a variety of electronic devices. The anode, which typically connects to power, is usually the long-er leg, and the cathode is the shorter leg.
Liquid Crystal Display (LCD) - A type of alpha-numeric or graphic display based on liquid crys-tals. LCDs are available in a many sizes, shapes, and styles. Yours has 2 rows with 16 characters each.
Male header pins - These pins fit into female sockets, like those on a breadboard. They help make connecting things much easier.
Optocoupler - This allows you to connect two circuits that do not share a common power supply. Internally there is a small LED that, when illuminated, causes a photoreceptor in-side to close an internal switch. When you ap-ply voltage to the + pin, the LED lights and the internal switch closes. The two outputs replace a switch in the second circuit.
Piezo - An electrical component that can be used to detect vibrations and create noises.
Photoresistor - (also called a photocell, or light-dependent resistor). A variable resistor that changes its resistance based on the amount of light that falls on its face.
Potentiometer - A variable resistor with three pins. Two of the pins are connected to the ends of a fixed resistor. The middle pin, or wiper, moves across the resistor, dividing it into two halves. When the external sides of the poten-tiometer are connected to voltage and ground, the middle leg will give the difference in voltage as you turn the knob. Often referred to as a pot.
Pushbuttons - Momentary switches that close a circuit when pressed. They snap into bread-boards easily. These are good for detecting on/off signals.
Resistors - Resist the flow of electrical energy in a circuit, changing the voltage and current as a result. Resistor values are measured in ohms (represented by the Greek omega char-acter: Ω). The colored stripes on the sides of resistors indicate their value (see resistor color code table).
Servo motor - A type of geared motor that can only rotate 180 degrees. It is controlled by sending electrical pulses from your Arduino. These pulses tell the motor what position it should move to.
Temperature sensor - Changes its voltage out-put depending on the temperature of the com-ponent. The outside legs connect to power and ground. The voltage on the center pin changes as it gets warmer or cooler.
Tilt sensor - A type of switch that will open or close depending on its orientation. Typically they are hollow cylinders with a metal ball in-side that will make a connection across two leads when tilted in the proper direction.
Transistor - A three legged device that can op-erate as an electronic switch. Useful for controlling high current/high voltage components like motors. One pin connects to ground, another to the component being controlled, and the third connects to the Arduino. When the com-ponent receives voltage on the pin connected to an Arduino, it closes the circuit between the ground and the other component.
USB Cable - This allows you to connect your Arduino Uno to your personal computer for programming. It also provides power to the Ar-duino for most of the projects in the kit.

TABLE OF SYMBOLS

UNCONNECTED WIRES
TILT SWITCH
RESISTOR
LED
POLARIZED CAPACITOR
GROUND
CONNECTED WIRES
TRANSISTOR
MOSFET
PHOTO RESISTOR
DIODE
CAPACITOR
PUSHBUTTON
MOTOR
POTENTIOMETER
PIEZO
BATTERY
In this book we will show you circuits both with realistic illustrations and with schematic diagrams.
Illustrations will give you an idea of what the breadboard might look like in one possible implementation of the project. Schematics, instead, use symbols to capture the essence of circuits: they present the components and the ways they are connected in a clear, succinct, and unambiguous form, but not their physical organization. Schematics and schematic symbols are how we communicate about circuits. As you explore the world of electronics you will discover that some books and websites only provide schematic diagrams, so learning to read circuits this way is a valuable skill.
Here are the symbols we will be using throughout the book.

最后编辑于
©著作权归作者所有,转载或内容合作请联系作者
  • 序言:七十年代末,一起剥皮案震惊了整个滨河市,随后出现的几起案子,更是在滨河造成了极大的恐慌,老刑警刘岩,带你破解...
    沈念sama阅读 203,324评论 5 476
  • 序言:滨河连续发生了三起死亡事件,死亡现场离奇诡异,居然都是意外死亡,警方通过查阅死者的电脑和手机,发现死者居然都...
    沈念sama阅读 85,303评论 2 381
  • 文/潘晓璐 我一进店门,熙熙楼的掌柜王于贵愁眉苦脸地迎上来,“玉大人,你说我怎么就摊上这事。” “怎么了?”我有些...
    开封第一讲书人阅读 150,192评论 0 337
  • 文/不坏的土叔 我叫张陵,是天一观的道长。 经常有香客问我,道长,这世上最难降的妖魔是什么? 我笑而不...
    开封第一讲书人阅读 54,555评论 1 273
  • 正文 为了忘掉前任,我火速办了婚礼,结果婚礼上,老公的妹妹穿的比我还像新娘。我一直安慰自己,他们只是感情好,可当我...
    茶点故事阅读 63,569评论 5 365
  • 文/花漫 我一把揭开白布。 她就那样静静地躺着,像睡着了一般。 火红的嫁衣衬着肌肤如雪。 梳的纹丝不乱的头发上,一...
    开封第一讲书人阅读 48,566评论 1 281
  • 那天,我揣着相机与录音,去河边找鬼。 笑死,一个胖子当着我的面吹牛,可吹牛的内容都是我干的。 我是一名探鬼主播,决...
    沈念sama阅读 37,927评论 3 395
  • 文/苍兰香墨 我猛地睁开眼,长吁一口气:“原来是场噩梦啊……” “哼!你这毒妇竟也来了?” 一声冷哼从身侧响起,我...
    开封第一讲书人阅读 36,583评论 0 257
  • 序言:老挝万荣一对情侣失踪,失踪者是张志新(化名)和其女友刘颖,没想到半个月后,有当地人在树林里发现了一具尸体,经...
    沈念sama阅读 40,827评论 1 297
  • 正文 独居荒郊野岭守林人离奇死亡,尸身上长有42处带血的脓包…… 初始之章·张勋 以下内容为张勋视角 年9月15日...
    茶点故事阅读 35,590评论 2 320
  • 正文 我和宋清朗相恋三年,在试婚纱的时候发现自己被绿了。 大学时的朋友给我发了我未婚夫和他白月光在一起吃饭的照片。...
    茶点故事阅读 37,669评论 1 329
  • 序言:一个原本活蹦乱跳的男人离奇死亡,死状恐怖,灵堂内的尸体忽然破棺而出,到底是诈尸还是另有隐情,我是刑警宁泽,带...
    沈念sama阅读 33,365评论 4 318
  • 正文 年R本政府宣布,位于F岛的核电站,受9级特大地震影响,放射性物质发生泄漏。R本人自食恶果不足惜,却给世界环境...
    茶点故事阅读 38,941评论 3 307
  • 文/蒙蒙 一、第九天 我趴在偏房一处隐蔽的房顶上张望。 院中可真热闹,春花似锦、人声如沸。这庄子的主人今日做“春日...
    开封第一讲书人阅读 29,928评论 0 19
  • 文/苍兰香墨 我抬头看了看天上的太阳。三九已至,却和暖如春,着一层夹袄步出监牢的瞬间,已是汗流浃背。 一阵脚步声响...
    开封第一讲书人阅读 31,159评论 1 259
  • 我被黑心中介骗来泰国打工, 没想到刚下飞机就差点儿被人妖公主榨干…… 1. 我叫王不留,地道东北人。 一个月前我还...
    沈念sama阅读 42,880评论 2 349
  • 正文 我出身青楼,却偏偏与公主长得像,于是被迫代替她去往敌国和亲。 传闻我的和亲对象是个残疾皇子,可洞房花烛夜当晚...
    茶点故事阅读 42,399评论 2 342

推荐阅读更多精彩内容