¾ÆµÎÀÌ³ë ±âÃÊ

 

1. ¾ÆµÎÀ̳ë¶õ?

- ¸¶ÀÌÅ©·ÎÄÁÆ®·Ñ·¯ ±â¹Ý ÀüÀÚÀÛÇ°(electronic projects) ±¸Çö(±³À°¿ë)À» À§ÇÑ ¿ÀǼҽº Ç÷§Æû( = Çϵå¿þ¾î+¼ÒÇÁÆ®¿þ¾î ±â¹Ý)

- ¾ÆµÎÀ̳뿡¼­ ½ÇÇàµÇ´Â  ÇÁ·Î±×·¥À» 'sketch'¶ó ÇÔ.

 

2. 1. What is an Arduino?

- An open-source platform used for building electronics projects

 

- The Arduino does not need a separate piece of hardware (called a programmer) in order to load new code onto the board. You can simply use a USB cable.

 

2. What is an Arduino consisted of?

- A physical programmable circuit board

    alt text

- IDE (integrated development environment): to make a program and download it to an Arduino board

    Arduino Uno

The Arduino IDE uses a simplified version of C++, making it easier to learn to program. 

 

- Input and output devices: user selected

    alt text

 

3. What's in an Arduino board?

(±âº» Á¤º¸)

- Example: Arduino Uno º¸µå

https://cdn.sparkfun.com/assets/b/f/e/9/c/513824face395f6d3d000000.png

1 = USB ´ÜÀÚ: PC¿Í ¿¬°áÇÏ¿© ÇÁ·Î±×·¥À» PC·ÎºÎÅÍ º¸µå·Î ´Ù¿î·Îµå, ¿ÜºÎ·ÎºÎÅÍ Àü¿ø°ø±Þ

2 = barrel jack: ¿ÜºÎ·ÎºÎÅÍ Àü¿ø°ø±Þ

3 = GND: 0V Àü¿øÁ¢Áö, ¿ÜºÎ¿¡ Àü¿ø °ø±Þ ½Ã »ç¿ë

4 = 5V: Àü¿ø´ÜÀÚ, ¿ÜºÎ¿¡ Àü¿ø °ø±Þ ½Ã »ç¿ë

5 = 3.3V: Àü¿ø´ÜÀÚ, ¿ÜºÎ¿¡ Àü¿ø °ø±Þ ½Ã »ç¿ë

6 = Analog: ¾Æ³¯·Î±× Àü¾Ð ÀÔ·Â ´ÜÀÚ. A0ºÎÅÍ A5±îÁö ÃÑ 6°³ ÇÉ. ¾Æ³¯·Î±× ½ÅÈ£´Â ¸¶ÀÌÅ©·ÎÄÁÆ®·Ñ·¯¿¡ ÀÇÇØ µðÁöÅзΠº¯È¯µÇ1°í °ªÀÌ Æǵ¶µÇ¾î ÇÁ·Î±×·¥¿¡¼­ »ç¿ëÇÒ ¼ö ÀÖ´Ù.

7 = Digital: µðÁöÅÐ ½ÅÈ£ ´ÜÀÚ. 0-13¹ø±îÁö ÃÑ 14°³ ÇÉ. ÇÁ·Î±×·¥¿¡¼­ Á¤ÀÇÇϱ⿡ µû¶ó Ãâ·Â ¶Ç´Â ÀÔ·ÂÀ¸·Î »ç¿ëÇÒ ¼ö ÀÖ´Ù. 0V¿Í 5VÀÇ µÎ °ª Áß¿¡ Çϳª¸¦ °¡Áø´Ù.

8 = PWM: 3,5,6,9,10,11¹ø ÃÑ 6°³ ´ÜÀÚ. µðÁöÅÐ ½ÅÈ£ÀÇ ÆÞ½ºÆøÀ» °¡º¯ÇÏ¿© ¿ÜºÎÀåÄ¡ Á¦¾î¿¡ »ç¿ëÇÏ´Â ´ÜÀÚ

9 = AREF: analog reference. ¿ÜºÎÀü¾ÐÀÇ ±âÁØ°ª ¼³Á¤¿¡ »ç¿ë

10 = RESET: ¾ÆµÎÀÌ³ë º¸µå¿¡ ´Ù¿î·ÎµåµÇ¾î ½ÇÇà ÁßÀÎ ÇÁ·Î±×·¥À» óÀ½ºÎÅÍ ´Ù½Ã ½ÃÀÛ

11 = POWER LED: ¾ÆµÎÀÌ³ë º¸µå¿¡ Àü¿øÀÌ °ø±ÞµÈ »óÅ ǥ½Ã

12 = TX RX LEDs: PC¿Í ¾ÆµÎÀÌ³ë º¸µå°¡ ½ÅÈ£¸¦ º¸³¾ °æ¿ì (¼Û½Å, Tx; transmit) LED°¡ Á¡µî, ¹ÞÀ» °æ¿ì (¼ö½Å, Rx; receive) LED°¡ Á¡µî

13 = MCU: microcontroller unit. Atmel ATMEGA 328P. PC¿¡¼­ ´Ù¿î·ÎµåµÈ ÇÁ·Î±×·¥À» ¼öÇàÇϴ Ĩ. ¾ÆµÎÀÌ³ë º¸µåÀÇ µÎ³ú¿ªÇÒ. ¿¬»ê ±â´É, ¸Þ¸ð¸® ±â´É, ÀÔÃâ·Â ±â´ÉÀ» ¼öÇà

