智慧電子應用設計導論(1/3) Arduino MEGA 2560

Slides:



Advertisements
Similar presentations
Autumn 2012C.-S. Shieh, EC, KUAS, Taiwan1 The 8051 Family Microcontroller Chin-Shiuh Shieh Department of Electronic Engineering.
Advertisements

ECE 480 Design Team 3 Technical Lecture
Lab7: Introduction to Arduino
Anurag Dwivedi & Rudra Pratap Suman.  Open Source electronic prototyping platform based on flexible easy to use hardware and software.
How to use Arduino By: Andrew Hoffmaster.
Lecture 8: Serial Interfaces
Serial Communication Buses: I 2 C and SPI By Brody Dunn.
Intro to AVR ATtiny2313 CS423 Dick Steflik. AVR ATtiny2313.
Aztec PC Oscilloscope Michael Mason Jed Brown Josh Price Andrew Youngs.
Introduction.
Autumn, 2013C.-S. Shieh, EC, KUAS, Taiwan1 智慧電子應用設計導論 (1/3) Communication - Serial Chin-Shiuh Shieh ( 謝欽旭 ) Department.
Khaled A. Al-Utaibi  What is Arduino?  Arduino Boards  Arduino Shields  Arduino Uno Hardware.
Engineering 1040: Mechanisms & Electric Circuits Fall 2011 Introduction to Embedded Systems.
Autumn, 2013C.-S. Shieh, EC, KUAS, Taiwan1 智慧電子應用設計導論 (1/3) Display Chin-Shiuh Shieh ( 謝欽旭 ) Department of Electronic Engineering.
Programming 8-bit PIC Microcontrollers in C Martin Bates Elsevier 2008.
Arduino John Marcoux Christopher Lesch Thomas Dodge Unless otherwise noted, all information and pictures came from:
Dean Brock, Rebecca Bruce and Susan Reiser, CCSC SE 2009 Using Arduino Material taken from Todbot blog Bionic Arduino Todbot blog Bionic ArduinoTodbot.
Little arduino microcontrollers Meghan Jimenez 12 February 2014.
Autumn, 2014C.-S. Shieh, EC, KUAS, Taiwan1 智慧電子應用設計導論 (1/3) Audio Chin-Shiuh Shieh ( 謝欽旭 ) Department of Electronic Engineering.
Autumn, 2012C.-S. Shieh, EC, KUAS, Taiwan1 智慧電子應用設計導論 (1/3) Sensors III Chin-Shiuh Shieh ( 謝欽旭 ) Department of Electronic.
LSU 06/04/2007Expanding the BASIC Stamp1 Expanding the BASIC Stamp: Useful peripherals Programming Unit, Lecture 6.
Footswitch Controller – Hardware System View – Level 0.
Programming ATtinys Paul MacDougal 7/8/13.
Ballooning Bundle. What is a Microcontroller? Small computer with a processor core, memory and programmable input/output Continuously repeats software.
4.0 rtos implementation part II
Arduino Josh Villbrandt February 4, Digital Circuits Analog versus digital – What’s the difference? – How to represent an analog signal in a computer?
Daniel Pickem and Rowland O’Flaherty 12/04/2012 Mechatronics (ME 6405) Student Lecture On Arduinos *Some slides courtesy of Eoin Brazil
Autumn, 2014C.-S. Shieh, EC, KUAS, Taiwan1 智慧電子應用設計導論 (1/3) Digital Input/Output Chin-Shiuh Shieh ( 謝欽旭 ) Department of.
Autumn, 2014C.-S. Shieh, EC, KUAS, Taiwan1 智慧電子應用設計導論 (1/3) Analog Input/Output Chin-Shiuh Shieh ( 謝欽旭 ) Department of.
Arduino. What is it? A open-source software suite and single-board microcontroller. Allows easy and affordable prototyping of microcontroller applications.
Arduino 101 Instructors: Ted Markson / Jim Sweeney.
Autumn, 2014C.-S. Shieh, EC, KUAS, Taiwan1 智慧電子應用設計導論 (1/3) Arduino Programming Language Chin-Shiuh Shieh ( 謝欽旭 ) Department.
MICROCONTROLLER SYSTEMS Part 1. Figure 1.1Elements of a digital controller CPU Central Processing Unit Input Peripherals Output Peripherals ROM Read Only.
Atmel Atmega128 Overview ALU Particulars RISC Architecture 133, Mostly single cycle instructions 2 Address instructions (opcode, Rs, Rd, offset) 32x8 Register.
Unconventional User Interface // // Mood Based Navigation Sheo // 1Haring, Naderer, Zachhuber Arduino  Open Source Project (HW u. SW)  Analog.
Suleyman Demirel University CSS340 Microprocessor Systems – Lecture 2 ATMEGA328P ARCHITECTURE ANALOG INPUTS.
Autumn, 2014C.-S. Shieh, EC, KUAS, Taiwan1 智慧電子應用設計導論 (1/3) Arduino Chin-Shiuh Shieh ( 謝欽旭 ) Department of Electronic Engineering.
Autumn, 2014C.-S. Shieh, EC, KUAS, Taiwan1 智慧電子應用設計導論 (1/3) Arduino Development Environment Chin-Shiuh Shieh ( 謝欽旭 ) Department.
Getting Started With the Arduino Uno
Adam Hendrickson Our project is to design and build an electronic monopoly game console. The console will output the board and sound to a monitor and player.
Autumn, 2013C.-S. Shieh, EC, KUAS, Taiwan1 智慧電子應用設計導論 (1/3) Actuator Chin-Shiuh Shieh ( 謝欽旭 ) Department of Electronic.
Autumn, 2012C.-S. Shieh, EC, KUAS, Taiwan1 智慧電子應用設計導論 (1/3) Sensors I Chin-Shiuh Shieh ( 謝欽旭 ) Department of Electronic.
Autumn, 2014C.-S. Shieh, EC, KUAS, Taiwan1 智慧電子應用設計導論 (1/3) Communication - Serial Chin-Shiuh Shieh ( 謝欽旭 ) Department.
ARDUINO OVERVIEW Bob Wilton – KF5TPQ. ARDUINO UNO.
Microcontroller basics Embedded systems for mortals.
Arduino Microcontroller Technical Details : Arduino (UNO R3) micro-controller ATmega 328 CPU (“industry-standard” micro-controller CPU) ?? MHz clock speed.
Microcontroller basics Embedded systems for mortals.
Autumn, 2012C.-S. Shieh, EC, KUAS, Taiwan1 智慧電子應用設計導論 (1/3) Arduino Development Environment Chin-Shiuh Shieh ( 謝欽旭 ) Department.
Arduino.
Embedded Systems Intro to the Arduino
Michael Rahaim, PhD Candidate Multimedia Communications Lab
Embedded Systems Programming
Microcontroller basics
UTA010 : Engineering Design – II
Table 2. Microcontroller pin description[5]
UCD ElecSoc Robotics Club 2017/2018
Arduino Part 1 Topics: Microcontrollers Programming Basics
INC 161 , CPE 100 Computer Programming
SArduino Training 2018 cho THPT Saigon Institute of Technology
The Arduino Microcontroller: Atmel AVR Atmega 328
ARDUINO     What is an Arduino? Features 14 Digital I/O pins 6 Analogue inputs 6 PWM pins USB serial 16MHz Clock speed 32KB Flash memory 2KB SRAM.
Arduino Board.
AVR – ATmega103(ATMEL) Architecture & Summary
GR-ROSE Pin Map Rev0.2 Serial5 Wire PIN_LED1 PIN_LED2 RX TX CL DA 8 9
智慧電子應用設計導論(1/3) Arduino
Introduction to Arduino
Arduino Board.
Arduino म्हणजे काय?.
Introduction to arduino
Presented By,  Mamata Yadav (BE Elex & Comm.) Vice R&D Coordinator(HW), PCRT  Payal Shah (BE Elex & Comm.)  Ananta Das (BE Elex & Comm.) R&D Team,PCRT.
Presentation transcript:

