⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 s3c2450.inc

📁 SMDK2416_BSP
💻 INC
📖 第 1 页 / 共 4 页
字号:
;
; Copyright (c) Microsoft Corporation.  All rights reserved.
;
;
; Use of this source code is subject to the terms of the Microsoft end-user
; license agreement (EULA) under which you licensed this SOFTWARE PRODUCT.
; If you did not accept the terms of the EULA, you are not authorized to use
; this source code. For a copy of the EULA, please see the LICENSE.RTF on your
; install media.
;
;-------------------------------------------------------------------------------
;
;  Header: s3c2450.inc
;
;  This header file defines only those registers required by the startup
;  code. All addresses are based off the physical addresses (PA) defined
;  in s3c2450_base_reg.h (s3c2450_base_reg.inc).
;
;-------------------------------------------------------------------------------

; Include the base register definitions

	INCLUDE s3c2450_base_regs.inc
	
	
;------------------------------------------------------------------------------
; General CPU constants

Mode_USR         EQU        (0x10)
Mode_FIQ         EQU        (0x11)
Mode_IRQ         EQU        (0x12)
Mode_SVC         EQU        (0x13)
Mode_ABT         EQU        (0x17)
Mode_UND         EQU        (0x1B)
Mode_SYS         EQU        (0x1F)
I_Bit            EQU        (0x80)
F_Bit            EQU        (0x40)
R1_iA            EQU        (1<<31)
R1_nF            EQU        (1<<30)

;------------------------------------------------------------------------------
;  Miscellaneous defines

WORD_SIZE       EQU         (4)
DW8             EQU         (0x0)
DW16            EQU         (0x1)
DW32            EQU         (0x2)
WAIT            EQU         (0x1<<2)
UBLB            EQU         (0x1<<3)

;------------------------------------------------------------------------------
; MMU constants

MMU_CTL_MASK     EQU        (0x3FFF0000)
MMU_TTB_MASK     EQU        (0x00003FFF)
MMU_ID_MASK      EQU        (0xFFFFFFF0)

;------------------------------------------------------------------------------
;  Interrupt Control group 1 Registers
	[ BSP_TYPE = BSP_SMDK2443 	
INTMSK          EQU         (S3C2450_BASE_REG_PA_INTR        + 0x08)
INTSUBMSK       EQU         (S3C2450_BASE_REG_PA_INTR        + 0x1C)
INTMOD          EQU         (S3C2450_BASE_REG_PA_INTR        + 0x04)
INTPND		EQU	    (S3C2450_BASE_REG_PA_INTR	     + 0x10)	
SRCPND		EQU	    (S3C2450_BASE_REG_PA_INTR	     + 0x00)	

vSRCPND		EQU	0xB0C00000	;Interrupt request status
vINTMOD		EQU	0xB0C00004	;Interrupt mode control
vINTMSK		EQU	0xB0C00008	;Interrupt mask control
vPRIORITY	EQU	0xB0C0000C	;IRQ priority control
vINTPND		EQU	0xB0C00010	;Interrupt request status
vINTOFFSET	EQU	0xB0C00014	;Interruot request source offset
vSUBSRCPND	EQU	0xB0C00018	;Sub source pending
vINTSUBMSK	EQU	0xB0C0001C	;Interrupt sub mask

vINTBASE	EQU	0xB0C00000	;Interrupt request status
oSRCPND		EQU	0x00			;Interrupt request status
oINTMSK		EQU	0x08			;Interrupt mask control
oINTPND		EQU	0x10			;Interrupt request status
oINTSUBMSK	EQU	0x1C			;Interrupt sub mask

	]
	[ BSP_TYPE = BSP_SMDK2450 
INTMSK1          EQU         (S3C2450_BASE_REG_PA_INTR        + 0x08)
INTSUBMSK       EQU         (S3C2450_BASE_REG_PA_INTR        + 0x1C)
INTMOD1          EQU         (S3C2450_BASE_REG_PA_INTR        + 0x04)
INTPND1		EQU	    (S3C2450_BASE_REG_PA_INTR	     + 0x10)	
SRCPND1		EQU	    (S3C2450_BASE_REG_PA_INTR	     + 0x00)	


vSRCPND1		EQU	0xB0C00000	;Interrupt request status
vINTMOD1		EQU	0xB0C00004	;Interrupt mode control
vINTMSK1		EQU	0xB0C00008	;Interrupt mask control
vPRIORITY_MODE1		EQU	0xB0C00030	;IRQ priority Mode 1
vPRIORITY_UPDATE1	EQU	0xB0C00034	;IRQ priority Update
vINTPND1		EQU	0xB0C00010	;Interrupt request status
vINTOFFSET1		EQU	0xB0C00014	;Interruot request source offset
vSUBSRCPND		EQU	0xB0C00018	;Sub source pending
vINTSUBMSK		EQU	0xB0C0001C	;Interrupt sub mask


vINTBASE1	 	EQU	0xB0C00000	;Interrupt request status
oSRCPND1		EQU	0x00			;Interrupt request status
oINTMSK1		EQU	0x08			;Interrupt mask control
oINTPND1		EQU	0x10			;Interrupt request status
oINTSUBMSK		EQU	0x1C			;Interrupt sub mask


;  Interrupt Control group 2 Registers


INTMSK2          EQU         (S3C2450_BASE_REG_PA_INTR        + 0x48)
INTMOD2          EQU         (S3C2450_BASE_REG_PA_INTR        + 0x44)
INTPND2		EQU	    (S3C2450_BASE_REG_PA_INTR	     + 0x50)	
SRCPND2		EQU	    (S3C2450_BASE_REG_PA_INTR	     + 0x40)


vSRCPND2		EQU	0xB0C00040	;Interrupt request status
vINTMOD2		EQU	0xB0C00044	;Interrupt mode control
vINTMSK2		EQU	0xB0C00048	;Interrupt mask control
vPRIORITY_MODE2		EQU	0xB0C00070	;IRQ priority Mode 1
vPRIORITY_UPDATE2	EQU	0xB0C00074	;IRQ priority Update
vINTPND2		EQU	0xB0C00050	;Interrupt request status
vINTOFFSET2		EQU	0xB0C00054	;Interruot request source offset


vINTBASE2 		EQU	0xB0C00040	;Interrupt request status
oSRCPND2		EQU	0x00			;Interrupt request status
oINTMSK2		EQU	0x08			;Interrupt mask control
oINTPND2		EQU	0x10			;Interrupt request status
	]
