1. PIC ADC  PIC18F877 has 8 analog input channels i.e. port A pins(RA0 to RA5) and port E pins(RE1 and RE2). These pins are used as Analog input pins.

Slides:



Advertisements
Similar presentations
MICROPROCESSORS AND MICROCONTROLLERS
Advertisements

INPUT-OUTPUT ORGANIZATION
Jordan Barry Victor Brzeski
The 8051 Microcontroller Chapter 5 SERIAL PORT OPERATION.
SPI Serial Peripheral Interface. SPI Serial Peripheral Interface is communication between two devices, one bit at a time sequential one bit at time over.
Introduction of Holtek HT-46 series MCU
Initial Position Orientation Tracking System (IPOTS) Group Members: Keiichi McGuireHenry Pham Marc TakamoriScott Spiro.
7-1 Digital Serial Input/Output Two basic approaches  Synchronous shared common clock signal all devices synchronised with the shared clock signal data.
ASPPRATECH.
Microcontroller Architecture PIC18F Family
Engineering 1040: Mechanisms & Electric Circuits Fall 2011 Introduction to Embedded Systems.
Timers and Interrupts Shivendu Bhushan Sonu Agarwal.
INPUT-OUTPUT ORGANIZATION
Objectives How Microcontroller works
Input/Output mechanisms
EE 446 Project Assignment Top Design Sensor Components Pin Assignment and Configuration Completed Physical Setup Project Tasks.
S4525A Peripherals & Enhanced FLASH 1 © 1999 Microchip Technology Incorporated. All Rights Reserved. S4525A Peripherals & Enhanced FLASH 1 Peripherals.
16F877A. Timer 0 The Timer0 module timer/counter has the following features: –8-bit timer/counter –Readable and writable –8-bit software programmable.
A Few Words From Dilbert
Lecture Set 9 MCS-51 Serial Port.
Lecture 20: Communications Lecturers: Professor John Devlin Mr Robert Ross.
RS232 #use rs232(baud=9600,xmit=PIN_C6,rcv=PIN_C7
Chapter 8 Serial and Parallel Port Interfacing Valvano’s Intro. To Embedded Systems.
CS 478: Microcontroller Systems University of Wisconsin-Eau Claire Dan Ernst Hybrid I/O – Pulses.
Other Chapters From the text by Valvano: Introduction to Embedded Systems: Interfacing to the Freescale 9S12.
MICROPROCESSOR AND MICRO CONTROLLER LAB
 8251A is a USART (Universal Synchronous Asynchronous Receiver Transmitter) for serial data communication.  Programmable peripheral designed for synchronous.
MICROPROCESSOR AND MICRO CONTROLLER
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.
© 2008, Renesas Technology America, Inc., All Rights Reserved 1 Course Introduction Purpose This course provides an overview of the standard peripheral.
Embedded Systems Design: A Unified Hardware/Software Introduction 1 Chapter 4 Standard Single Purpose Processors: Peripherals.
Teachers Name : Suman Sarker Telecommunication Technology Subject Name : Microcontroller & Embedded System Subject Code : 6871 Semester : 7th Department.
SOLAR CELL PARAMETERS MEASUREMENT
Interrupts Microprocessor and Interfacing
July 18, UCSD - R.A. de Callafon Short Intro to Micro Processors and I/O functions of our Kinetic Sculpture Control Box Raymond de Callafon.
Chapter 5 - Interrupts.
C PERIPHERAL INTERFACES
Water Flow GROUP A. Analogue input voltage results: Motor Input voltage( V) pin 12 Analogue input voltage (V) Display number
Features of the PIC18 microcontroller - 8-bit CPU - 2 MB program memory space (internal 32KB to 128KB) bytes to 1KB of data EEPROM - Up to 4096 bytes.
© 2008, Renesas Technology America, Inc., All Rights Reserved 1 Course Introduction Purpose  This course provides an introduction to the peripheral functions.
بسم الله الرحمن الرحيم MEMORY AND I/O.
 The Programmable Interrupt Controller (PlC) functions as an overall manager in an Interrupt-Driven system. It accepts requests from the peripheral equipment,