智慧電子應用設計導論(1/3) Arduino MEGA 2560 Chin-Shiuh Shieh (謝欽旭) http://bit.kuas.edu.tw/~csshieh Department of Electronic Engineering National Kaohsiung University of Applied Sciences, Taiwan Autumn, 2012 C.-S. Shieh, EC, KUAS, Taiwan

C.-S. Shieh, EC, KUAS, Taiwan Arduino Mega 2560 Autumn, 2012 C.-S. Shieh, EC, KUAS, Taiwan

C.-S. Shieh, EC, KUAS, Taiwan Summary Microcontroller: ATmega2560 Operating Voltage: 5V Input Voltage (recommended): 7-12V Digital I/O Pins: 54 of which 15 provide PWM output Analog Input Pins: 16 Flash Memory: 256 KB of which 8 KB used by boot-loader SRAM: 8 KB EEPROM: 4 KB Clock Speed: 16 MHz Autumn, 2012 C.-S. Shieh, EC, KUAS, Taiwan

C.-S. Shieh, EC, KUAS, Taiwan Power The Arduino Mega can be powered via the USB connection or with an external power supply. The power source is selected automatically. The power pins are as follows: VIN: The input voltage to the Arduino board when it's using an external power source. 5V: This pin outputs a regulated 5V from the regulator on the board. 3V3: A 3.3 volt supply generated by the on-board regulator. GND: Ground pins. Autumn, 2012 C.-S. Shieh, EC, KUAS, Taiwan

