html5-img
1 / 19

Arquitetura 8051

Arquitetura 8051. Disciplina: Microcontroladores Prof. Remy Eskinazi Depto Engenharia Elétrica UPE - Poli. Agenda. Características do Microcontrolador 8051 Arquitetura 8051 Memória interna Área de RAM Clock e Reset Temporização. Características do 8051.

Download Presentation

Arquitetura 8051

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Arquitetura 8051 Disciplina: Microcontroladores Prof. Remy Eskinazi Depto Engenharia Elétrica UPE - Poli

  2. Agenda • Características do Microcontrolador 8051 • Arquitetura 8051 • Memória interna • Área de RAM • Clock e Reset • Temporização

  3. Características do 8051 • 8051 Introduzido no mercado pela Intel no início da década de 80 (1981) • Atualmente produzido por várias companhias em muitos varientes • É o microcontrolador mais frequente (produção e utilização) – (40% do mercado) • Microcontrolador de 8 bits

  4. Microcontroladores e Fabricantes • Motorola • 8-bit • 68HC05 • 68HC08 • 68HC11 • 16-bit • 68HC12 • 68HC16 • 32-bit • 683xx • Texas Instruments • TMS370 • MSP430 • Zilog • Z8 • Z86E02 • Atmel • ARM • Intel • 8-bit • 8XC42 • MCS48 • MCS51 • 8xC251 • 16-bit • MCS96 • MXS296 • National Semiconductor • COP8 • Microchip • 12-bit instruction PIC • 14-bit instruction PIC • PIC16F84 • 16-bit instruction PIC • NEC

  5. Part Number Fabricante ROM RAM Pinos I/O Timers Interrupções Vcc Package 8051 Intel 4K 128 32 2 6 5v 40 8031 Intel - 128 32 2 6 5v 40 8751 Intel 4K 128 32 2 6 5v 40 8052 Intel 8K 256 32 3 8 5v 40 AT89C51 Atmel 4K 128 32 2 6 5v 40 AT89C1051 Atmel 1K 64 15 1 3 3v 20 AT89C2051 Atmel 2K 128 15 2 6 3v 20 DS5000-8 Dallas 8K 128 32 2 6 3v 40 DS5000T-8 Dallas 32K 128 32 2 6 3v 40 8051 “Flavors”

  6. Arquitetura 8051 Standard • CPU CISC de 8 bits (8 bit Data bus, 16 bit Address bus) • ULA 8 bits • Registradores 8 bits • 4Kbytes de ROM de programa • ROM => 8051 • EPROM => 8751 • ROMLESS => 8031 • FLASH => AT89C51 (Atmel) • 256 bytes de SRAM • 128 bytes de SFRs • 128 bytes de usuário+pilha • 64 kbytes de ROM externa • 64 kbytes de RAM externa

  7. Arquitetura 8051 Standard • Periféricos embarcados • 2 Timers de 16 bits com 4 modos funcionais • 4 ports paralelos • 1 Canal de comunicação serial • 5 fontes de interrupção independentes • 2 externas • 2 timers • 1 canal serial • Set de instruções fortemente voltado para controle • 112 instruções básicas • Instruções aritméticas; • Instruções lógicas • Instruções movimentação • Instruções saltos e desvios • Instruções controle interno

  8. EA/VPP ALE/PROG PSEN (INT0)P3.2 (INT1)P3.3 (WR)P3.6 (RD)P3.7 Pinagem 8051 Vcc P1.0 1 40 P0.0(AD0) P1.1 2 39 P0.1(AD1) P1.2 3 38 P0.2(AD2) P1.3 4 37 8051 8031 8751 AT89C51 P0.3(AD3) P1.4 5 36 P0.4(AD4) P1.5 6 35 P0.5(AD5) P1.6 7 34 P0.6(AD6) P1.7 8 33 P0.7(AD7) RST 9 32 (RXD)P3.0 10 31 (TXD)P3.1 11 30 12 29 P2.7(A15) 13 28 (T0)P3.4 P2.6(A14) 14 27 (T1)P3.5 P2.5(A13) 15 26 P2.4(A12) 16 25 P2.3(A11) 17 24 P2.2(A10) XTAL2 18 23 P2.1(A9) XTAL1 19 22 P2.0(A8) GND 20 21

  9. PSEN ALE/PRG RXD TXD INT0 INT1 T0 T1 WR RD Pinagem 8051 P0.0 AD0 Vcc P0.1 AD1 P0.2 AD2 GND P0.3 AD3 PORT 0 P0.4 AD4 P0.5 AD5 XTAL1 P0.6 AD6 XTAL2 P0.7 AD7 P2.0 A8 RST P2.0 A9 P2.0 A10 P2.0 A11 PORT 2 EA/VPP P2.0 A12 P2.0 A13 P2.0 A14 P2.0 A15 P3.0 P1.0 P3.1 P1.0 P3.2 P1.0 P3.3 P1.0 PORT 1 P3.4 P1.0 PORT 3 P3.5 P1.0 P3.6 P1.0 P3.7 P1.0

  10. Demux Barramentos 8051

  11. RD WR PSEN PSEN Sistema de Memória 8051 Memória de programa 7 0 7 0 FFFF FFFF 60 K External 64 K External 1000 OU 0FFF 4 K Internal 0000 0000 EA = 1 EA = 0 Memória de Dados FFFF FF SFRs 64 K External 80 E 7F RAM 00 Internal 0000 Direct Direct , Register, Reg. Indirect

  12. RAM Interna 8051 User & Stack SFRs SFRs FF 7F * B F0 * IE Interrupt Enable Ctr 1 A8 Scratch Pad Area * ACC E0 * P2 Port 2 A0 RAM * PSW D0 SBUF Serial Data Buffer 99 98 * SCON Serial Control * IP B8 90 * P1 Port 1 * P3 B0 8D TH1 timer 1 High 30 8C TH0 timer 0 High Bit #00 7F OR 8B TL1 timer 1 Low Bit Addressable RAM TL0 20.0 2F.7 8A timer 0 Low TMOD 89 timer/counter Mode 20 R7 * TCON 88 timer/counter control Bank 3 87 PCON Power Control Select Bank with PSW.4 , .3 = RS1, RS0 18 R0 R7 Bank 2 * = Bit endereçável 10 R0 83 DPH Data pointer DPTR R7 Bank 1 82 DPL 08 R0 81 SP Stack pointer R7 Bank 0 80 * P0 Port 0 00 R0

  13. 8051 8052 Bancos de Registradores Quatro bancos de registradores Cada banco com registradores R0-R7 1F 18 Bank 3 17 10 Bank 2 0F 08 Bank 1 07 06 05 04 03 02 01 00 R7 R6 R5 R4 R3 R2 R1 R0 Bank 0

  14. 8051 8052 Área de Bit e Byte Endereçável 2F 2E 2D 2C 2B 2A 29 28 20h – 2Fh (16 locations X 8-bits = 128 bits) Bit addressing: mov C, 1Ah or mov C, 23h.2 27 26 25 24 23 22 21 20

  15. Reset e Clock no 8051 Vcc 31 EA/VPP X1 10 uF 30 pF X2 RST 9 8.2 K

  16. Reset e Clock no 8051

  17. Ciclo de Máquina no 8051 Ciclo de Máquina = 1/ (fext / 12) 8051 Ex.: Encontrar o ciclo de máquina para: (a) XTAL = 11.0592 MHz (b) XTAL = 16 MHz. Solução: (a) 11.0592 MHz / 12 = 921.6 kHz; Ciclo de máquina = 1 / 921.6 kHz = 1.085 s (b) 16 MHz / 12 = 1.333 MHz; Ciclo de máquina = 1 / 1.333 MHz = 0.75 s

  18. Temporização do 8051

More Related