;------------------------------------------------------------------------------
;  IOPort Control Registers

GPACDL		EQU		(S3C2450_BASE_REG_PA_IOPORT  + 0x00)
GPACDH		EQU		(S3C2450_BASE_REG_PA_IOPORT  + 0x04)

GPBCON		EQU		(S3C2450_BASE_REG_PA_IOPORT  + 0x10)
GPBDAT		EQU		(S3C2450_BASE_REG_PA_IOPORT  + 0x14)
GPBUDP		EQU		(S3C2450_BASE_REG_PA_IOPORT  + 0x18)
	[ BSP_TYPE = BSP_SMDK2443 	
	]

	[ BSP_TYPE = BSP_SMDK2450 
GPBSEL		EQU		(S3C2450_BASE_REG_PA_IOPORT  + 0x1C)	
	]


GPFCON		EQU		(S3C2450_BASE_REG_PA_IOPORT  + 0x50)
GPFDAT		EQU		(S3C2450_BASE_REG_PA_IOPORT  + 0x54)
GPFUDP		EQU		(S3C2450_BASE_REG_PA_IOPORT  + 0x58)

	[ BSP_TYPE = BSP_SMDK2443 	
GPGCON		EQU		(S3C2450_BASE_REG_PA_IOPORT	 + 0x60)
GPGDAT		EQU		(S3C2450_BASE_REG_PA_IOPORT  + 0x64)
GPGUDP		EQU		(S3C2450_BASE_REG_PA_IOPORT  + 0x68)
	]
	[ BSP_TYPE = BSP_SMDK2450 
	]

GPHCON		EQU		(S3C2450_BASE_REG_PA_IOPORT  + 0x70)
GPHDAT		EQU		(S3C2450_BASE_REG_PA_IOPORT  + 0x74)
GPHUDP		EQU		(S3C2450_BASE_REG_PA_IOPORT  + 0x78)

GPKCON		EQU		(S3C2450_BASE_REG_PA_IOPORT  + 0xE0)
GPKDAT		EQU		(S3C2450_BASE_REG_PA_IOPORT  + 0xE4)
GPKUDP		EQU		(S3C2450_BASE_REG_PA_IOPORT  + 0xE8)

MISCCR		EQU		(S3C2450_BASE_REG_PA_IOPORT  + 0x80)

	[ BSP_TYPE = BSP_SMDK2443 
GSTATUS3	EQU		(S3C2450_BASE_REG_PA_IOPORT  + 0xB8)
	]
	[ BSP_TYPE = BSP_SMDK2450 
	]


vGPFCON		EQU	0xB2100050	;Port F data
vGPFDAT		EQU	0xB2100054	;Port F data
vGPFUDP		EQU	0xB2100058	;Port F data

vEINTMASK	EQu	0xB21000A4
vEINTPEND	EQU	0xB21000A8

