1 IKI10230 Pengantar Organisasi Komputer Kuliah no. A6: Bahasa Rakitan AVR I/O Instructions 4 April 2003 Bobby Nazief Qonita Shahab.

Slides:



Advertisements
Similar presentations
Numbers Treasure Hunt Following each question, click on the answer. If correct, the next page will load with a graphic first – these can be used to check.
Advertisements

Repaso: Unidad 2 Lección 2
1 A B C
Scenario: EOT/EOT-R/COT Resident admitted March 10th Admitted for PT and OT following knee replacement for patient with CHF, COPD, shortness of breath.
AP STUDY SESSION 2.
1
Select from the most commonly used minutes below.
Copyright © 2003 Pearson Education, Inc. Slide 1 Computer Systems Organization & Architecture Chapters 8-12 John D. Carpinelli.
Copyright © 2013 Elsevier Inc. All rights reserved.
Copyright © 2011, Elsevier Inc. All rights reserved. Chapter 6 Author: Julia Richards and R. Scott Hawley.
Author: Julia Richards and R. Scott Hawley
1 Copyright © 2013 Elsevier Inc. All rights reserved. Chapter 3 CPUs.
Properties Use, share, or modify this drill on mathematic properties. There is too much material for a single class, so you’ll have to select for your.
Objectives: Generate and describe sequences. Vocabulary:
David Burdett May 11, 2004 Package Binding for WS CDL.
1 RA I Sub-Regional Training Seminar on CLIMAT&CLIMAT TEMP Reporting Casablanca, Morocco, 20 – 22 December 2005 Status of observing programmes in RA I.
Properties of Real Numbers CommutativeAssociativeDistributive Identity + × Inverse + ×
Custom Statutory Programs Chapter 3. Customary Statutory Programs and Titles 3-2 Objectives Add Local Statutory Programs Create Customer Application For.
CALENDAR.
1 10 pt 15 pt 20 pt 25 pt 5 pt 10 pt 15 pt 20 pt 25 pt 5 pt 10 pt 15 pt 20 pt 25 pt 5 pt 10 pt 15 pt 20 pt 25 pt 5 pt 10 pt 15 pt 20 pt 25 pt 5 pt BlendsDigraphsShort.
1 Click here to End Presentation Software: Installation and Updates Internet Download CD release NACIS Updates.
REVIEW: Arthropod ID. 1. Name the subphylum. 2. Name the subphylum. 3. Name the order.
Media-Monitoring Final Report April - May 2010 News.
Break Time Remaining 10:00.
Turing Machines.
Table 12.1: Cash Flows to a Cash and Carry Trading Strategy.
PP Test Review Sections 6-1 to 6-6
Bright Futures Guidelines Priorities and Screening Tables
Chapter 3 Logic Gates.
Bellwork Do the following problem on a ½ sheet of paper and turn in.
K ONTRAK PERKULIAHAN I Made Gatot K, ST. MT 1. PENILAIAN Kehadiran min 75 % : 5 % Tugas: 20 % Diskusi / Presentasi: 20 % UTS: 25 % UAS: 30 % TOTAL: 100%
1 The Royal Doulton Company The Royal Doulton Company is an English company producing tableware and collectables, dating to Operating originally.
Operating Systems Operating Systems - Winter 2010 Chapter 3 – Input/Output Vrije Universiteit Amsterdam.
Exarte Bezoek aan de Mediacampus Bachelor in de grafische en digitale media April 2014.
TESOL International Convention Presentation- ESL Instruction: Developing Your Skills to Become a Master Conductor by Beth Clifton Crumpler by.
Copyright © 2012, Elsevier Inc. All rights Reserved. 1 Chapter 7 Modeling Structure with Blocks.
1 RA III - Regional Training Seminar on CLIMAT&CLIMAT TEMP Reporting Buenos Aires, Argentina, 25 – 27 October 2006 Status of observing programmes in RA.
Basel-ICU-Journal Challenge18/20/ Basel-ICU-Journal Challenge8/20/2014.
1..
Sequence Quickies 1  ORB Education. Visit for the other resources in this pack.
CONTROL VISION Set-up. Step 1 Step 2 Step 3 Step 5 Step 4.
Adding Up In Chunks.
1 IKI20210 Pengantar Organisasi Komputer Kuliah No. 19: I/O, Interupsi pada AVR 22 November 2002 Bobby Nazief Johny Moningka
MaK_Full ahead loaded 1 Alarm Page Directory (F11)
Right Triangle Test Review 1. x = 262. x = 253. x = 2  6 4. x = 115. x = 3    ” x 24.7” 9. yes10. no11. yes12. yes obtuseacuteobtuse.
1 10 pt 15 pt 20 pt 25 pt 5 pt 10 pt 15 pt 20 pt 25 pt 5 pt 10 pt 15 pt 20 pt 25 pt 5 pt 10 pt 15 pt 20 pt 25 pt 5 pt 10 pt 15 pt 20 pt 25 pt 5 pt Synthetic.
Artificial Intelligence
1 IKI10230 Pengantar Organisasi Komputer Kuliah no. A7: Bahasa Rakitan AVR Interrupt Handler 25 April 2003 Bobby Nazief Qonita Shahab.
Subtraction: Adding UP
: 3 00.
5 minutes.
1 hi at no doifpi me be go we of at be do go hi if me no of pi we Inorder Traversal Inorder traversal. n Visit the left subtree. n Visit the node. n Visit.
Analyzing Genes and Genomes
Speak Up for Safety Dr. Susan Strauss Harassment & Bullying Consultant November 9, 2012.
1 Titre de la diapositive SDMO Industries – Training Département MICS KERYS 09- MICS KERYS – WEBSITE.
Essential Cell Biology
Converting a Fraction to %
Clock will move after 1 minute
famous photographer Ara Guler famous photographer ARA GULER.
PSSA Preparation.
Essential Cell Biology
Immunobiology: The Immune System in Health & Disease Sixth Edition
Physics for Scientists & Engineers, 3rd Edition
Energy Generation in Mitochondria and Chlorplasts
Select a time to count down from the clock above
Murach’s OS/390 and z/OS JCLChapter 16, Slide 1 © 2002, Mike Murach & Associates, Inc.
Copyright Tim Morris/St Stephen's School
1.step PMIT start + initial project data input Concept Concept.
Presentation transcript:

1 IKI10230 Pengantar Organisasi Komputer Kuliah no. A6: Bahasa Rakitan AVR I/O Instructions 4 April 2003 Bobby Nazief Qonita Shahab bahan kuliah: Sumber: 1. AVR AT90S8515 Data Sheet. 2. Materi kuliah CS152, th. 1997, UCB.

2 Instruksi: I/O

3 Organisasi I/O dari μC AVR Built-in I/O, Interupsi Internal Interupsi Eksternal

4 Peta Memori Data Akses menggunakan instruksi: IN & OUT Akses menggunakan instruksi: LD & ST

5 Alamat-alamat I/O (1) Address Hex NameFunction $3F ($5F) SREG Status Register $3E ($5E) SPH Stack Pointer High $3D ($5D) SPL Stack Pointer Low $3B ($5B) GIMSK General Interrupt MaSK Register $3A ($5A) GIFR General Interrupt Flag Register $39 ($59) TIMSK Timer/Counter Interrupt MaSK Register $38 ($58) TIFR Timer/Counter Interrupt Flag Register $35 ($55) MCUCR MCU general Control Register $33 ($53) TCCR0 Timer/Counter 0 Control Register $32 ($52) TCNT0 Timer/Counter 0 (8-bit) $2F ($4F) TCCR1A Timer/Counter 1 Control Register A $2E ($4E) TCCR1B Timer/Counter 1 Control Register B $2D ($4D) TCNT1H Timer/Counter 1 High Byte $2C ($4C) TCNT1L Timer/Counter 1 Low Byte $2B ($4B) OCR1AH Output Compare Register A High Byte $2A ($4A) OCR1AL Output Compare Register A Low Byte $29 ($49) OCR1AH Output Compare Register B High Byte $28 ($48) OCR1AL Output Compare Register B Low Byte $25 ($45) ICR1H T/C 1 Input Capture Register High Byte $24 ($44) ICR1L T/C 1 Input Capture Register Low Byte $21 ($41) WDTCR Watchdog Timer Control Register

6 Alamat-alamat I/O (2) Address Hex Name Function $1B ($38) PORTA Data Register, Port A $1A ($3A) DDRA Data Direction Register, Port A $19 ($39) PINA Input Pins, Port A $18 ($38) PORTB Data Register, Port B $17 ($37) DDRB Data Direction Register, Port B $16 ($36) PINB Input Pins, Port B $15 ($35) PORTC Data Register, Port C $14 ($34) DDRCData Direction Register, Port C $13 ($33) PINC Input Pins, Port C $12 ($32) PORTD Data Register, Port D $11 ($31) DDRD Data Direction Register, Port D $10 ($30) PIND Input Pins, Port D $0F ($2F) SPDR SPI I/O Data Register $0E ($2E) SPSR SPI I/O Status Register $0D ($2D) SPCR SPI I/O Control Register $0C ($2C) UDR UART I/O Data Register $0B ($2B) USRUART Status Register $0A ($2A) UCRUART Control Register $09 ($29) UBRR UART Baud Rate Register $08 ($28) ACSR Analog Comparator Control and Status Register

7 Instruksi-instruksi I/O °P: I/O Register °Data Transfer: INRd,P; Rd  P OUTP,Rs; P  Rs °Bit Operation: SBIP,b; P(b)  1 CBIP,b; P(b)  0 °Branch: SBICP,b; Skip if P(b) == 0 SBISP,b; Skip if P(b) == 1 RETI °Special: SEI; Global Interrupt Enable CLI; Global Interrupt Disable WDR; Watchdog Reset

8 Simulasi Program I/O di AVR Studio

9 Penggunaan Port I/O 8 bit (A,B,C,D) °Penamaan: PORTA,PORTB,PORTC,PORTD DDRA,DDRB,DDRC,DDRD (data direction) PINA,PINB,PINC,PIND °Mengeset sebuah port untuk menjadi sebuah Input Port: outDDRD,0x00 °Mengeset sebuah port untuk menjadi sebuah Output Port: outDDRB,0xff °Memasukkan data (input) dari sebuah port: inR16,PIND °Mengeluarkan data (output) ke sebuah port: outPORTB,R16

10 Contoh masuk/keluar data °outPORTB,0b °inR18,PIND isi R18 = 0b

11 Contoh Program: io-bd.asm lditemp,$ff outPORTB,temp; Set all pins at port B high outDDRB,temp; Set port B as output lditemp,$00 outPIND,temp; Set all pins at port D low outDDRD,temp; Set port D as input ldicount,5 rjmpshow_inputs show_inputs: nop; only in simulator intemp,PIND; get input outPORTB,temp; output the data deccount cpicount,0 brne show_inputs quit:rjmp quit

12 STK200: board untuk percobaan I/O °Port B: LED °Port D: tombol-tombol

13 Penggunaan STK200 °Prosesor AVR ditancapkan di STK200 board °Kabel ke parallel port di PC

14 Referensi °AVR Assembler User Guide ° ° \appnotes\*.asm °AVR AT90S8515 Data Sheets