Section1_16bit Arc.ppt

Similar documents
ICD ICD ICD ICD ICD

2 PIC PIC 1 / CPU PIC MCU PIC RC

USB解决方案.ppt

1-1 SH79F6431 A. 2( ) 9~15V ( 12V) U2 U3 3.3V SH79F B. 1(VCC/GND) SH79F6431 C. VDDIO SH79F6431 P4 P5 P0.6 P0.7 VDDIO VDDIO=5V D. 2 V 1.0

(Load Project) (Save Project) (OffLine Mode) (Help) Intel Hex Motor

目 录

ARM Cortex-M3 (STM32F) STMicroelectronics ( ST) STM32F103 Core: ARM 32-bit Cortex -M3 CPU 72 MHz, 90 DMIPS with 1.25 DMIPS/MHz Single-cycle multiplica

2 Keil µ vision 2.1 1) Keil µ vision2 V2.34 µ vision3 2) Sino_Keil.exe Keil c:\keil\ 3) JET51 USB PC C:\Keil\ USB PC 4) S-L

投影片 1

untitled

1 CPU

DPJJX1.DOC

Tel:

ATMEL AT90S8515 AVR CPU AVR AVR AVR ATMEL RISC 32 8 r0 r X Y Z R0 R1 R2 R13 R14 R15 R16 R17 R26 R27 R28 R29 R30 R31 0x00 0x

1.1 ML_ONOFF = 1 Q 3 Q 8 C 0.3V M 2 L 1 ML_ONOFF = 0 Q 3 Q 8 C 1. + R31 VCC R21 10K ML_ONOFF R15 0:off 1:on 1K Green Light VCC=5V L1 Q VDD=12V C

,,, PCB, AR M VxWorks DSP,,,,,,,,,,, (CIP) /,,.:,2005 ISBN TP36 CIP (2005) : ( 10 ) : : (010 ) : (010)

JTAG ICE PC JTAG ICE JTAG ISP... 5 IDE AVR STUDIO JTAGICE JTAGICE... 12

SPHE8202R Design Guide Important Notice SUNPLUS TECHNOLOGY CO. reserves the right to change this documentation without prior notice. Information provi

FM1935X智能非接触读写器芯片

2 14 PORTC.1 PORTB.3 PORTA.2/T0 GND PORTB.2 PORTA.0 PORTC.3 PORB.0/OSCO PORTB.1/OSCI PORTC.0 PORTC.2 SH69P21 /SOP PORTA

逢 甲 大 學

MCU DSP MSO MCU DSP MSO MSO MSO MCU/DSP I/O MSO 16 Microchip IC18 turn-on MSO chirp MCU I/O I 2 C

专业主干课程与主要专业课程教学大纲(2009年、2011年).doc

PCM-3386用户手册.doc

Microsoft PowerPoint - CA_03 Chapter5 Part-II_multi _V1.ppt

图 片 展 示 : 资 源 简 介 : FPGA Altera CycloneII EP2C5T144C8 (4608 个 LE) 2 路 有 源 晶 振 (50M,25M) AS & JTAG 标 准 接 口 VGA 接 口 UART 接 口 蜂 鸣 器 8bit 并 行 DAC 8 路 按 键

Ps22Pdf

51 C 51 isp 10 C PCB C C C C KEIL

KT-SOPCx开发套件简明教程

《计算机应用基础》学习材料(讲义)

ARM JTAG实时仿真器安装使用指南

untitled

目录

IP TCP/IP PC OS µclinux MPEG4 Blackfin DSP MPEG4 IP UDP Winsock I/O DirectShow Filter DirectShow MPEG4 µclinux TCP/IP IP COM, DirectShow I

PIC16F F MPLAB 08 16F LED 15 LED

RESET OSCO OSCI OSC CPU WDTEN RC RESET PRESCALER PORTA (4-BITS) WATCHDOG TIMER Power on PORTB (4-BITS) PORTA [0:3] PORTB [0:3] LPD PORTC (4-BITS) LPDO

单片机应用编程技巧(专家:邓宏杰)

User ID 150 Password - User ID 150 Password Mon- Cam-- Invalid Terminal Mode No User Terminal Mode No User Mon- Cam-- 2

PROTEUS VSM

2005.book

T stg -40 to 125 C V cc 3.8V V dc RH 0 to 100 %RH T a -40 to +125 C -0.3 to 3.6V V -0.3 to VDD+0.3 V -10 to +10 ma = 25 = 3V) VDD

SST SPAC SST SoftICE SST89C5x/SST89x554RC /564RD /SST89x516/5xRD / SoftICE SoftICE MCU SoftICE SS

<4D F736F F D20C7B6C8EBCABDCFB5CDB3C9E8BCC6CAA6BFBCCAD4B4F3B8D92E646F63>

文件名

Bus Hound 5

P4V88+_BIOS_CN.p65

2/80 2

audiogram3 Owners Manual

untitled

P4VM800_BIOS_CN.p65

Hz 10MHz 0.5V 5V 0.01% 10s 2 0.5V 5V 1Hz 1kHz 10% 90% 1% 3 1Hz 1MHz 1% EPM7128SLC84-15 LM361 LM361 Zlg

S 可编程控制器

A Preliminary Implementation of Linux Kernel Virus and Process Hiding

Microsoft PowerPoint - CA_02 Chapter5 Part-I_Single _V2.ppt

1 Project New Project 1 2 Windows 1 3 N C test Windows uv2 KEIL uvision2 1 2 New Project Ateml AT89C AT89C51 3 KEIL Demo C C File

Microsoft PowerPoint - STU_EC_Ch08.ppt

System Design and Setup of a Robot to Pass over Steps Abstract In the research, one special type of robots that can pass over steps is designed and se

AL-M200 Series

C35_RG_E.book

Abstract arm linux tool-chain root NET-Start! 2

dsPIC Architecture Overview

untitled

典型自编教材

STM32 for sensorless vector control

Microsoft PowerPoint - C15_LECTURE_NOTE_09

untitled

行业

untitled

一个开放源码的嵌入式仿真环境 ― SkyEye

MENU SYD8821: Ultra Low Power Bluetooth 4.2 Single Mode SoC General Description Key Features Applications Key Para

1 1

上海东软载波微电子有限公司 SMART

行业

1 MTK 2 MTK 3 MTK

1 TPIS TPIS 2 2


新建 Microsoft Word 文档.doc

mdt1030

Support All Industrial Ethernet Standards on Your Next "Drive" Design White Paper

52C

untitled

6 C51 ANSI C Turbo C C51 Turbo C C51 C51 C51 C51 C51 C51 C51 C51 C C C51 C51 ANSI C MCS-51 C51 ANSI C C C51 bit Byte bit sbit

EK-STM32F

70178C.book

逢甲大學

SMART 7P 0 HR7P OTPMCU A/D I/O OTP ROM RAM HR7P HR7P HR7PPMB MSOP0 7+input HR7PPSC HR7PPSD SOP SOP6 +input input HR7PERB SSOP0 7



<4D F736F F D FB971BEF7BB50B971A46CB8735FB773A55FA5ABA5DFB7E7AADAB0AAAFC5A475B77EC2BEB77EBEC7AED55FA97EAE61C0F4B9D2B4BCBC7AB1B1A8EEA874B2CE2E646F63>

DATASHEET SEARCH SITE ==

untitled

邏輯分析儀的概念與原理-展示版

大学计算机基础B.doc

33023A.book(31001A_cn.fm)

untitled

, STC11F01-35C-SOP16 RMB 1.99 STC10F04-35C-LQFP44 R MB 2. 99

画像処理に新しい価値を提供するUSB3.0カメラ(国際画像機器展2014)

Transcription:

16-bit Elite Program 2009 Summer Section-1 Microchip 16-bit 2005 Microchip Technology Incorporated. All Rights Reserved. Slide 1

MCU CPU (NOP),, (Data Memory), I/O CPU w. ALU/Working Reg. Data Mem. Data Bus Data Mem. Addr. Bus Data Memory Memory mapped I/O Program Data. Bus Instruction Fetch & Decode Program Addr. Bus Program Memory Microchip 16-bit MCU I/O Memory mapped Data Memory Program Counter Program Memory, CPU. 2006 Microchip Technology Incorporated. All Rights Reserved. 1005 GS5 Slide 2

Memory Mapped IO MCU / High/Low ( LED, ) ( SPII2CUART ) ( ADDA ) ( PWM ) MCU I/O, Memory I/O Memory Mapped IO Memory Mapped IO Special Function Register 2006 Microchip Technology Incorporated. All Rights Reserved. 1005 GS5 Slide 3

Microchip 16-bit Microchip 16-bit Family dspic30f PIC24FJ PIC24HJ 16-bit DSP DSP /16 -bit MCU DSP 40 MIPs 16 -bit MCU DMA dspic33fj DSP, 40 MIPs DMA 2006 Microchip Technology Incorporated. All Rights Reserved. 1005 GS5 Slide 4

Program & Data Memory Bus 16-bit microcontroller CPU Data Memory Bus 24-bit Instruction width OP Code & 24-bits, Data Transfer Mechanism between PM and DM (PSV) Program Memory Data Memory CPU Program Memory ( ) 16 bit window Program Memory (Up to 12MB) 24 16-bit RISC CPU 16 Data Memory (Up to 64KB) 2006 Microchip Technology Incorporated. All Rights Reserved. 1005 GS5 Slide 5

Microchip 16-bit MCU Data Memory (RAM) 32K x 16 bit DSP: dual access MCU: single access Instruction Pre-fetch & Decode DSP Engine Y AGU W Array 16 x 16 X AGU TABLE Access Cntrl Program Memory DSC ONLY MCU ALU Address Path MCU/DSP Data Path 23-bit PC Control DSP Data Path Program Data/Control Path 4M x 24 bit Linear 2006 Microchip Technology Incorporated. All Rights Reserved. 1005 GS5 Slide 6

16-bit Architecture Programmers model MCU (ALU) Intel 8051 AB R0.. R7 PIC16F WREG & FSR PIC18F WERG, FSR0.. FSR2 Microchip 16-bit MCU WREG0.. WREG15 16 : Microchip 16-bit-MCU -Multiplier Barrel Shifter 2006 Microchip Technology Incorporated. All Rights Reserved. 1005 GS5 Slide 7

16-bit Architecture Programmers model SFR TBLPAG PSVPAG DOSTART DOEND DCOUNT AccB AccA SPLIM RCOUNT STATUS REG CORCON ALU W 0 W 1 Near Memory Far Memory PCH W 13 W 14 W 15 PCL dspic only 16-bit devices 2006 Microchip Technology Incorporated. All Rights Reserved. 1005 GS5 Slide 8

#1 (c = a + b;) w0 w1 w2 w3 w5 w15 CPU Registers a (copy) b (copy) c (copy). Data Memory (Variables) a b c temp i. ALU ALU can operate directly on variables stored in CPU Registers add w0, w1, w2 2006 Microchip Technology Incorporated. All Rights Reserved. 1005 GS5 Slide 9

# 2 (c = a + b;) w0 w1 w2 w3 w5 w15 CPU Registers a (copy) addr(b) addr(c). Data Memory (Variables) a b c temp i. ALU can operate directly or indirectly on variables stored in Data Memory Direct ALU add w0, [w1], [w2] Indirect 2006 Microchip Technology Incorporated. All Rights Reserved. 1005 GS5 Slide 10

Program Memory Organization Reset Vector GOTO Main 0x000000 Interrupt Vector Table Executable code starts at 0x100 or 0x200 Interrupts Reserved Alternate Interrupt Vector Table Main: User Program Flash Memory Midway point of Program Memory Unimplemented or Reserved for Configuration Memory Data EEPROM Upper Half of PM 24-bit 0x7FFFFE 0x800000 0xFFFFFE 2006 Microchip Technology Incorporated. All Rights Reserved. 1005 GS5 Slide 11

Data Memory Organization* MS Byte Address 16-bits MSB LSB LS Byte Address 2 KB SFR Space 8 KB SRAM Space 0x0001 0x07FF 0x0801 0x17FF 0x1801 SFR Space X Data Ram 0x0000 0x07FE 0x0800 0x17FE 0x1800 Near Data Memory 8 KB Y Data Ram 0x1FFE 0x27FF 0x27FE 0x8001 0x8000 Optionally Mapped into Program Memory Unimplemented PIC24 DSP, X & Y Memory X & Y 0xFFFF 0xFFFE 2006 Microchip Technology Incorporated. All Rights Reserved. 1005 GS5 Slide 12

IO PIC24FXXXGA1 2006 Microchip Technology Incorporated. All Rights Reserved. 1005 GS5 Slide 13

MCU Power On Disable, ADC, Power On AD Input Power On ( Comparator ) Initial Oscillator Debug 16-bit MCU 2 Debug Pins Debug Mode module 2006 Microchip Technology Incorporated. All Rights Reserved. 1005 GS5 Slide 14

PIC30F Family Block Diagram 12 144 KB Flash 0.5 8 KB RAM Memory Bus 16/32-bit Timers WDT / Pwr Mgmt. 1 Msps A/D, 10-bit 30 MIPS 16-bit Core 16-bit ALU 17 x 17 MPY Working Register Array 2 Add. Gen. Units Interrupt Control Peripheral Bus 500 Ksps A/D,12-bit GP I/O UART - 2 I 2 C - 2 Multi-bit Shifter SPI - 2 CAN 1-2 DSP Engine 2006 Microchip Technology Incorporated. All Rights Reserved. 1005 GS5 Slide 15

PIC24F Family Block Diagram 64 128 KB Flash 8 KB RAM 16/32-bit Timers WDT / Pwr Mgmt. Memory Bus 500Ksps A/D,10-bit 16 MIPS 16-bit Core 16-bit ALU Working Register Array 17 x 17 MPY 1 Add. Gen. Units Interrupt Control Peripheral Bus GP I/O UART - 2 I 2 C - 2 SPI - 2 JTAG Interface Multi-bit Shifter RTCC PMP CRC 2006 Microchip Technology Incorporated. All Rights Reserved. 1005 GS5 Slide 16

PIC24H Family Block Diagram 64 256 KB Flash 8 16 KB RAM 8-chnl. DMA 16-/32-bit Timers WDT / Pwr Mgmt. Memory Bus 1 Msps A/D, 10-bit 40 MIPS 16-bit Core 16-bit ALU 17 x 17 MPY Working Register Array 1 Add. Gen. Units Interrupt Control Peripheral Bus 500 Ksps A/D,12-bit GP I/O UART - 2 I 2 C - 2 JTAG Interface Multi-bit Shifter SPI - 2 ECAN 1-2 2006 Microchip Technology Incorporated. All Rights Reserved. 1005 GS5 Slide 17

PIC33F Family Block Diagram 64 256 KB Flash 8 16 KB RAM 8-chnl. DMA 16-/32-bit Timers WDT / Pwr Mgmt. Memory Bus 1 Msps A/D, 10-bit 40 MIPS 16-bit Core 16-bit ALU 17 x 17 MPY Working Register Array 2 Add. Gen. Units Interrupt Control Peripheral Bus 500 Ksps A/D,12-bit GP I/O UART - 2 I 2 C - 2 JTAG Interface Multi-bit Shifter SPI - 2 ECAN 1-2 DSP Engine 2006 Microchip Technology Incorporated. All Rights Reserved. 1005 GS5 Slide 18

CPU Reset, PC ( Program Counter) 0 CPU 0x0000,, Programmer Program memory CPU (CPU Instruction set ) Microchip 16-bit MCU 24 bits 2 words Instruction Word ( Single Instruction Word ) Instruction Words Call, goto PC ( PC + 2 ) CPU Call, goto BRA 2006 Microchip Technology Incorporated. All Rights Reserved. 1005 GS5 Slide 19

Instruction cycle() = 2 Input Clocks CPU () PIC24F A 32Mhz clk = 16MIPS or Tcy = 62.5 ns PIC24H/dsPIC33 A 80Mhz clk = 40 MIPS or Tcy = 25 ns dspic30f Instruction cycle = 4 Input Clocks A 120Mhz clk = 30MIPS or Tcy = 33 ns FOSC Q1 Q2 Q3 Q4 FCY 1 Instruction cycle (TCY) 2006 Microchip Technology Incorporated. All Rights Reserved. 1005 GS5 Slide 20

Microchip 16-bit Harvard (e.g. goto, rcall T CY0 T CY1 T CY2 T CY3 T CY4 2006 Microchip Technology Incorporated. All Rights Reserved. 1005 GS5 Slide 21

Microchip 16-bit MCU Vdd & AVdd RESET to MCLR Microchip 16-bit MCU Clock Input VDDCORE 10 uf Low ESR Debugger / Program Interface 2006 Microchip Technology Incorporated. All Rights Reserved. 1005 GS5 Slide 22

Maximum 12MB 4M Instruction x 24-bit 23-bit PC ( PCH & PCL ) PC increments in words ( LSb always 0 ) Reset Vector at 0 Program Memory Interrupt Vector Table from 4h to FEh ( 8+118 ) Alternate Vector Table from 104h to 1FEh User 200h dspic30f ( 8+54 ), Table FEh. User 100h PC<22:1> 0 Reset Vector Interrupt Vector Table Alternate Vector Table On Chip User Flash Memory Flash Config Words Config Registers Device ID 0 PSVPAG Source reg 0 2006 Microchip Technology Incorporated. All Rights Reserved. 1005 GS5 Slide 23 Config Space User Space 23 0 TABPAG Source reg 0

16-bit MCU PC 23 bits 2^23 8 M Words Instruction Word 2 words, 4M Instruction words CPU 0x0004,, 0x0004 0x01FE User 0x200..0x0000 goto xxxx, xxxx 0x200 goto? Address Error Trap!! Trap 2006 Microchip Technology Incorporated. All Rights Reserved. 1005 GS5 Slide 24

CPU Program Counter, X=Y+Z X, PayMoney = Cost * (1+Profit), Cost & Profit! Microchip 16-bit MCU Flash Self -Programming, ( Table Read & Table Write ) Program Memory Write Erase. Erase block (192 Bytes for PIC24FJ128GA006). Table Read/Write ( 2 cycles ). Table Read/Write. Data Memory - Program Memory Solution.. Read/Write ( 1 Cycle ).. 2006 Microchip Technology Incorporated. All Rights Reserved. 1005 GS5 Slide 25

PSV - Program Space Visibility From Data Space 15 SFR Space 0 0x0000 23 15 0 0x000000 0x001000 Data Memory 0x008000 0x009000 0x8000 0x9000 0x010000 0x011000 Data Memory 0xFFFE Program Memory 0x018000 2006 Microchip Technology Incorporated. All Rights Reserved. 1005 GS5 Slide 26

PSV PSV? 1. (Mapping) - 2. (32K Words) - PSVPAG PSV Data Memory( PSV ) PSV : Using PSV for digital filters (FIR) Filter coefficients stored in PS -> PSV Data Memory Saves valuable in SRAM ( Data Memory ) Minimal performance impact (2 cycles/filter iteration) LCD Data Encryption algorithms 32KW Program mapping 32KB Data? Instruction word 24-bit, 2 Words Instruction word bit 0.. Bit 15 mapping.. 32KW 16KW mapping, 32 KB 2006 Microchip Technology Incorporated. All Rights Reserved. 1005 GS5 Slide 27

Microchip 16-bit 76 instructions (PIC24) 84 instructions (dspic30/33) Most are one cycle except: Program Flow Changes Double Word Operations (32-bit) Program Memory Accesses Divide Operations (DIV instruction 18x) Most are one word (24 bit) except: CALL, GOTO instructions Byte (8-bit) and Double Word (32-bit) Operations 2006 Microchip Technology Incorporated. All Rights Reserved. 1005 GS5 Slide 28

PIC24F Clock sources Primary Oscillator OSCI OSCO XT,HS Crystal OSC 4x PLL Post Scaler CPU Clock Fast RC 8.0 MHz Post Scaler Peripherals Clock Low Pwr RC 32KHz SOSCI SOSCO 32KHz Secondary Crystal OSC 2006 Microchip Technology Incorporated. All Rights Reserved. 1005 GS5 Slide 29

USB Family Device 2006 Microchip Technology Incorporated. All Rights Reserved. 1005 GS5 Slide 30

On-Board Regulator 16-bit MCU, dspic30f Vdd 3.6V (3.3V) I/O CPU core 2.5V PIC24F VDDCORE 2.0V to 2.75V 3.3V PIC24F, PIC24H, dspic33f 2.5V output Regulator ENVREG Vdd Regulator disable CPU core Vddcore/ PIC24F Vdd = 2.2 V to 3.6V!! Vcap 2.5V regulator Low ESR cap VDDCORE 10µf recommended ENVREG pin (PIC24F) enable /disable 2.5V regulator 3.3V Vdd Regulator CPU 2006 Microchip Technology Incorporated. All Rights Reserved. 1005 GS5 Slide 31

Working Registers General Purpose Data Registers or Address Pointers DSP Accumulators (40-bit) OA OB SA Programmer s Model ACCA ACCB SRH SB Working Register Array 39 22 OAB SAB DSP Status DA DC W0 W1 W2 W3 W4 W5 W6 W7 W8 W9 W10 W11 W12 W13 W14 W15 15 0 32 31 15 IPL2 IPL1 IPL0 Frame Pointer Stack Pointer MCU Status DSP OPERAND Registers DSP ADDRESS Registers Program Counter 2006 Microchip Technology Incorporated. All Rights Reserved. 1005 GS5 Slide 32 SRL RA N OV SZ 16 15 0 C PUSH.S Shadow Status Register 0

Programmers Model ACCA 39 ACCAU 31 ACCAH 15 ACCAL 0 Two DSP ACCB ACCBU ACCBH ACCBL Accumulators 15 CORCON 0 Core/DSP Control Register dspic Only 7 PSVPAG 0 Prg. Space Visibility Page Address 7 TBLPAG 0 Data Table Page Address 2006 Microchip Technology Incorporated. All Rights Reserved. 1005 GS5 Slide 33

Programmers Model dspic Only 15 RCOUNT 0 Repeat Loop Counter 15 DCOUNT 0 Do Loop Counter 22 DOSTART 0 Do Loop Start Address 22 DOEND 0 Do Loop End Address 2006 Microchip Technology Incorporated. All Rights Reserved. 1005 GS5 Slide 34

Microchip 16-bit MCU Software Stack SPLIM 0x27FE Over Flow Error Stack Two Pointer levels used (W15 ) Top to of save the PC Stack Pushed Data 0x00 PCH PCL SRL PCH PCL Stack Grows Towards Higher Address Interrupt push call Under Flow Error 0x800 2006 Microchip Technology Incorporated. All Rights Reserved. 1005 GS5 Slide 35