vGPIOBASE	EQU	0xB2100000	;Port A control
oGSTATUS3       EQU     0xB8

oGPFCON		EQU	0x50			;Port F control
oGPFDAT		EQU	0x54			;Port F data
oGPFUDP		EQU	0x58			;Pull-Down control F

vMISCCR		EQU	0xB2100080	;Miscellaneous control
;------------------------------------------------------------------------------

;  Watch Dog Control Registers

WTCON           EQU         (S3C2450_BASE_REG_PA_WATCHDOG    + 0x00)
WTDAT		   EQU		 (S3C2450_BASE_REG_PA_WATCHDOG	+ 0x04)
WTCNT		   EQU		 (S3C2450_BASE_REG_PA_WATCHDOG	+ 0x08)

vWTCON		EQU	0xB1E00000	  ;Watch-dog timer mode
vWTDAT		EQU	0xB1E00004	  ;Watch-dog timer data
vWTCNT		EQU	0xB1E00008	  ;Eatch-dog timer count
;------------------------------------------------------------------------------
;  Memory configuration Control Registers

BANKCFG    EQU           0x48000000	;;//Mobile DRAM configuration
BANKCON1    EQU           0x48000004	;;//Mobile DRAM control 
BANKCON2    EQU           0x48000008	;;//Mobile DRAM timing control 
BANKCON3    EQU           0x4800000C	;;//Mobile DRAM (E)MRS 
REFRESH    EQU           0x48000010	;;//Mobile DRAM refresh control
TIMEOUT    EQU           0x48000014	;;//Write Buffer Time out control 
vREFRESH	EQU	0xB0800010	;DRAM/SDRAM refresh

;//chapter1	EBI controller
EBICON   EQU           0x4E800008	;//Bank Configuration 




;//chapter4 SSMC
SMBIDCYR0   EQU           0x4F000000	;//Bank0 idle cycle control 
SMBIDCYR1   EQU           0x4F000020	;//Bank1 idle cycle control 
SMBIDCYR2   EQU           0x4F000040	;//Bank2 idle cycle control 
SMBIDCYR3   EQU           0x4F000060	;//Bank3 idle cycle control 
SMBIDCYR4   EQU           0x4F000080	;//Bank0 idle cycle control 
SMBIDCYR5   EQU           0x4F0000A0	;//Bank5 idle cycle control 
SMBWSTRDR0  EQU           0x4F000004	;//Bank0 read wait state control 
SMBWSTRDR1  EQU           0x4F000024	;//Bank1 read wait state control
SMBWSTRDR2  EQU           0x4F000044	;//Bank2 read wait state control
SMBWSTRDR3  EQU           0x4F000064	;//Bank3 read wait state control 
SMBWSTRDR4  EQU           0x4F000084	;//Bank4 read wait state control 
SMBWSTRDR5  EQU           0x4F0000A4	;//Bank5 read wait state control 
SMBWSTWRR0  EQU           0x4F000008	;//Bank0 write wait state control 
SMBWSTWRR1  EQU           0x4F000028	;//Bank1 write wait state control 
SMBWSTWRR2  EQU           0x4F000048	;//Bank2 write wait state control 
SMBWSTWRR3  EQU           0x4F000068	;//Bank3 write wait state control 
SMBWSTWRR4  EQU           0x4F000088	;//Bank4 write wait state control 
SMBWSTWRR5  EQU           0x4F0000A8	;//Bank5 write wait state control 
SMBWSTOENR0 EQU           0x4F00000C	;//Bank0 output enable assertion delay control 
SMBWSTOENR1 EQU           0x4F00002C	;//Bank1 output enable assertion delay control 
SMBWSTOENR2 EQU           0x4F00004C	;//Bank2 output enable assertion delay control
SMBWSTOENR3 EQU           0x4F00006C	;//Bank3 output enable assertion delay control 
SMBWSTOENR4 EQU           0x4F00008C	;//Bank4 output enable assertion delay control
SMBWSTOENR5 EQU           0x4F0000AC	;//Bank5 output enable assertion delay control 
SMBWSTWENR0 EQU           0x4F000010	;//Bank0 write enable assertion delay control 
SMBWSTWENR1 EQU           0x4F000030	;//Bank1 write enable assertion delay control 
SMBWSTWENR2 EQU           0x4F000050	;//Bank2 write enable assertion delay control 
SMBWSTWENR3 EQU           0x4F000070	;//Bank3 write enable assertion delay control 
SMBWSTWENR4 EQU           0x4F000090	;//Bank4 write enable assertion delay control 
SMBWSTWENR5 EQU           0x4F0000B0	;//Bank5 write enable assertion delay control 
SMBCR0      EQU           0x4F000014	;//Bank0 control 
SMBCR1      EQU           0x4F000034	;//Bank1 control 
SMBCR2      EQU           0x4F000054	;//Bank2 control 
SMBCR3      EQU           0x4F000074	;//Bank3 control 
SMBCR4      EQU           0x4F000094	;//Bank4 control 
SMBCR5      EQU           0x4F0000B4	;//Bank5 control 
SMBSR0      EQU           0x4F000018	;//Bank0 status 
SMBSR1      EQU           0x4F000038	;//Bank1 status 
SMBSR2      EQU           0x4F000058	;//Bank2 status 
SMBSR3      EQU           0x4F000078	;//Bank3 status 
SMBSR4      EQU           0x4F000098	;//Bank4 status 
SMBSR5      EQU           0x4F0000B8	;//Bank5 status 
SMBWSTBRDR0 EQU           0x4F00001C	;//Bank0 burst read wait delay control 
SMBWSTBRDR1 EQU           0x4F00003C	;//Bank1 burst read wait delay control 
SMBWSTBRDR2 EQU           0x4F00005C	;//Bank2 burst read wait delay control 
SMBWSTBRDR3 EQU           0x4F00007C	;//Bank3 burst read wait delay control 
SMBWSTBRDR4 EQU           0x4F00009C	;//Bank4 burst read wait delay control 
SMBWSTBRDR5 EQU           0x4F0000BC	;//Bank5 burst read wait delay control 
SSMCSR      EQU           0x4F000200	;//SROMC status 
SSMCCR      EQU           0x4F000204	;//SROMC control 