C.-S. Shieh, EC, KUAS, Taiwan Arduino Mega 2560 Autumn, 2012 C.-S. Shieh, EC, KUAS, Taiwan

C.-S. Shieh, EC, KUAS, Taiwan Memory The ATmega2560 has 256 KB of flash memory for storing code (of which 8 KB is used for the boot-loader) 8 KB of SRAM 4 KB of EEPROM (which can be read and written with the EEPROM library). Autumn, 2012 C.-S. Shieh, EC, KUAS, Taiwan

C.-S. Shieh, EC, KUAS, Taiwan Input and Output Each of the 54 digital pins on the Mega can be used as an input or output, using pinMode(), digitalWrite(), and digitalRead() functions. Some pins have specialized functions: Serial: 0 (RX) and 1 (TX); Serial 1: 19 (RX) and 18 (TX); Serial 2: 17 (RX) and 16 (TX); Serial 3: 15 (RX) and 14 (TX). Used to receive (RX) and transmit (TX) TTL serial data Autumn, 2012 C.-S. Shieh, EC, KUAS, Taiwan

Input and Output (cont) External Interrupts: 2 (interrupt 0), 3 (interrupt 1), 18 (interrupt 5), 19 (interrupt 4), 20 (interrupt 3), and 21 (interrupt 2). These pins can be configured to trigger an interrupt on a low value, a rising or falling edge, or a change in value. See the attachInterrupt() function for details. PWM: 2 to 13 and 44 to 46. Provide 8-bit PWM output with the analogWrite() function. Autumn, 2012 C.-S. Shieh, EC, KUAS, Taiwan

Input and Output (cont) SPI: 50 (MISO), 51 (MOSI), 52 (SCK), 53 (SS). These pins support SPI communication using the SPI library. LED: 13. There is a built-in LED connected to digital pin 13. When the pin is HIGH value, the LED is on, when the pin is LOW, it's off. TWI: 20 (SDA) and 21 (SCL). Support TWI communication using the Wire library. Autumn, 2012 C.-S. Shieh, EC, KUAS, Taiwan

C.-S. Shieh, EC, KUAS, Taiwan Communication The ATmega2560 provides four hardware UARTs for TTL (5V) serial communication. An ATmega16U2 on the board channels RX0/TX0 over USB and provides a virtual com port to software on the computer. The Arduino software includes a serial monitor which allows simple textual data to be sent to and from the board. Autumn, 2012 C.-S. Shieh, EC, KUAS, Taiwan

C.-S. Shieh, EC, KUAS, Taiwan Communication (cont) The ATmega2560 also supports TWI and SPI communication. The Arduino software includes a Wire library to simplify use of the TWI bus. For SPI communication, use the SPI library. Autumn, 2012 C.-S. Shieh, EC, KUAS, Taiwan

C.-S. Shieh, EC, KUAS, Taiwan Analog Input The Mega2560 has 16 analog inputs, each of which provide 10 bits of resolution (i.e. 1024 different values). By default they measure from ground to 5 volts, though is it possible to change the upper end of their range using the AREF pin and analogReference() function. Autumn, 2012 C.-S. Shieh, EC, KUAS, Taiwan

C.-S. Shieh, EC, KUAS, Taiwan Programming The Arduino Mega can be programmed with the Arduino software. The ATmega2560 on the Arduino Mega comes pre-burned with a boot-loader that allows you to upload new code to it without the use of an external hardware programmer. Automatic (software) reset after uploading. Autumn, 2012 C.-S. Shieh, EC, KUAS, Taiwan