14 = Votage Regulator: »ç¿ëÀÚ°¡ °ø±ÞÇÑ Àü¾Ð(7-15V)À» ¾ÆµÎÀÌ³ë º¸µå¿¡¼­ ÇÊ¿äÇÑ 5V·Î º¯È¯

 

(°í±Þ Á¤º¸)

ArduinoUno_R3_Pinouts (2)

 

- ICSP (in-circuit serial programming) ÇÉ: MCUÀÇ ½Ãµ¿ ÇÁ·Î±×·¥(bootloader)¸¦ À缳ġÇϱâ À§ÇÑ ÇÉ

(»ó¼¼ Á¤º¸)

UNO ISP

It¡¯s very uncommon to program ICs before they are soldered onto a PCB. Instead, most microcontrollers have what¡¯s called an in-system programming (ISP) header. Particularly, some IC manufacturers, such as Atmel and Microchip, have a specialized ISP method for programming their ICs. This is referred to as in-circuit serial programming (ICSP). Most Arduino and Arduino compatible boards will have a 2x3 pin ICSP header on them. Some may even have more than one depending on how many ICs live on the PCB. It breaks out three of the SPI (serial peripheral interface) pins (MISO, MOSI, SCK), and power, ground, and reset. These are the pins you¡¯ll need to connect your programmer to in order to reflash the firmware on your board.

 

- bootloader: ¸¶ÀÌÅ©·ÎÄÁÆ®·Ñ·¯ÀÇ µ¿ÀÛÀ» °³½ÃÇÏ´Â ÇÁ·Î±×·¥. ¸ðµç MCU¿¡ ³»ÀåµÇ¾î ÀÖÀ½. PCÀÇ BIOS¿¡ ÇØ´ç

(»ó¼¼)

What is a bootloader?

  The bootloader is basically a .hex file that runs when you turn on the board. It is very similar to the BIOS that runs on your PC. It does two things. First, it looks around to see if the computer is trying to program it. If it is, it grabs the program from the computer and uploads it into the ICs memory (in a specific location so as not to overwrite the bootloader). That is why when you try to upload code, the Arduino IDE resets the chip. This basically turns the IC off and back on again so the bootloader can start running again. If the computer isn¡¯t trying to upload code, it tells the chip to run the code that¡¯s already stored in memory. Once it locates and runs your program, the Arduino continuously loops through the program and does so as long as the board has power.

Why install a bootloader in an Arduino?

  If you are building your own Arduino, or need to replace the IC, you will need to install the bootloader. There are also cases where you¡¯ve put your board in a weird setting and reinstalling the bootloader and getting it back to factory settings is the easiest way to fix it.

Selecting a programmer (a hardware board) to install a bootloader

     AVR Procket Programmer

     Atmel JTAG ICE3 Programmer

Using the Arduino as a programmer

   The other option is grabbing an Arduino Uno. If you go into the Arduino IDE you will see an example sketch called ¡®Arduino as ISP.¡¯ If you upload this code to your Arduino, it will basically act as an AVR programmer. As of this writing the code only works on ATmega328 boards.

Bootloader is already installed in the Arduino

   The Arduino has largely done away with the blootloader issues. They¡¯ve put a .hex file on their AVR chips that allows you to program the board over the serial port, meaning all you need to program your Arduino is a USB cable.

 

- I2C/TWI: MCU °£ÀÇ Àú¼Ó Åë½Å

(»ó¼¼)

- ȸ·Î »ó¿¡¼­ ÀåÄ¡µéÀÌ ¾î¶»°Ô Åë½ÅÇÒ °ÍÀÎÁö Çʸ³½º »ç°¡ 1980³â´ë °í¾ÈÇÑ BUS ¹æ½Ä

- SDA(Serial Data Line), SLK(Serial Clock)¶ó ºÎ¸£´Â 2 °³ÀÇ ¿¬°á¸¸ »ç¿ë

- ´Ü 2°³ÀÇ ¿¬°áÀ» »ç¿ëÇÏ´Â ¹æ½ÄÀ̾ Two Wire Interface, Áï TWI¶ó°í ºÎ¸£±âµµ ÇÑ´Ù.

- ÇϳªÀÇ ¸¶½ºÅÍ(Master) ÀåÄ¡¿Í ¿©·¯ °³ÀÇ ½½·¹À̺ê(Slave) ÀåÄ¡°¡ ÀÌ µÎ ȸ¼±À» ÅëÇØ ¿¬°á

- ´ÙÀ½Àº Arduino UNO º¸µåÀÇ A4, A5¸¦ ¿¬°áÇÑ ±×¸²ÀÌ´Ù. SDA, SLK 2°³ ´ÜÀÚ¿Í Á¢Áö´ÜÀÚ¸¦ ¿¬°áÇÑ´Ù.

 

   i2c-bw-uno

4. Arduino º¸µå Á¾·ù

- Arduino Uno (R3) :

alt text

 

- LilyPad Arduino:

alt text

 

- RedBoard:

https://cdn.sparkfun.com/assets/0/9/4/7/3/515b53d7ce395fc351000000.png

 

- Arduino Mega (R3):

https://cdn.sparkfun.com/assets/9/2/3/f/f/515b547fce395f853c000007.png

 

- Arduino Leonardo:

alt text

 

- Arduino Shields:

They are pre-built circuit boards that fit on top of your Arduino and provide additional capabilities – controlling motors, connecting to the internet, providing cellular or other wireless communication, controlling an LCD screen, and much more.

alt text

 

[Âü°í¹®Çå]

1. DC: Arduino Uno

2. Lee: Arduino