;------------------------------------------------------------------------------
;  Clock and Power Control Registers

LOCKCON0        EQU         (S3C2450_BASE_REG_PA_CLOCK_POWER + 0x00)
LOCKCON1        EQU         (S3C2450_BASE_REG_PA_CLOCK_POWER + 0x04)
MPLLCON         EQU         (S3C2450_BASE_REG_PA_CLOCK_POWER + 0x10)
EPLLCON         EQU         (S3C2450_BASE_REG_PA_CLOCK_POWER + 0x18)
HCLKCON         EQU         (S3C2450_BASE_REG_PA_CLOCK_POWER + 0x30)
PCLKCON         EQU         (S3C2450_BASE_REG_PA_CLOCK_POWER + 0x34)
SCLKCON         EQU         (S3C2450_BASE_REG_PA_CLOCK_POWER + 0x38)
CLKDIV0         EQU         (S3C2450_BASE_REG_PA_CLOCK_POWER + 0x24)
CLKDIV1         EQU         (S3C2450_BASE_REG_PA_CLOCK_POWER + 0x28)
CLKSRC          EQU         (S3C2450_BASE_REG_PA_CLOCK_POWER + 0x20)
PWRMODE			EQU			(S3C2450_BASE_REG_PA_CLOCK_POWER + 0x40)

RSTSTAT     EQU           0x4C000068  		;//Reset status
WKUPSTAT    EQU           0x4C00006c  		;//Wakeup status
INFORM0     EQU           0x4C000070  		;//Sleep mode information 0
INFORM1     EQU           0x4C000074  		;//Sleep mode information 1
INFORM2     EQU           0x4C000078  		;//Sleep mode information 2
INFORM3     EQU           0x4C00007C  		;//Sleep mode information 3
RSTCON      EQU     	  0x4C000064        ;//Reset Control

vRSTSTAT     EQU           0xb1000068  		;//Reset status
vWKUPSTAT    EQU           0xb100006c  		;//Wakeup status
vINFORM0     EQU           0xb1000070  		;//Sleep mode information 0
vINFORM1     EQU           0xb1000074  		;//Sleep mode information 1
vINFORM2     EQU           0xb1000078  		;//Sleep mode information 2
vINFORM3     EQU           0xb100007C  		;//Sleep mode information 3

vHCLKCON	EQU	0xb1000030	;HCLK enable control
vPCLKCON	EQU	0xb1000034	;PCLK enable control
vSCLKCON	EQU	0xb1000038	;Special colck enable control

vCLKDIV0	EQU	0xb1000024      ;Clock divider control
vCLKDIV1	EQU	0xb1000028      ;Clock divider control


vRSTCON        	EQU     0xb1000064      ;Reset Control
vOSCSET        	EQU     0xb1000008      ;Osc Control
vPWRCFG        	EQU     0xb1000060      ;Power config Control
vPWRMODE        EQU     0xb1000040      ;Power Mode Control


;------------------------------------------------------------------------------
;  RTC Control Registers
	[ BSP_TYPE = BSP_SMDK2443 	

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -