URL
https://opencores.org/ocsvn/altor32/altor32/trunk
[/] [altor32/] [trunk/] [sw/] [gdb_stub/] [mem_map.h] - Blame information for rev 43
Details |
Compare with Previous |
View Log
Line No. |
Rev |
Author |
Line |
1 |
43 |
ultra_embe |
#ifndef __MEM_MAP_H__
|
2 |
|
|
#define __MEM_MAP_H__
|
3 |
|
|
|
4 |
|
|
//-----------------------------------------------------------------
|
5 |
|
|
// Defines:
|
6 |
|
|
//-----------------------------------------------------------------
|
7 |
|
|
#define IO_BASE 0x12000000
|
8 |
|
|
|
9 |
|
|
//-----------------------------------------------------------------
|
10 |
|
|
// Macros:
|
11 |
|
|
//-----------------------------------------------------------------
|
12 |
|
|
#define REG8 (volatile unsigned char*)
|
13 |
|
|
#define REG16 (volatile unsigned short*)
|
14 |
|
|
#define REG32 (volatile unsigned int*)
|
15 |
|
|
|
16 |
|
|
//-----------------------------------------------------------------
|
17 |
|
|
// Peripheral Base Addresses
|
18 |
|
|
//-----------------------------------------------------------------
|
19 |
|
|
#define UART_BASE (IO_BASE + 0x000)
|
20 |
|
|
#define TIMER_BASE (IO_BASE + 0x100)
|
21 |
|
|
#define INTR_BASE (IO_BASE + 0x200)
|
22 |
|
|
|
23 |
|
|
//-----------------------------------------------------------------
|
24 |
|
|
// Interrupts
|
25 |
|
|
//-----------------------------------------------------------------
|
26 |
|
|
#define IRQ_UART_RX 0
|
27 |
|
|
#define IRQ_TIMER_SYSTICK 1
|
28 |
|
|
#define IRQ_TIMER_HIRES 2
|
29 |
|
|
#define IRQ_EXT_INT0 8
|
30 |
|
|
|
31 |
|
|
//-----------------------------------------------------------------
|
32 |
|
|
// Peripheral Registers
|
33 |
|
|
//-----------------------------------------------------------------
|
34 |
|
|
|
35 |
|
|
// UART
|
36 |
|
|
#define UART_USR (*(REG32 (UART_BASE + 0x4)))
|
37 |
|
|
#define UART_UDR (*(REG32 (UART_BASE + 0x8)))
|
38 |
|
|
|
39 |
|
|
// TIMER
|
40 |
|
|
#define TIMER_VAL (*(REG32 (TIMER_BASE + 0x0)))
|
41 |
|
|
#define SYS_CLK_COUNT (*(REG32 (TIMER_BASE + 0x4)))
|
42 |
|
|
|
43 |
|
|
// IRQ
|
44 |
|
|
#define IRQ_MASK (*(REG32 (INTR_BASE + 0x00)))
|
45 |
|
|
#define IRQ_MASK_SET (*(REG32 (INTR_BASE + 0x00)))
|
46 |
|
|
#define IRQ_MASK_CLR (*(REG32 (INTR_BASE + 0x04)))
|
47 |
|
|
#define IRQ_STATUS (*(REG32 (INTR_BASE + 0x08)))
|
48 |
|
|
|
49 |
|
|
#endif
|
© copyright 1999-2025
OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.