A microcontroller is a computer on a single integrated chip that contains a processor, memory, and input/output ports. Common microcontroller families include Intel, Atmel, Microchip, and ARM. Microcontrollers are used in devices like cellphones, toys, appliances, cars, and cameras. The Arduino is a popular open-source hardware and software platform for building prototypes and interactive objects. It uses a simple programming language based on C/C++ and is inexpensive and easy to use.
To develop a home automation system with a RF controlled remote. As technology is advancing so houses are also getting smarter. Modern houses are gradually shifting from conventional switches to centralized control system, involving RF controlled switches.
The TMS320C5x DSP architecture is based on the C25 with some enhancements. It uses a Harvard architecture with separate program and data memory buses. The CPU contains a CALU for arithmetic, PLU for logic, and ARAU for address calculations. On-chip memory includes ROM, DARAM, and SARAM. Peripherals include serial ports, timers, interrupts, and I/O. The architecture provides high performance with low power consumption and compatibility with prior C series DSPs.
1) The document presents information about a magic tee, which is a waveguide component used in microwave engineering systems.
2) A magic tee has four ports and is able to split or combine signals passing through in specific ways depending on which port is used.
3) The document discusses the working, operation, and S-matrix of a magic tee. It also provides examples of how magic tees can be used for applications like impedance measurement, duplexing, and mixing.
This document provides an introduction to pins, ports, and configuring pins on the ARM LPC2148 microcontroller. It discusses pin configuration, the different ports on the LPC2148, and how to configure pins as inputs, outputs, or alternate functions using the various IO registers. It also provides an example program for blinking an LED connected to pin P1.16 to demonstrate basic pin configuration and output. The document concludes with an assignment to draw the LED blinking circuit and modify the program to blink LEDs on pins P0.16 through P0.23.
This document describes a circuit that allows home appliances to be controlled using an infrared remote control. The circuit consists of a transmitter that sends infrared signals using a 555 timer chip and an IR LED. The receiver uses a TSOP1738 IR sensor and CD4017 counter IC to receive and decode the IR signals, then trigger a relay to turn the appliance on or off. The circuit was designed to have a range of up to 10 meters and provide a low-cost way to remotely control appliances like lamps, fans, and radios.
pull up to pull down ratio of nmos inverter driven by another nmos inverter and also another describing with pass transistor. Transistor sizing with example and some formulas
This document provides an overview of digital signal processors (DSPs). It defines a DSP as an integrated circuit designed for high-speed data manipulation used in applications such as audio, communications, and image processing. The document discusses how DSPs work by converting analog signals to digital signals and processing them. It explains that DSPs are needed because they can perform multiplication and division faster than general-purpose processors. The rest of the document details the architecture of DSPs, examples of DSP chip families like TMS320, and how instruction pipelining is implemented on the TMS320C54X DSP processor.
The NodeMCU is an ESP8266 development board that contains a 32-bit RISC CPU, 64KB of instruction RAM, 96KB of data RAM, and external flash memory. It supports WiFi, GPIO pins, SPI, I2C, PWM and ADC interfaces. Official firmware includes Lua, Micropython, and Espruino scripting languages as well as support for Arduino IDE. It is inexpensive, functional, and has a large community supporting its use and development.
To develop a home automation system with a RF controlled remote. As technology is advancing so houses are also getting smarter. Modern houses are gradually shifting from conventional switches to centralized control system, involving RF controlled switches.
The TMS320C5x DSP architecture is based on the C25 with some enhancements. It uses a Harvard architecture with separate program and data memory buses. The CPU contains a CALU for arithmetic, PLU for logic, and ARAU for address calculations. On-chip memory includes ROM, DARAM, and SARAM. Peripherals include serial ports, timers, interrupts, and I/O. The architecture provides high performance with low power consumption and compatibility with prior C series DSPs.
1) The document presents information about a magic tee, which is a waveguide component used in microwave engineering systems.
2) A magic tee has four ports and is able to split or combine signals passing through in specific ways depending on which port is used.
3) The document discusses the working, operation, and S-matrix of a magic tee. It also provides examples of how magic tees can be used for applications like impedance measurement, duplexing, and mixing.
This document provides an introduction to pins, ports, and configuring pins on the ARM LPC2148 microcontroller. It discusses pin configuration, the different ports on the LPC2148, and how to configure pins as inputs, outputs, or alternate functions using the various IO registers. It also provides an example program for blinking an LED connected to pin P1.16 to demonstrate basic pin configuration and output. The document concludes with an assignment to draw the LED blinking circuit and modify the program to blink LEDs on pins P0.16 through P0.23.
This document describes a circuit that allows home appliances to be controlled using an infrared remote control. The circuit consists of a transmitter that sends infrared signals using a 555 timer chip and an IR LED. The receiver uses a TSOP1738 IR sensor and CD4017 counter IC to receive and decode the IR signals, then trigger a relay to turn the appliance on or off. The circuit was designed to have a range of up to 10 meters and provide a low-cost way to remotely control appliances like lamps, fans, and radios.
pull up to pull down ratio of nmos inverter driven by another nmos inverter and also another describing with pass transistor. Transistor sizing with example and some formulas
This document provides an overview of digital signal processors (DSPs). It defines a DSP as an integrated circuit designed for high-speed data manipulation used in applications such as audio, communications, and image processing. The document discusses how DSPs work by converting analog signals to digital signals and processing them. It explains that DSPs are needed because they can perform multiplication and division faster than general-purpose processors. The rest of the document details the architecture of DSPs, examples of DSP chip families like TMS320, and how instruction pipelining is implemented on the TMS320C54X DSP processor.
The NodeMCU is an ESP8266 development board that contains a 32-bit RISC CPU, 64KB of instruction RAM, 96KB of data RAM, and external flash memory. It supports WiFi, GPIO pins, SPI, I2C, PWM and ADC interfaces. Official firmware includes Lua, Micropython, and Espruino scripting languages as well as support for Arduino IDE. It is inexpensive, functional, and has a large community supporting its use and development.
The document discusses interfacing LEDs with microcontrollers. It explains that LEDs are PN junction semiconductors that emit monochromatic light when forward-biased. It describes the data direction register (DDR) which determines whether pins on a given port are inputs or outputs. It also discusses the PORT register which sets the data values on pins. Finally, it provides a code example that blinks LEDs connected to port C using these registers and a delay function.
The document describes the components and circuit diagram for a door locker system controlled by an 8051 microcontroller. The system uses a keypad to enter a password which is checked by the microcontroller to open the door if correct. It lists the components used including the 8051 microcontroller, stepper motor, diodes, resistors, crystal oscillator, voltage regulator, capacitors, momentary switches, and LCD. It then provides details on each component and their purpose in the system before presenting the circuit diagram.
Introduction to Arduino Hardware and ProgrammingEmmanuel Obot
Introduction to Arduino Hardware and Programming:
Arduino is an open-source electronics platform based on easy-to-use hardware and software. It's intended for anyone making interactive projects.
Teachers and students use it to build low cost scientific instruments, to prove chemistry and physics principles, or to get started with programming and robotics. Designers and architects build interactive prototypes, musicians and artists use it for installations and to experiment with new musical instruments. Makers, of course, use it to build many of the projects exhibited at the Maker Faire. Arduino is a key tool to learn new things. Anyone - children, hobbyists, artists, programmers can use it to build an interactive device.
A signal is a pattern of variation that carry information.
Signals are represented mathematically as a function of one or more independent variable
basic concept of signals
types of signals
system concepts
Basics of Colour Television and Digital TVjanakiravi
Main characteristics of human eye with regard to perception of colours-mixing of colours. three standards of colour transmission system, CATV, DTH, HDTV & SMART TV
For TS-SBTET, C-18, DECE 6 Unit, By Nenavath Ravi Kumar, MIST Hyderabad
This document provides an introductory presentation on the Raspberry Pi single board computer. It discusses what Raspberry Pi is, its low cost, support for education and programming. It describes the different models and their technical specifications. It also covers setting up Raspberry Pi, installing an operating system, using the Linux shell and commands, programming languages supported, and interfacing with GPIO pins to control hardware. Projects discussed include a home automation system and an LED blink example using GPIO pins.
Cadbridge Semiconductor is an emerging electronics company with offices in Greater Noida and Jalander that works on projects involving memories, PCB design, digital security locks, robots, image processing, and microcontrollers. The company's vision is to hire and develop the best talent worldwide in a multicultural environment. The VLSI design flow presented includes idea conception, specification, design architecture, RTL coding, RTL verification, synthesis, sending to a foundry, and producing an IC chip. Application areas of VLSI discussed were microprocessors, memories, and mobile devices.
3.Frequency Domain Representation of Signals and SystemsINDIAN NAVY
This document provides an overview of frequency domain representation of signals and systems. It defines key concepts such as the Fourier transform, which converts a signal from the time domain to the frequency domain. The frequency spectrum shows the distribution of frequencies within a signal. Periodic signals can be represented using Fourier series, while aperiodic signals use the Fourier transform. Properties of the Fourier transform such as linearity, time shifting, and the convolution theorem are also covered.
This document discusses switch level modeling in Verilog. It describes different types of transistor switches that can be used as primitives in Verilog, including nmos, pmos, rnmos, rpmos, and cmos switches. It also covers bidirectional switches like tran, tranif1, and examples of how to use the switches to model basic logic gates and memory cells like a RAM cell. Time delays can be specified for switches. Switch level modeling allows designing circuits using transistors directly in Verilog.
5. Signal flow graph, Mason’s gain formula.pptxAMSuryawanshi
This document provides an overview of a lecture on signal flow graphs and Mason's gain formula in control systems engineering. Key points covered include:
- Signal flow graphs can represent algebraic equations graphically using nodes and branches. Mason's gain formula can be used to determine the transfer function of a linear signal flow graph.
- The lecture outlines concepts like input/output/mixed nodes, branches, path and loop gains, and non-touching loops. It provides an example of constructing a signal flow graph from equations.
- Mason's gain formula is presented to calculate the transfer function between the input and output nodes of a signal flow graph based on its forward path gains and loop gains.
- The session concludes
This document provides information about reversible logic gates and their application in field programmable gate arrays (FPGAs). It describes the design of reversible 4-to-1 multiplexers, D latches, and master-slave flip flops using novel reversible gates. The proposed reversible designs have fewer components and lower cost compared to existing irreversible circuit designs. In conclusion, the document presents the first proposed design of a reversible logic block for FPGAs, improving the efficiency of sequential circuits used to realize FPGA functions.
This document provides information on fundamental antenna parameters and concepts. It discusses:
1. How antennas convert guided waves into radiating waves and vice versa.
2. Key antenna parameters including radiation pattern, directivity, radiation resistance, efficiency, gain, bandwidth, reciprocity, effective aperture, beamwidth, and polarization matching.
3. The Friis transmission formula for calculating received power between two antennas in free space based on their gains, wavelength, and distance.
Introduction to Embedded System I: Chapter 2 (5th portion)Moe Moe Myint
The document provides an introduction to embedded systems, outlining key components and concepts. It discusses the core of embedded systems including processors, programmable logic devices, and memory. Sensors, actuators, and communication interfaces are also reviewed. Embedded firmware, other system components like reset circuits and watchdogs, and printed circuit boards are examined. The objectives are to learn about the building blocks of embedded systems and factors in selecting components.
A microcontroller is a small computer on a single integrated circuit containing a processor core, memory, and programmable input/output peripherals. It is used in embedded systems to make decisions. The AVR ATmega8 is an 8-bit microcontroller based on Harvard architecture. It has 8KB of flash memory, 512B of EEPROM, and 1KB of SRAM. It contains peripherals like timers, PWM channels, ADC, and serial interfaces. The ATmega8 comes in PDIP and TQFP packages and uses three registers - DDRx, PORTx, and PINx - to communicate with its I/O ports.
This document discusses Nyquist's criterion for distortionless transmission of binary signals over a baseband channel. It states that intersymbol interference (ISI) can be eliminated by choosing a transmit filter response P(f) that satisfies the Nyquist criterion. An ideal rectangular pulse shape meets the criterion but is physically unrealizable. A more practical raised cosine pulse is proposed, which introduces a rolloff factor to trade off excess bandwidth for slower decay. The full-cosine case provides additional zero-crossings that aid synchronization but doubles the bandwidth.
FM transmitters and receivers are used for sending and receiving FM signals. Transmitters modulate a carrier wave with an audio signal to generate an FM signal, which is transmitted through a band. Receivers receive the modulated signal, demodulate it to extract the original audio signal. FM offers advantages over AM like noise reduction, improved fidelity, and more efficient power use, though it requires more complex circuits and a larger bandwidth. Applications of FM include radio broadcasting, mobile radio, TV sound, and cellular/satellite communication.
Arduino Uno is a microcontroller board based on 8-bit ATmega328P microcontroller. Along with ATmega328P, it consists other components such as crystal oscillator, serial communication, voltage regulator, etc. to support the microcontroller. Arduino Uno has 14 digital input/output pins (of which 6 can be used as PWM outputs), 6 analog inputs, a 16 MHz ceramic resonator, a USB connection, a power jack, an ICSP header, and a reset button.
LEDs are of interest for fibre optics because of five inherent characteristics..
How it works?
Spectrum of an LED
Modulation of LED
LED Vs. Laser diode
disadvantages of LED
Arduino is an open-source hardware and software platform for building interactive electronic projects. It consists of a programmable microcontroller board and IDE software to write code. The board contains ports that can be configured as digital or analog inputs/outputs to interact with sensors, LEDs, motors and other components. Common Arduino boards include the Uno, Nano, Mega and Leonardo, which differ in processor, memory and I/O pins. The ATmega328P microcontroller on the Uno uses a Harvard architecture with separate memory and buses for instructions and data, allowing simultaneous access.
The document provides information about Experiment No. 1 which aims to study IOT microcontrollers Arduino and Raspberry Pi. It describes the hardware components and specifications of the Arduino Uno board including the microcontroller, pins, and programming. It also discusses how to program and use the Arduino board for digital and analog input/output. The document then summarizes the generations and components of the Raspberry Pi 3 Model B microcontroller board including its processor, memory, and wireless capabilities.
The document discusses interfacing LEDs with microcontrollers. It explains that LEDs are PN junction semiconductors that emit monochromatic light when forward-biased. It describes the data direction register (DDR) which determines whether pins on a given port are inputs or outputs. It also discusses the PORT register which sets the data values on pins. Finally, it provides a code example that blinks LEDs connected to port C using these registers and a delay function.
The document describes the components and circuit diagram for a door locker system controlled by an 8051 microcontroller. The system uses a keypad to enter a password which is checked by the microcontroller to open the door if correct. It lists the components used including the 8051 microcontroller, stepper motor, diodes, resistors, crystal oscillator, voltage regulator, capacitors, momentary switches, and LCD. It then provides details on each component and their purpose in the system before presenting the circuit diagram.
Introduction to Arduino Hardware and ProgrammingEmmanuel Obot
Introduction to Arduino Hardware and Programming:
Arduino is an open-source electronics platform based on easy-to-use hardware and software. It's intended for anyone making interactive projects.
Teachers and students use it to build low cost scientific instruments, to prove chemistry and physics principles, or to get started with programming and robotics. Designers and architects build interactive prototypes, musicians and artists use it for installations and to experiment with new musical instruments. Makers, of course, use it to build many of the projects exhibited at the Maker Faire. Arduino is a key tool to learn new things. Anyone - children, hobbyists, artists, programmers can use it to build an interactive device.
A signal is a pattern of variation that carry information.
Signals are represented mathematically as a function of one or more independent variable
basic concept of signals
types of signals
system concepts
Basics of Colour Television and Digital TVjanakiravi
Main characteristics of human eye with regard to perception of colours-mixing of colours. three standards of colour transmission system, CATV, DTH, HDTV & SMART TV
For TS-SBTET, C-18, DECE 6 Unit, By Nenavath Ravi Kumar, MIST Hyderabad
This document provides an introductory presentation on the Raspberry Pi single board computer. It discusses what Raspberry Pi is, its low cost, support for education and programming. It describes the different models and their technical specifications. It also covers setting up Raspberry Pi, installing an operating system, using the Linux shell and commands, programming languages supported, and interfacing with GPIO pins to control hardware. Projects discussed include a home automation system and an LED blink example using GPIO pins.
Cadbridge Semiconductor is an emerging electronics company with offices in Greater Noida and Jalander that works on projects involving memories, PCB design, digital security locks, robots, image processing, and microcontrollers. The company's vision is to hire and develop the best talent worldwide in a multicultural environment. The VLSI design flow presented includes idea conception, specification, design architecture, RTL coding, RTL verification, synthesis, sending to a foundry, and producing an IC chip. Application areas of VLSI discussed were microprocessors, memories, and mobile devices.
3.Frequency Domain Representation of Signals and SystemsINDIAN NAVY
This document provides an overview of frequency domain representation of signals and systems. It defines key concepts such as the Fourier transform, which converts a signal from the time domain to the frequency domain. The frequency spectrum shows the distribution of frequencies within a signal. Periodic signals can be represented using Fourier series, while aperiodic signals use the Fourier transform. Properties of the Fourier transform such as linearity, time shifting, and the convolution theorem are also covered.
This document discusses switch level modeling in Verilog. It describes different types of transistor switches that can be used as primitives in Verilog, including nmos, pmos, rnmos, rpmos, and cmos switches. It also covers bidirectional switches like tran, tranif1, and examples of how to use the switches to model basic logic gates and memory cells like a RAM cell. Time delays can be specified for switches. Switch level modeling allows designing circuits using transistors directly in Verilog.
5. Signal flow graph, Mason’s gain formula.pptxAMSuryawanshi
This document provides an overview of a lecture on signal flow graphs and Mason's gain formula in control systems engineering. Key points covered include:
- Signal flow graphs can represent algebraic equations graphically using nodes and branches. Mason's gain formula can be used to determine the transfer function of a linear signal flow graph.
- The lecture outlines concepts like input/output/mixed nodes, branches, path and loop gains, and non-touching loops. It provides an example of constructing a signal flow graph from equations.
- Mason's gain formula is presented to calculate the transfer function between the input and output nodes of a signal flow graph based on its forward path gains and loop gains.
- The session concludes
This document provides information about reversible logic gates and their application in field programmable gate arrays (FPGAs). It describes the design of reversible 4-to-1 multiplexers, D latches, and master-slave flip flops using novel reversible gates. The proposed reversible designs have fewer components and lower cost compared to existing irreversible circuit designs. In conclusion, the document presents the first proposed design of a reversible logic block for FPGAs, improving the efficiency of sequential circuits used to realize FPGA functions.
This document provides information on fundamental antenna parameters and concepts. It discusses:
1. How antennas convert guided waves into radiating waves and vice versa.
2. Key antenna parameters including radiation pattern, directivity, radiation resistance, efficiency, gain, bandwidth, reciprocity, effective aperture, beamwidth, and polarization matching.
3. The Friis transmission formula for calculating received power between two antennas in free space based on their gains, wavelength, and distance.
Introduction to Embedded System I: Chapter 2 (5th portion)Moe Moe Myint
The document provides an introduction to embedded systems, outlining key components and concepts. It discusses the core of embedded systems including processors, programmable logic devices, and memory. Sensors, actuators, and communication interfaces are also reviewed. Embedded firmware, other system components like reset circuits and watchdogs, and printed circuit boards are examined. The objectives are to learn about the building blocks of embedded systems and factors in selecting components.
A microcontroller is a small computer on a single integrated circuit containing a processor core, memory, and programmable input/output peripherals. It is used in embedded systems to make decisions. The AVR ATmega8 is an 8-bit microcontroller based on Harvard architecture. It has 8KB of flash memory, 512B of EEPROM, and 1KB of SRAM. It contains peripherals like timers, PWM channels, ADC, and serial interfaces. The ATmega8 comes in PDIP and TQFP packages and uses three registers - DDRx, PORTx, and PINx - to communicate with its I/O ports.
This document discusses Nyquist's criterion for distortionless transmission of binary signals over a baseband channel. It states that intersymbol interference (ISI) can be eliminated by choosing a transmit filter response P(f) that satisfies the Nyquist criterion. An ideal rectangular pulse shape meets the criterion but is physically unrealizable. A more practical raised cosine pulse is proposed, which introduces a rolloff factor to trade off excess bandwidth for slower decay. The full-cosine case provides additional zero-crossings that aid synchronization but doubles the bandwidth.
FM transmitters and receivers are used for sending and receiving FM signals. Transmitters modulate a carrier wave with an audio signal to generate an FM signal, which is transmitted through a band. Receivers receive the modulated signal, demodulate it to extract the original audio signal. FM offers advantages over AM like noise reduction, improved fidelity, and more efficient power use, though it requires more complex circuits and a larger bandwidth. Applications of FM include radio broadcasting, mobile radio, TV sound, and cellular/satellite communication.
Arduino Uno is a microcontroller board based on 8-bit ATmega328P microcontroller. Along with ATmega328P, it consists other components such as crystal oscillator, serial communication, voltage regulator, etc. to support the microcontroller. Arduino Uno has 14 digital input/output pins (of which 6 can be used as PWM outputs), 6 analog inputs, a 16 MHz ceramic resonator, a USB connection, a power jack, an ICSP header, and a reset button.
LEDs are of interest for fibre optics because of five inherent characteristics..
How it works?
Spectrum of an LED
Modulation of LED
LED Vs. Laser diode
disadvantages of LED
Arduino is an open-source hardware and software platform for building interactive electronic projects. It consists of a programmable microcontroller board and IDE software to write code. The board contains ports that can be configured as digital or analog inputs/outputs to interact with sensors, LEDs, motors and other components. Common Arduino boards include the Uno, Nano, Mega and Leonardo, which differ in processor, memory and I/O pins. The ATmega328P microcontroller on the Uno uses a Harvard architecture with separate memory and buses for instructions and data, allowing simultaneous access.
The document provides information about Experiment No. 1 which aims to study IOT microcontrollers Arduino and Raspberry Pi. It describes the hardware components and specifications of the Arduino Uno board including the microcontroller, pins, and programming. It also discusses how to program and use the Arduino board for digital and analog input/output. The document then summarizes the generations and components of the Raspberry Pi 3 Model B microcontroller board including its processor, memory, and wireless capabilities.
The document introduces the Arduino microcontroller board. It describes the Arduino as an easy-to-use and inexpensive platform for physical computing. Key components of the Arduino include an ATmega328P microcontroller, digital and analog input/output pins, a USB connection for programming, and a standard pin layout that allows connection of expansion boards. The document provides an overview of the Arduino's capabilities and use in interactive projects.
The Arduino Nano is a small, breadboard-friendly board based on the ATmega328 or ATmega168 microcontroller. It has 14 digital input/output pins, 8 analog inputs, a 16 MHz crystal oscillator, a micro USB connection, ICSP headers, and a reset button. The Nano can be programmed with the Arduino IDE and powered via USB or an external power source.
The document discusses the Arduino Nano development board. It provides an overview of the board's specifications including its microcontroller, operating voltage, analog and digital pins, memory, and communication interfaces. It also compares the Nano to the Arduino Uno and Arduino Mega boards, highlighting their differences in size, programming, and technical specifications. The document then provides instructions on how to power and program the Nano board using the Arduino IDE and examples.
This document discusses automating an office environment using various sensors. It describes using RFID cards to automatically identify and greet employees upon entry. Motion detectors and a flame sensor are used for energy saving, automatic control of electronics, and fire safety. The objectives are to create a secure, safe working environment with automatic door control, lighting/device control based on presence detection, and fire alerts. Required hardware includes an Arduino, RFID components, sensors, and display. Software includes the Arduino IDE. Detailed descriptions of the Arduino, servo motor, and flame sensor components are also provided.
The document discusses several embedded application development platforms including Arduino, Raspberry Pi, Tiva C Series, and MSP430. It provides overview information on each platform, including key components, features, programming languages supported, and examples of applications. For Arduino, it describes the Arduino Uno board in detail. For Raspberry Pi, it outlines the basic specifications and components. For Tiva C Series and MSP430, it summarizes the development boards and features of the microcontrollers.
Touch Switch (Smart Switches) by arduino Project report fileimkanhaiyalal
The document provides details about the Arduino Mega 2560 microcontroller board. It has an ATmega2560 microcontroller, 54 digital input/output pins, 16 analog inputs, and is commonly used for beginner electronic projects and prototyping. The board can be powered via USB or an external power supply. It has 256KB of flash memory for storing code, 8KB of SRAM for variables, and communicates using serial communication and protocols like I2C and SPI. Programming the board involves using the Arduino IDE to compile code and upload it via the micro-USB connection.
The Arduino Uno is a microcontroller board based on the ATmega328 with 14 digital input/output pins, 6 analog inputs, a USB connection, and a power jack. It contains everything needed to support the microcontroller and can be programmed using the Arduino IDE. The Uno differs from previous boards by using an Atmega8U2 as a USB-to-serial converter instead of an FTDI chip. It is the latest and reference version of the Arduino platform.
The Arduino Uno is a microcontroller board based on the ATmega328 chip. It has 14 digital input/output pins, 6 analog inputs, a USB connection, power jack, and reset button. It can be programmed and powered through the USB connection. The Arduino Uno differs from previous boards in that it uses the Atmega8U2 instead of FTDI chip for USB-to-serial conversion. It is the reference version of the Arduino platform and is recommended for beginners.
This document provides an overview and introduction to a digital home automation project using Arduino and Bluetooth. The project aims to develop a home automation system that allows appliances to be remotely controlled via an Android smartphone application. Key components include an Arduino Uno microcontroller, HC-05 Bluetooth module, relays, and an Android app. The system allows electrical appliances like lights and fans to be switched on or off from a smartphone. The Arduino code controls the relays based on commands received over Bluetooth from the Android app.
The document provides an overview of the Arduino prototyping platform. It discusses the main components of Arduino including the Arduino board itself, external hardware like sensors and actuators, and the Arduino IDE. It describes the key capabilities of Arduino boards like the ATmel microcontroller, I/O pins, and programming interfaces. The Arduino can be used to build all kinds of projects from automatic plant watering systems to quadcopter autopilots by connecting various external hardware and programming it using the Arduino IDE.
The arduino uno is a microcontroller board based on thePramod Kumar
The document provides information about the Arduino Uno microcontroller board. It discusses the following key details:
- The Uno uses the ATmega328 microcontroller and has 14 digital input/output pins, 6 analog inputs, a USB connection, power jack, and reset button.
- It can be powered via USB or an external power source between 6-20V connected to the power jack or Vin pin.
- The board has 32KB of flash memory, 2KB of SRAM, and 1KB of EEPROM for storage. Communication is supported through serial via USB or pins 0 and 1, I2C, and SPI.
- The Uno can be programmed through the USB
Arduino is an open-source electronics platform based on easy-to-use hardware and software. Arduino boards are able to read inputs - light on a sensor, a finger on a button, or a Twitter message - and turn it into an output - activating a motor, turning on an LED, publishing something online.
This document provides an overview of Arduino, an open-source hardware platform used for building interactive objects and prototypes. It describes Arduino as a single-board microcontroller intended to make electronics projects more accessible. Key topics covered include the Arduino programming environment, common Arduino boards and their features, examples of simple Arduino projects like blinking an LED and building a line-following robot, and comparisons to other prototyping platforms. The document encourages readers to get started with Arduino for its low cost, easy programming environment, and large community support.
The document provides an introduction to Arduino boards. It describes that Arduinos contain a microcontroller and can be programmed to interact with electronic components. The specific board being discussed, the Arduino Uno R3, contains an ATmega328 chip, has ports for digital and analog input/output, and can be expanded with shields. The document also outlines how to install the Arduino IDE software and provides an example code to fade an LED on and off.
Arduino is an open-source platform that allows users to create interactive electronics projects. It consists of a microcontroller board, which is essentially a small computer, and various input and output pins that can be programmed using the Arduino Integrated Development Environment (IDE). The platform is relatively inexpensive and easy to use, making it popular among hobbyists, students, and professionals alike.
The Arduino board is the heart of the platform, and it comes in different variations that cater to different projects. At the center of the board is a microcontroller, which is essentially a small computer that controls the inputs and outputs of the board.
In addition to the microcontroller, the board also has various input and output pins that can be used to connect different sensors and actuators to the board. These pins allow the board to interact with the outside world and perform different functions depending on the project.
Visit https://robomart.com/ for more info
The Arduino Uno is a microcontroller board based on the ATmega328p chip. It has 14 digital input/output pins, 6 analog inputs, a 16MHz ceramic resonator, a USB connection, a power jack, an ICSP header, and a reset button. It is commonly used for beginner projects in electronics, programming, and robotics.
The document provides information about how the Arduino board works. It explains that the Arduino uses an Atmega microcontroller chip which is programmed to control inputs and outputs. A secondary chip, such as an Atmega8U2, handles the USB connection and communication between the microcontroller and computer. Supporting components like voltage regulators, capacitors, crystals and resistors work together to power the chips safely and generate the clock signal needed for programming and operation.
Similar to Basics of open source embedded development board ( (20)
Blood finder application project report (1).pdfKamal Acharya
Blood Finder is an emergency time app where a user can search for the blood banks as
well as the registered blood donors around Mumbai. This application also provide an
opportunity for the user of this application to become a registered donor for this user have
to enroll for the donor request from the application itself. If the admin wish to make user
a registered donor, with some of the formalities with the organization it can be done.
Specialization of this application is that the user will not have to register on sign-in for
searching the blood banks and blood donors it can be just done by installing the
application to the mobile.
The purpose of making this application is to save the user’s time for searching blood of
needed blood group during the time of the emergency.
This is an android application developed in Java and XML with the connectivity of
SQLite database. This application will provide most of basic functionality required for an
emergency time application. All the details of Blood banks and Blood donors are stored
in the database i.e. SQLite.
This application allowed the user to get all the information regarding blood banks and
blood donors such as Name, Number, Address, Blood Group, rather than searching it on
the different websites and wasting the precious time. This application is effective and
user friendly.
Tools & Techniques for Commissioning and Maintaining PV Systems W-Animations ...Transcat
Join us for this solutions-based webinar on the tools and techniques for commissioning and maintaining PV Systems. In this session, we'll review the process of building and maintaining a solar array, starting with installation and commissioning, then reviewing operations and maintenance of the system. This course will review insulation resistance testing, I-V curve testing, earth-bond continuity, ground resistance testing, performance tests, visual inspections, ground and arc fault testing procedures, and power quality analysis.
Fluke Solar Application Specialist Will White is presenting on this engaging topic:
Will has worked in the renewable energy industry since 2005, first as an installer for a small east coast solar integrator before adding sales, design, and project management to his skillset. In 2022, Will joined Fluke as a solar application specialist, where he supports their renewable energy testing equipment like IV-curve tracers, electrical meters, and thermal imaging cameras. Experienced in wind power, solar thermal, energy storage, and all scales of PV, Will has primarily focused on residential and small commercial systems. He is passionate about implementing high-quality, code-compliant installation techniques.
This study Examines the Effectiveness of Talent Procurement through the Imple...DharmaBanothu
In the world with high technology and fast
forward mindset recruiters are walking/showing interest
towards E-Recruitment. Present most of the HRs of
many companies are choosing E-Recruitment as the best
choice for recruitment. E-Recruitment is being done
through many online platforms like Linkedin, Naukri,
Instagram , Facebook etc. Now with high technology E-
Recruitment has gone through next level by using
Artificial Intelligence too.
Key Words : Talent Management, Talent Acquisition , E-
Recruitment , Artificial Intelligence Introduction
Effectiveness of Talent Acquisition through E-
Recruitment in this topic we will discuss about 4important
and interlinked topics which are
Levelised Cost of Hydrogen (LCOH) Calculator ManualMassimo Talia
The aim of this manual is to explain the
methodology behind the Levelized Cost of
Hydrogen (LCOH) calculator. Moreover, this
manual also demonstrates how the calculator
can be used for estimating the expenses associated with hydrogen production in Europe
using low-temperature electrolysis considering different sources of electricity
Determination of Equivalent Circuit parameters and performance characteristic...pvpriya2
Includes the testing of induction motor to draw the circle diagram of induction motor with step wise procedure and calculation for the same. Also explains the working and application of Induction generator
Supermarket Management System Project Report.pdfKamal Acharya
Supermarket management is a stand-alone J2EE using Eclipse Juno program.
This project contains all the necessary required information about maintaining
the supermarket billing system.
The core idea of this project to minimize the paper work and centralize the
data. Here all the communication is taken in secure manner. That is, in this
application the information will be stored in client itself. For further security the
data base is stored in the back-end oracle and so no intruders can access it.
Impartiality as per ISO /IEC 17025:2017 StandardMuhammadJazib15
This document provides basic guidelines for imparitallity requirement of ISO 17025. It defines in detial how it is met and wiudhwdih jdhsjdhwudjwkdbjwkdddddddddddkkkkkkkkkkkkkkkkkkkkkkkwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwioiiiiiiiiiiiii uwwwwwwwwwwwwwwwwhe wiqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq gbbbbbbbbbbbbb owdjjjjjjjjjjjjjjjjjjjj widhi owqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq uwdhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhwqiiiiiiiiiiiiiiiiiiiiiiiiiiiiw0pooooojjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjj whhhhhhhhhhh wheeeeeeee wihieiiiiii wihe
e qqqqqqqqqqeuwiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiqw dddddddddd cccccccccccccccv s w c r
cdf cb bicbsad ishd d qwkbdwiur e wetwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwww w
dddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddfffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffw
uuuuhhhhhhhhhhhhhhhhhhhhhhhhe qiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii iqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccc ccccccccccccccccccccccccccccccccccc bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbu uuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuum
m
m mmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmm m i
g i dijsd sjdnsjd ndjajsdnnsa adjdnawddddddddddddd uw
2. What is a Microcontroller
(µC, MCU)
Computer on a single integrated chip•
–
–
–
Processor (CPU)
Memory (RAM / ROM / Flash)
I/O ports (USB, I2C, SPI, ADC)
• Common microcontroller families:
–
–
–
–
Intel: 4004, 8008, etc.
Atmel: AT and AVR
Microchip: PIC
ARM: (multiple manufacturers)
• Used in:
–
–
–
–
–
Cellphones,
Toys
Household appliances
Cars
Cameras
3. Arduino Overview
The Arduino microcontroller is an easy to use yet powerful
single board computer that has gained considerable
traction in the hobby and professional market. The
Arduino is open-source, which means hardware is
reasonably priced and development software is free.
The Arduino project was started in Italy to develop low cost
hardware for interaction design.
The Arduino hardware comes in several flavors. In the
United States, Sparkfun (www.sparkfun.com) is a good
source for Arduino hardware.
With the Arduino board, you can write programs and
create interface circuits to read switches and other sensors,
and to control motors and lights with very little effort.
4. Continue
The Arduino programming language is a simplified version of
C/C++. If you know C, programming the Arduino will be
familiar. If you do not know C, no need to worry as only a few
commands are needed to perform useful functions. An
important feature of the Arduino is that you can create a control
program on the host PC, download it to the Arduino and it will
run automatically. Remove the USB cable connection to the PC,
and the program will still run from the top each time you push
the reset button. Remove the battery and put the Arduino board
in a closet for six months. When you reconnect the battery, the
last program you stored will run. This means that you connect
the board to the host PC to develop and debug your program,
but once that is done, you no longer need the PC to run the
program.
5. The ATmega328P Microcontroller
(used by the Arduino)
•
•
•
•
•
•
AVR 8-bit RISC architecture
Available in DIP package
Up to 20 MHz clock
32kB flash memory
1 kB SRAM
23 programmable I/O
channels
Six 10-bit ADC inputs
Three timers/counters
Six PWM outputs
•
•
•
6. What is Arduino Not?
•
•
•
•
•
It
It
It
It
It
is
is
is
is
is
not
not
not
not
not
a
a
a
a
a
chip (IC)
board (PCB)
company or a manufacturer
programming language
computer architecture
(although it involves all of these things...)
7. So what is Arduino?
It’s a movement, not a microcontroller:
• Founded by Massimo Banzi and David
Cuartielles in 2005
Based on “Wiring Platform”, which dates
2003
Open-source hardware platform
Open source development environment
• to
•
•
– Easy-to learn language and libraries (based
on Wiring language)
Integrated development environment (based
on Processing programming environment)
Available for Windows / Mac / Linux
–
–
8. What is Arduino?
Arduino is a popular “open source” single board
microcontroller. It is designed to make the process of
using electronics in multidisciplinary projects more
accessible.
This idea began in Italy and its initial
purpose was to make STUDENT design
projects more affordable than other
prototyping projects at the time.
9. Continue…
Open Source Hardware, you can make your own
board, or buy one.
Cheap, easily available.
Open Source Software.
Very widespread, many projects openly available.
Extra HW (shields) available.
10. The Many Flavors of Arduino
•
•
•
•
•
•
•
•
Arduino
Arduino
Arduino
Arduino
Arduino
Arduino
Arduino
Arduino
Uno
Leonardo
LilyPad
Mega
Nano
Mini
Mini Pro
BT
13. Where to Get an Arduino Board
• Purchase from
worldwide)
online vendor (available
–
–
–
...
Sparkfun
Adafruit
DFRobot
or build your• own
– PC board
– Solderless breadboard http://itp.nyu.edu/physcomp/Tutorials/ArduinoBreadboard
14. Different types of Arduinos
Arduino Mega 2560
Arduino LilyPad
Arduino Uno
DIY Arduino
Boarduino Kit
22. Other Hardware Choices-Sheilds
Xbee Shield
The Xbee shield allows an Arduino board to communicate wirelessly using
Zigbee. The module can communicate up to 100 feet indoors or 300 feet outdoors (with
line-of-sight). It can be used as a serial/usb replacement or you can put it into a
command mode and configure it for a variety of broadcast and mesh networking options.
The Xbee shield was created in collaboration with Libelium, who developed it
for use in their SquidBee motes (used for creating sensor networks).
Adafruit Servo/Stepper/DC Motor shield
A shield that can control 2 hobby servos and up to 2 unipolar/bipolar stepper
motors or 4 bi-directional DC motors.
Battery Shield
A shield from Liquidware that connects to the back of the Arduino, with a USB-
rechargable lithium ion battery that can power an Arduino for 14-28 hours depending on
the circuit
Liquidware TouchShield
OLED touch screen shield.
23. Continue
Adafruit Wave shield
Plays any size 22KHz audio files from an SD memory card
for music, effects and interactive sound art
Adafruit GPS & Datalogging shield
Connects up a GPS module and can log location, time/date
as well as sensor data to an SD memory flash card.
Adafruit XPort/Ethernet shield
Allows use of an XPort module for connecting to the Internet
as a client or server.
25. Continue…
Liquidware TouchShield
OLED touch screen shield.
Adafruit Servo/Stepper/DC Motor shield
A shield that can control 2 hobby servos and up to 2
unipolar/bipolar stepper motors or 4 bi-directional DC
motors.
31. Pins on Arduino
Starting clockwise from the top center:
Analog Reference pin (orange)
Digital Ground (light green)
Digital Pins 2-13 (green)
Digital Pins 0-1/Serial In/Out - TX/RX (dark green) - These pins cannot be used
for digital i/o (digitalRead and digitalWrite) if you are also using serial
communication (e.g. Serial.begin).
Reset Button - S1 (dark blue)
In-circuit Serial Programmer (blue-green)
Analog In Pins 0-5 (light blue)
Power and Ground Pins (power: orange, grounds: light orange)
External Power Supply In (9-12VDC) - X1 (pink)
Toggles External Power and USB Power (place jumper on two pins closest to
desired supply) - SV1 (purple)
USB (used for uploading sketches to the board and for serial communication
between the board and the computer; can be used to power the board) (yellow)
32. Digital Pins
In addition to the specific functions listed below, the
digital pins on an Arduino board can be used for
general purpose input and output via the pinMode(),
digitalRead(), and digitalWrite() commands. Each pin
has an internal pull-up resistor which can be turned on
and off using digitalWrite() (w/ a value of HIGH or
LOW, respectively) when the pin is configured as an
input. The maximum current per pin is 40 mA.
33. Serial: 0 (RX) and 1 (TX). Used to receive (RX) and transmit (TX) TTL
serial data. On the Arduino Diecimila, these pins are connected to the
corresponding pins of the FTDI USB-to-TTL Serial chip. On the
Arduino BT, they are connected to the corresponding pins of the WT11
Bluetooth module. On the Arduino Mini and LilyPad Arduino, they are
intended for use with an external TTL serial module (e.g. the Mini-USB
Adapter).
External Interrupts: 2 and 3. 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: 3, 5, 6, 9, 10, and 11. Provide 8-bit PWM output with the
analogWrite() function. On boards with an ATmega8, PWM output is
available only on pins 9, 10, and 11.
Reset: 7. (Arduino BT-only) Connected to the reset line of the
bluetooth module.
SPI: 10 (SS), 11 (MOSI), 12 (MISO), 13 (SCK). These pins support SPI
communication, which, although provided by the underlying
hardware. It allow serial communication with another interface by
connecting it serially.
LED: 13. On the Diecimila and LilyPad, 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.
34. Analog Pins
In addition to the specific functions listed below,
the analog input pins support 10-bit analog-to-digital
conversion (ADC) using the analogRead() function.
Most of the analog inputs can also be used as digital
pins: analog input 0 as digital pin 14 through analog
input 5 as digital pin 19. Analog inputs 6 and 7
(present on the Mini and BT) cannot be used as digital
pins.
I2C: 4 (SDA) and 5 (SCL). Support I2C (TWI)
communication using the Wire library
35. Power Pins
VIN (sometimes labelled "9V"). The input voltage to the Arduino
board when it's using an external power source (as opposed to 5
volts from the USB connection or other regulated power source).
You can supply voltage through this pin, or, if supplying voltage
via the power jack, access it through this pin. Note that different
boards accept different input voltages ranges, please see the
documentation for your board. Also note that the LilyPad has no
VIN pin and accepts only a regulated input.
5V. The regulated power supply used to power the
microcontroller and other components on the board. This can
come either from VIN via an on-board regulator, or be supplied
by USB or another regulated 5V supply.
3V3. (Diecimila-only) A 3.3 volt supply generated by the on-
board FTDI chip.
GND. Ground pins.
36. Other Pins
AREF. Reference voltage for the analog inputs. It
provide the analog reference voltage for analog to
digital conversion
Reset. (Diecimila-only) Bring this line LOW to reset
the microcontroller. Typically used to add a reset
button to shields which block the one on the board.
38. Function of Each block
USB Plug: By using this plug we can download hex file of
our program by connecting it with PC. It also provide
supply to arduino board. This USB plug is connected with
FTDI Chip internally
FTDI Chip: This chip is nothing but voltage level converter
chip. This chip is used to convert USB voltage level to TTL
level and vice versa.
Digital I/O and PWM section: This section is used as for
general purpose input output usage. By using this section
we can perform digital input and output functions. In this
section some pins are also used as PWM output pins. It is
used for PWM based application like servo motors.
39. Continue…
Serial Tx and Rx Section: These two pins are used for serial
communication in arduino. It is internally connected with USB
plug through FTDI chip.
Power Supply: Power supply section provide different voltage
level to different part of arduino board. This part contain bridge
rectifier and voltage regulator.
AVR Atmega CPU: This block is the heart of the controller.
Generally Atmega 8, Atmega 16, Atmega 32, Atmega 328
controller are used in arduino board. This block execute all the
fuctions that written in arduino program.
SPI Interface section: This section is used for serial peripheral
interfacing.
Power Pins section: This section include various voltage level
pins including ground pins.
Analog input section: We know that Atmega 8 CPU has
inbuilt 6 channel 10 – bit ADC. This ADC can convert analog
data from analog pin into digital. So, for taking analog value for
digital conversion we have to use this section.
46. Comments
• Comments can be anywhere
• Comments created with // or /* and */
• // is used for single line comment.
• /* */ is used for multiline
comments
• Comments do not affect code
• You may not need comments, but
think about the community!
47. //- Single line comment
/* */ - Multiline comment
{ } – used to define a block of code that starts and ends.
; - used to define the end of a line of code.
Programming Symbols
48. Math Operators
= (assignment) makes something equal to something else. For example,
x = 10*2, thus x = 20.
% (modulo) – this gives the remainder when one number is divided by
another. For example 12 % 10 gives 2.
+ (addition)
- (subtraction)
* (multiplication)
/ (division)
49. Comparison Operators
These are used to make logical comparisons.
== (equal to) - For example 12==10 is FALSE and 12 ==12 is
TRUE.
!= (not equal to) - For example 12!=10 is TRUE and 12!=12 is
FALSE.
< (less than)
> (greater than)
50. Control Structures
These execute code based on CONDITIONS. Here are
just a few.
if(condition) { }
else if (condition) { }
else(condition) { }
This will execute the code between the curly braces if the condition
is true, and if not test the condition of the “else if”. If that is false ,
the “else” code will execute.
for (int i =0; i < #repeats; i ++) { }
Used when you would like to repeat a line of code a specific # of times. Often
called a FOR LOOP.
51. Activity 1: LED Blink
• Load the “Blink” example
(FileExamplesBasicsBlink)
Use pin 13 as digital output
Set output high (+5V)
Wait 1000 milliseconds
Set output low (0V)
•
•
Compile, then upload the program
Congratulations! you are now blinkers!
void setup() {
// initialize the digital pin as an output.
// Pin 13 has an LED connected on most Arduino boards:
pinMode(13, OUTPUT);
}
void loop() {
digitalWrite(13, HIGH); // set the LED on
delay(1000); // wait for a second
digitalWrite(13, LOW); // set the LED off
delay(1000); // wait for a second
}
52. Now connect your own LED
Anatomy of an LED:
Notes:
•
•
Resistor is needed to limit current
Resistor and LED may be
interchanged
(but polarity of LED is important)
Pin 13 is special: has built-in
resistor and LED
Change program and upload
http://www.wikipedia.org/ •
•
53. Aside: Using a Solderless
Breadboard
Connected together
300 mils
Connected together
55. Experimenting
• Change the blink rate
– how fast can the LED blink (before you
no longer perceive the blinking?)
can
• How would you make the LED dimmer?
– (...without changing the resistor?)
56. Digital Input: Reading
and Buttons
Switches
Writing HIGH to an input pin:
enables an internal pull-up
resistor
•
•
•
Turn on/off LED based on switch
Pin 12 reads
Pin 12 reads
LOW when switch is closed
HIGH when switch is open (pull-up)
Without the internal pull-up resistor,
unconnected digital inputs
could read either high or low
void setup() {
pinMode(11, OUTPUT); // Use pin 11 for digital out
pinMode(12, INPUT); // Use pin 12 for digital input
digitalWrite(12, HIGH); // Enable pull‐up resistor
}
void loop() {
boolean state;
state = digitalRead(12); // read state of pin 12
digitalWrite(11, state); // set state of pin 11 (LED)
delay(100); // wait for a 1/10 second
}
57. Activity 2: Seven-Segment
Display
Write a that program that counts from 0
9 and displays the result on a seven-
segment LED display
• to
• Consider writing a function:
void writeDigit(int n)
that writes a single digit
58. Seven-Segment Display Table
Useful:
• bitRead(x,n)
Get the value of the
Example:
nth bit of an integer x
– bitRead(0x7E,7); // returns 1 (see table above)
Digit ABCDEFG A B C D E F G
0 0×7E on on on on on on off
1 0×30 off on on off off off off
2 0×6D on on off on on off on
3 0×79 on on on on off off on
4 0×33 off on on off off on on
5 0×5B on off on on off on on
6 0×5F on off on on on on on
7 0×70 on on on off off off off
8 0×7F on on on on on on on
9 0×7B on on on on off on on
59. •
•
Serial Communication - Writing
IMPORTANT:
USB serial
communication is
shared with
Arduino pins 0
and 1 (RX/TX)
Initialize serial
rate)
Example:
port for communication (and sets baud
Note: Serial.end()
command is usually
unnecessary, unless you need
to use pins 0 & 1
– Serial.begin(9600); // 9600 baud
Format can be:
BIN, HEX, OCT,
or an integer
specifying the
number of digits
to display
Prints data to the serial
Examples:
port
–
–
–
–
Serial.print(“Hi”);
Serial.print(78);
Serial.print(variable);
Serial.print(78,BIN);
//
//
//
//
print
works
works
a string
with
with
numbers, too
variables
1001110will print
•
Same as Serial.print(), but with line-feed
Serial.println(val)
Serial.print(val), Serial.print(val,fmt)
Serial.begin(baud)
60. Activity 3: Hello World!
Serial Monitor:
• Write an Arduino
program that prints the
message “Hello world”
to the serial port
...whenever you press
a switch/button
Use the Serial Monitor
to see the output
(Ctrl-Shift-M)
Try increasing baud
rate
•
•
•
Make sure this agrees with your
program, i.e.,
Serial.begin(9600);
62. Serial Communication - Reading
•
Returns the number of bytes
Example:
if (Serial.available() > 0)
data = Serial.read();
}
available to be read, if any
{
To read data from serial port:
•
•
•
•
letter = Serial.read()
letters = Serial.readBytesUntil(character, buffer, length)
number = Serial.parseInt()
number = Serial.parseFloat()
Serial.available()