OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [bootloaders/] [orpmon/] [include/] [board.h] - Blame information for rev 179

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 2 marcus.erl
#ifndef _BOARD_H_
2
#define _BOARD_H_
3
 
4 140 julius
#define CFG_IN_FLASH            0
5
//#define MC_ENABLED            1
6 2 marcus.erl
 
7
//LAN controller 
8
//#define SMC91111_LAN          1
9
#define OC_LAN                  1
10
 
11
/* BOARD
12
 * 0 - bender
13
 * 1 - marvin
14 140 julius
 * 2 - ORSoC A3PE1500 usbethdev board
15
 * 3 - ORSoC A3P1000 usbethdev board
16 2 marcus.erl
 */
17 140 julius
#define BOARD                   3
18 2 marcus.erl
 
19 140 julius
/* Ethernet IP and TFTP config
20
 * 0 - JB ORSoC board
21
 * 1 - AE ORSoC board
22
 * 2 - JB Southpole board
23
 */
24
#define IPCONFIG                 0
25
 
26 2 marcus.erl
#if BOARD==0
27
// Nibbler on bender1
28
 
29
#  define IC_ENABLE             1
30
#  define IC_SIZE               4096
31
#  define DC_ENABLE             1
32
#  define DC_SIZE               2048
33
#  define FLASH_BASE_ADDR         0xf0000000
34
#  define FLASH_SIZE              0x02000000
35
#  define FLASH_BLOCK_SIZE        0x00020000
36
#  define START_ADD               0x0
37
#  define CONFIG_OR32_MC_VERSION  2
38
#  define IN_CLK                  25000000
39
#  define BOARD_DEF_NAME          "bender"
40
// Flash Organization on board
41
// FLASH_ORG_XX_Y
42
// where XX - flash bit size
43
//       Y  - number of parallel devices connected
44
#  define FLASH_ORG_16_1          1
45
#elif BOARD==1
46
//Marvin
47
 
48 140 julius
#  define IC_ENABLE             1
49 2 marcus.erl
#  define IC_SIZE               8192
50
#  define DC_ENABLE             0
51
#  define DC_SIZE               8192
52
#  define FLASH_BASE_ADDR         0xf0000000
53
#  define FLASH_SIZE              0x04000000
54
#  define FLASH_BLOCK_SIZE        0x00040000
55
#  define START_ADD               0x0
56
#  define CONFIG_OR32_MC_VERSION  1
57
/*#  define IN_CLK                100000000*/
58
#  define IN_CLK                  50000000
59
#  define FLASH_ORG_16_2          1
60
#  define BOARD_DEF_NAME          "marvin"
61 140 julius
#elif BOARD==2
62
//ORSoC usbethdev board
63
 
64
#  define IC_ENABLE             1
65
#  define IC_SIZE               8192
66
#  define DC_ENABLE             0
67
#  define DC_SIZE               8192
68
#  define FLASH_BASE_ADDR         0xf0000000
69
#  define FLASH_SIZE              0x04000000
70
#  define FLASH_BLOCK_SIZE        0x00040000
71
#  define START_ADD               0x0
72
#  define SDRAM_SIZE             0x02000000
73
#  define SDRAM_ROW_SIZE         0x00000400
74
#  define SDRAM_BANK_SIZE        0x00800000
75
//#  define IN_CLK                32000000
76
//#  define IN_CLK                24000000
77
#  define IN_CLK                  20000000
78
//#  define IN_CLK                16000000
79
//#  define IN_CLK                17000000
80
 
81
#  define FLASH_ORG_16_2          1
82
#  define BOARD_DEF_NAME          "ORSoC devboard"
83
#elif BOARD==3
84
//ORSoC A3P1000 usbethdev board
85
 
86
#  define IC_ENABLE             1
87
#  define IC_SIZE               4096
88
#  define DC_ENABLE             0
89
#  define DC_SIZE               8192
90
#  define FLASH_BASE_ADDR         0xf0000000
91
#  define FLASH_SIZE              0x04000000
92
#  define FLASH_BLOCK_SIZE        0x00040000
93
#  define START_ADD               0x0
94
#  define SDRAM_SIZE             0x02000000
95
#  define SDRAM_ROW_SIZE             0x00000400
96
#  define SDRAM_BANK_SIZE             0x00800000
97
#  define IN_CLK                  20000000
98
#  define FLASH_ORG_16_2          1
99
#  define BOARD_DEF_NAME          "ORSoC A3P1000 devboard"
100
 
101 2 marcus.erl
#else
102
//Custom Board
103
#  define IC_ENABLE             0
104
#  define IC_SIZE               8192
105
#  define DC_ENABLE             0
106
#  define DC_SIZE               8192
107
#  define FLASH_BASE_ADDR         0xf0000000
108
#  define FLASH_SIZE              0x04000000
109
#  define FLASH_BLOCK_SIZE        0x00040000
110
#  define START_ADD               0x0
111
#  define CONFIG_OR32_MC_VERSION  1
112
#  define IN_CLK                  25000000
113
#  define FLASH_ORG_16_2          1
114
#  define BOARD_DEF_NAME          "custom"
115
 
116
#endif
117
 
118 140 julius
 
119
// IP tboot configs
120
#if IPCONFIG==0
121
 
122
#define BOARD_DEF_IP            0xc0a8649b // 192.168.100.155
123
#define BOARD_DEF_MASK          0xffffff00 // 255.255.255.0
124
#define BOARD_DEF_GW            0xc0a86401 // 192.168.100.1
125
#define BOARD_DEF_TBOOT_SRVR    0xc0a86469 //"192.168.100.105"
126
#define BOARD_DEF_IMAGE_NAME    "boot.img"
127
#define BOARD_DEF_LOAD_SPACE    0xa00000
128
#define ETH_MDIOPHYADDR         0x00
129
#define ETH_MACADDR0            0x00
130
#define ETH_MACADDR1            0x12
131
#define ETH_MACADDR2            0x34
132
#define ETH_MACADDR3            0x56
133
#define ETH_MACADDR4            0x78
134
#define ETH_MACADDR5            0x9a
135
 
136
#elif IPCONFIG==1
137
 
138
#define BOARD_DEF_IP            0xc0a8649c // 192.168.100.156
139
#define BOARD_DEF_MASK          0xffffff00 // 255.255.255.0
140
#define BOARD_DEF_GW            0xc0a86401 // 192.168.100.1
141
#define BOARD_DEF_TBOOT_SRVR    0xc0a864e3 //"192.168.100.227"
142
#define BOARD_DEF_IMAGE_NAME    "boot.img"
143
#define BOARD_DEF_LOAD_SPACE    0xa00000
144
#define ETH_MDIOPHYADDR         0x00
145
#define ETH_MACADDR0            0xad
146
#define ETH_MACADDR1            0xda
147
#define ETH_MACADDR2            0x34
148
#define ETH_MACADDR3            0x56
149
#define ETH_MACADDR4            0x78
150
#define ETH_MACADDR5            0x9a
151
 
152
#elif IPCONFIG==2
153
 
154
#define BOARD_DEF_IP            0xac1e0002 // 172.30.0.2
155
#define BOARD_DEF_MASK          0xffffff00 // 255.255.255.0
156
#define BOARD_DEF_GW            0xac1e0001 //"172.30.0.1"
157
#define BOARD_DEF_TBOOT_SRVR    0xac1e0001 //"172.30.0.1"
158
#define BOARD_DEF_IMAGE_NAME    "boot.img"
159
#define BOARD_DEF_LOAD_SPACE    0xa00000
160
#define ETH_MDIOPHYADDR         0x00
161
#define ETH_MACADDR0            0x00
162
#define ETH_MACADDR1            0x12
163
#define ETH_MACADDR2            0x34
164
#define ETH_MACADDR3            0x56
165
#define ETH_MACADDR4            0x78
166
#define ETH_MACADDR5            0x9a
167
 
168
#else // Some custom one
169
 
170
#define BOARD_DEF_IP            0x0a01010a // 10.1.1.10
171
#define BOARD_DEF_MASK          0xffffff00 // 255.255.255.0
172
#define BOARD_DEF_GW            0x0a010101 // 10.1.1.10
173
#define BOARD_DEF_TBOOT_SRVR    0x0a010101 // 10.1.1.10
174
#define BOARD_DEF_IMAGE_NAME    "boot.img"
175
#define BOARD_DEF_LOAD_SPACE    0xa00000
176
#define ETH_MDIOPHYADDR         0x00
177
#define ETH_MACADDR0            0xad
178
#define ETH_MACADDR1            0xaa
179
#define ETH_MACADDR2            0x34
180
#define ETH_MACADDR3            0x56
181
#define ETH_MACADDR4            0x78
182
#define ETH_MACADDR5            0x9a
183
 
184
#endif
185
 
186
 
187
 
188 2 marcus.erl
#define UART_BAUD_RATE          115200
189
 
190
#define TICKS_PER_SEC           100
191
 
192 140 julius
 
193
#define MS_PER_SEC 1000
194
#define US_PER_SEC 1000000
195
#define US_PER_TICK (US_PER_SEC/TICKS_PER_SEC)
196
#define TICKS_PER_US (TICKS_PER_SEC*1000000)
197
 
198 2 marcus.erl
#define STACK_SIZE              0x10000
199
 
200
#if     CONFIG_OR32_MC_VERSION==1
201
// Marvin, Bender MC
202
#  include "mc-init-1.h"
203
#elif   CONFIG_OR32_MC_VERSION==2
204
// Highland MC
205
#  include "mc-init-2.h"
206 140 julius
//#else
207
//#  error "no memory controler chosen"
208 2 marcus.erl
#endif
209
 
210
#define UART_BASE               0x90000000
211
#define UART_IRQ                2
212
#define ETH_BASE                0x92000000
213
#define ETH_IRQ                 4
214 140 julius
 
215
#define SPI_BASE                0xb0000000
216 2 marcus.erl
#define CRT_BASE_ADDR           0x97000000
217
#define ATA_BASE_ADDR           0x9e000000
218
#define KBD_BASE_ADD            0x94000000
219
#define KBD_IRQ                 5
220
 
221
#define SANCHO_BASE_ADD         0x98000000
222 140 julius
#define ETH_DATA_BASE           (SDRAM_SIZE - (0x600 * 128)) /*  Address for ETH_DATA */
223 2 marcus.erl
 
224 140 julius
#define CRT_ENABLED             0
225 2 marcus.erl
#define FB_BASE_ADDR            0xa8000000
226
 
227
/* Whether online help is available -- saves space */
228
#define HELP_ENABLED            1
229
 
230
/* Whether self check is enabled */
231
#define SELF_CHECK              0
232
 
233
/* Whether we have keyboard suppport */
234 140 julius
#define KBD_ENABLED             0
235 2 marcus.erl
 
236
/* Keyboard buffer size */
237
#define KBDBUF_SIZE             256
238
 
239
/* Which console is used (CT_NONE, CT_SIM, CT_UART, CT_CRT) */
240
#define CONSOLE_TYPE            CT_UART
241
 
242
#endif

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.