Steve Andre Eric Glover Shaun Greene Russell Willmot.
ECET 340 Entire Course (All ilabs and Homework) For more classes visit ECET 340 Week 1 HomeWork 1 ECET 340 Week 1 iLab 1 ECET 340.
Components of a typical full-featured microcontroller.
Chapter 3. Advanced Hardware Fundamentals The various parts you will commonly find in an embedded-system circuit 발표일시 : 발표자 : 채화영.
MICROCONTROLLER INTERFACING WITH STEPPER MOTOR MADE BY: Pruthvirajsinh Jadeja ( ) COLLEGE:DIET BRANCH:EC.
Microcontroller basics Embedded systems for mortals.
Microcontroller basics Embedded systems for mortals.
CEng3361/18 CENG 336 INT. TO EMBEDDED SYSTEMS DEVELOPMENT Spring 2007 Recitation 01.
Criteria for choosing a microcontroller A microcontroller must meet the task at hand efficiency and cost effectively. Speed. What is highest speed of.
FOR MORE CLASSES VISIT   ECET 340 Week 1 HomeWork 1  ECET 340 Week 1 iLab 1  ECET 340 Week 2 HomeWork 2  ECET 340 Week 2 iLab.
USING TV REMOTE AS A CORDLESS MOUSE FOR THE COMPUTER
CORDLESS MOUSE FEATURES BY TV REMOTE USING PIC MICROCONTROLLER
Timers and Event Counters
SERIAL PORT PROGRAMMING
Hardware Source: ttp:// under
BVM Engineering College Electrical Engineering Department : Microprocessor and Microcontroller Interfacing Interrupts of 8051 Prepared by:
E3165 DIGITAL ELECTRONIC SYSTEM
ECET 340 Competitive Success/snaptutorial.com
ECET 340 Education for Service-- snaptutorial.com.
ECET 340 Education for Service/tutorialrank.com
ECET 340 Teaching Effectively-- snaptutorial.com.
Introduction to Microprocessors and Microcontrollers
Presentation of Robotics (3)
Hardware Source: ttp:// under
8051 Micro Controller.
Compiled by Dr. N.Shanmugasundaram, HOD, ECE Dept, SECE.
Presentation transcript:

1. PIC ADC  PIC18F877 has 8 analog input channels i.e. port A pins(RA0 to RA5) and port E pins(RE1 and RE2). These pins are used as Analog input pins AIN0 to AIN7. A signal 10 bit ADC.  To select ADC channel set_adc_channel(n) for input ADC channel.  read_adc()- this function is used to read date from ADC. S.no functionsDescription 1set_adc(ADC_CLK_INTERNAL)Initialize ADC 2set_up_ports(Rpx_ANALOG)Initialize pin ‘x’ of port ‘p’ to function as analog input

2. PIC Interrupt  There is special method to define the function as an ISR. The directive to indicate an ISR is #int_  E.g- #int_ext

3. PIC Timer and Counters  The timer function of timer/counter keeps track of the timer or also helps in generating delays.  Counter mode of operation of a timer/counter helps in counting the number of times an event occurs.

Function NameDescription 1setup_timerx( )Used to select mode of the timer ‘x’. 2get_timerx()Used to read the content of timer register. Which will be stored in left side variable of this function. 3set_timerx(n)It loads the value ‘n’ in the timer ‘x’ register. 4setup_ccpx(ccp_pwm)It sets the timer ‘x’ in CCP mode of PWM 5setup_ccpx(ccp_pwm)It sets the timer ‘x’ in CCP mode of capture mode with rising edge 6setup_ccpx(ccp_pwm)It sets the timer ‘x’ in CCP mode of capture mode 7set_pwmx_duty(n)Used to initialize the on time value given by ‘n’ for the PWM mode of operation of the CCP.

4. PIC UART Programming  PIC supports the RS232 port for serial communication.  RXD and TXD pins used for this communication. FunctionDescription 1setup_uart(n)It sets bound rate of the UART port to the value given 2putc(n)It sends the data ‘n’ passed to the function on the serial link connected on the TXD 3getc()It reads data received on the serial port i.e. RXD

5. SPI Serial Bus  Serial Peripheral Interface (SPI) normally is preffered for the program transfer and other huge data communication from microcontroller and it is high speed communication Functiondescription 1setup_spi(spi_master) Or setup_spi(spi_slave) Used to initialize the SPI port in master or slave mode 2spi_read()Used to accept data received by SPI port. 3spi_write(n)Used to transfer character byte ‘n’.

6. PIC I2C Serial Bus  It is single wire communication for both the direction. functiondescription 1i2c_write(n)It transfers the byte data ‘n’ passed to the function on the serial port of I2C 2i2c_read()It reads byte data from serial port of I2C. 3i2c_stop()It issues a stop command when in the master mode.

7.Parallel Slave Port (PSP) FunctionDescription 1 psp_input_full() It returns Boolean type of data i.e. true or false. Return value depend on whether i/p is received from PSP or not. 2 psp_output_full() It checks if the output for the PSP port is ready to go or not. 3 output_x(n) To output the data 4 input_x() Used to accept data from port 5 setup_psp(PSP_ENABLE D) Used enable or disable PSP port 6 set_tris_e(n) Used to set data direction of the PSP port. 7 psp_overflow() Check the error on data overflow

 It mainly involves driving motors(like stepper motors, DC motor, servo motors etc.), interfacing displays (like LCD, LED), interfacing sensors.  Interfacing DC  Interfacing Stepper Motor  Temperature  Sensor LM35

Interfacing DC Motor

 Temperature Sensor LM35  It is used to convert temperature value to an electrical value.  LM35 are precision integrated circuit temperature sensors, whose output voltage is proportional to the Celsius temperature.

Temperature Sensor LM35