📄 config.h
字号:
/* config.h - Motorola MPC5200 board configuration header *//* Copyright 1984-2003 Wind River Systems, Inc. *//*This file contains the configuration parameters for the BSP.*/#ifndef INCconfigh#define INCconfigh#ifdef __cplusplusextern "C" {#endif/* BSP version/revision identification, before configAll.h */#define BSP_VER_1_1 0#define BSP_VER_1_2 1#define BSP_VERSION "1.2"#define BSP_REV "/9"#include "configAll.h" /* Set the VxWorks default configuration */#include "lite5200b.h"/* Memory configuration *//* * The constants ROM_TEXT_ADRS, ROM_SIZE, & RAM_HIGH_ADRS are defined in * config.h, MakeSkel, Makefile, and Makefile. All definitions for these * constants must be identical. *//* --- ROM image boot at FFF00100 (BOOT_HIGH = 1) --- */#define LOCAL_MEM_LOCAL_ADRS 0x00000000 /* Physical start of RAM */#define CPU_PCI_SLV_MEM_LOCAL_B LOCAL_MEM_LOCAL_ADRS#define USER_RESERVED_MEM 0x00000000 /* user reserved memory size *//* Flash starts such that it ends at 0xFFFFFFFF */#define FLASH_BASE_ADRS (0xFFFFFFFF-FLASH_SIZE+1)#define ROM_BASE_ADRS 0xFF000000 /* Physical start of ROM */#define ROM_TEXT_ADRS 0xFFF00100 /* ROM entry address */#define ROM_SIZE 0x01000000 /* 16M bytes of ROM space */#define LOCAL_MEM_SIZE 0x10000000 /* 256 Megabyte */#define RAM_LOW_ADRS LOCAL_MEM_LOCAL_ADRS+0x00100000 /* RAM test/data address */#define RAM_HIGH_ADRS LOCAL_MEM_LOCAL_ADRS+0x01E00000 /* RAM address for ROM boot */#define DRAM_BITS 0x1A#define ROM_WARM_ADRS (ROM_TEXT_ADRS+8) /* warm reboot entry */#undef LOCAL_MEM_AUTOSIZE /* not supported *//* Serial port configuration */#define INCLUDE_SERIAL#undef NUM_TTY#define NUM_TTY N_SIO_CHANNELS#ifdef IS_CP2#undef CONSOLE_TTY#define CONSOLE_TTY 0 /* console channel is /tyCo/0 (=COM0)*/#endif#undef CONSOLE_BAUD_RATE#define CONSOLE_BAUD_RATE 115200 #define INCLUDE_M5200_PSC_SIO /* COM via PSC */#ifdef IS_CP2#undef INCLUDE_TSFS_BOOT /* boot over target file system */#ifdef INCLUDE_TSFS_BOOT#undef WDB_COMM_TYPE#define WDB_COMM_TYPE WDB_COMM_SERIAL#undef WDB_TTY_CHANNEL#define WDB_TTY_CHANNEL 0 /* use /tyCo/0 (=COM1) */#undef WDB_TTY_BAUD#define WDB_TTY_BAUD 115200#endif /* INCLUDE_TSFS_BOOT */#endif/* Timer configuration */#define INCLUDE_TIMESTAMP#define INCLUDE_AUX_CLK/* * Enable Flash as NvRam. Use the last 512 bytes of flash bank 0 */#undef INCLUDE_FLASH#ifdef INCLUDE_FLASH#ifdef IS_CP2 #define SYS_FLASH_TYPE FLASH_29LV320MB /* Specify 29LV320MB 8-bit, 4MB part */ #define FLASH_WIDTH 1 #define FLASH_CHIP_WIDTH 1 /* adress flash width for polling */ #define FLASH_SECTOR_SIZE 0x10000 /* sector size of 29LV320MB */ #define FLASH_SEGMENT_SIZE 0x10000 /* sector size of 29LV320MB */ #define NV_RAM_ADRS 0x3f0000 /* last flash sector */ #undef FLASH_ADRS #define FLASH_ADRS ROM_BASE_ADRS#elif defined(IS_ICECUBE) || defined(IS_ICECUBE_OLD) #define SYS_FLASH_TYPE FLASH_29LV065D /* Specify 29LV065D 8-bit, 8MB part */ #define FLASH_WIDTH 1 #define FLASH_CHIP_WIDTH 1 /* adress flash width for polling */ #define FLASH_SECTOR_SIZE 0x10000 /* sector size of 29LV065D */ #define FLASH_SEGMENT_SIZE 0x10000 /* sector size of 29LV065D */#if (BOOT_HIGH == 0)#define NV_RAM_ADRS 0x7f0000 /* boot 0x100, use last flash sector of first device */ #undef FLASH_ADRS #define FLASH_ADRS ROM_BASE_ADRS# else#define NV_RAM_ADRS (0xFFFF0000-FLASH_ADRS) /* boot 0xFFF00100, use last flash sector at all */ #undef FLASH_ADRS #define FLASH_ADRS 0xFF800000 /* only the second device */# endif#else# error#endif #undef FLASH_SIZE_WRITEABLE #define NV_RAM_SIZE FLASH_SECTOR_SIZE #define NV_INIT_SIZE (FLASH_SECTOR_SIZE - 0x200) #undef NV_BOOT_OFFSET /* room for init indicator */ #define NV_BOOT_OFFSET NV_INIT_SIZE #define SYS_FLASH_DELAY#else /* INCLUDE_FLASH */ #define NV_RAM_SIZE NONE#endif /* PCI configuration */#define INCLUDE_PCI/* #define INCLUDE_SHOW_ROUTINES */#define INCLUDE_PCI_AUTOCONF#define PCI_CFG_TYPE PCI_CFG_AUTO#if !defined(PRJ_BUILD)#define INCLUDE_SHELL#define INCLUDE_LOG_STARTUP#endif/* * Cache configuration * Note that when MMU is enabled, cache modes are controlled by * the MMU table entries in sysPhysMemDesc[], not the cache mode * macros defined here. */#define INCLUDE_CACHE_SUPPORT#define USER_I_CACHE_ENABLE #undef USER_I_CACHE_MODE#define USER_D_CACHE_ENABLE #undef USER_D_CACHE_MODE#if 1#define SNOOP_ENABLE#endif#ifdef SNOOP_ENABLE#define USER_I_CACHE_MODE (CACHE_WRITETHROUGH | CACHE_SNOOP_ENABLE)#define USER_D_CACHE_MODE (CACHE_WRITETHROUGH | CACHE_SNOOP_ENABLE)#else#define USER_I_CACHE_MODE (CACHE_COPYBACK)#define USER_D_CACHE_MODE (CACHE_COPYBACK)#endif/* MMU configuration */#define INCLUDE_MMU_BASIC#undef INCLUDE_MMU_FULL#define USER_I_MMU_ENABLE#define USER_D_MMU_ENABLE/* create a single macro INCLUDE_MMU */#if defined(INCLUDE_MMU_BASIC) || defined(INCLUDE_MMU_FULL)#define INCLUDE_MMU#endif/* Only one can be selected, FULL overrides BASIC */#ifdef INCLUDE_MMU_FULL# undef INCLUDE_MMU_BASIC#endif/* Network driver configuration */#define INCLUDE_NETWORK#ifdef IS_CP2#define INCLUDE_USB_PEGASUS_END /* (END) USB Pegasus (Netgear FA101) */#else#undef INCLUDE_USB_PEGASUS_END /* (END) USB Pegasus (Netgear FA101) */#endif#define INCLUDE_FEC_END /* (END) FEC Ethernet driver */#undef INCLUDE_EL_3C90X_END /* (END) 3Com Fast EtherLink XL PCI */ /* not tested */#if defined(IS_ICECUBE) && defined(PRJ_BUILD)#define INCLUDE_FEI82557END /* END-style CPM Ethernet driver */#endif#undef INCLUDE_BP#undef INCLUDE_EX#undef INCLUDE_ENP#undef INCLUDE_SM_NET#undef INCLUDE_SM_SEQ_ADD/* MAC Address configuration */#if defined(INCLUDE_FEC_END)#define MAC_ADRS_LEN 6 /* 6 bytes in MAC address */#define WR_ENET0 0x00 /* WR specific portion of MAC (MSB->LSB) */#define WR_ENET1 0xa0#define WR_ENET2 0x1e #define CUST_ENET3 0x01 /* Customer specific portion of MAC address */#define CUST_ENET4 0x02#define CUST_ENET5 0x03#define ENET_DEFAULT 0x1ea00000#define ETHERNET_MAC_ADRS {WR_ENET0, WR_ENET1, WR_ENET2, CUST_ENET3, CUST_ENET4, CUST_ENET5}#define ETHERNET_ADR_SET /* (used in bootConfig.c to enable 'N' command) */#endif /* INCLUDE_FEC_END *//* Only if using network *//* Network Driver Types */#ifdef INCLUDE_NETWORK#define INCLUDE_NET_INIT#define STANDALONE_NET#else#undef INCLUDE_NET_INIT#endif/* Boot device */#undef INCLUDE_END#undef INCLUDE_BSD#undef INCLUDE_WDB#ifdef IS_CP2#if defined(INCLUDE_FEC_END)# define INCLUDE_END /* Enhanced Network Driver (see configNet.h) */# undef WDB_COMM_TYPE# define WDB_COMM_TYPE WDB_COMM_END /* task and system debugging */#endif /* */#if defined(INCLUDE_USB_PEGASUS_END)# define INCLUDE_END /* Enhanced Network Driver (see configNet.h) */# undef WDB_COMM_TYPE# define WDB_COMM_TYPE WDB_COMM_NETWORK /* task debugging only available */#endif /* */#if defined(INCLUDE_TSFS_BOOT)# undef WDB_COMM_TYPE# define WDB_COMM_TYPE WDB_COMM_SERIAL# undef WDB_TTY_CHANNEL# define WDB_TTY_CHANNEL 0# undef WDB_TTY_BAUD# define WDB_TTY_BAUD 115200#endif /* */#endif#if defined(IS_ICECUBE) || defined(IS_ICECUBE_OLD)|| defined(IS_LITE5200B)#ifdef INCLUDE_NETWORK#define TSF_BOOT 0#define FEC_END 1#define FEI_END 2#define PEGASUS_USB 3#define BOOT_DEVICE FEC_END /* Specify Boot Device: FEC_END */#if defined(INCLUDE_FEC_END) && (BOOT_DEVICE == FEC_END)# define INCLUDE_END /* Enhanced Network Driver (see configNet.h) */# define BOOT_DEV_NAME "fec"# undef WDB_COMM_TYPE# define WDB_COMM_TYPE WDB_COMM_END /* END-style CPM Ethernet driver */# define INCLUDE_WDB#elif defined(INCLUDE_FEI_END) && (BOOT_DEVICE == FEI_END)# define INCLUDE_END /* Enhanced Network Driver (see configNet.h) */# define BOOT_DEV_NAME "fei"# undef WDB_COMM_TYPE# define WDB_COMM_TYPE WDB_COMM_END /* END-style CPM Ethernet driver */#elif defined(INCLUDE_USB_PEGASUS_END) && (BOOT_DEVICE == PEGASUS_USB)# define INCLUDE_END /* Enhanced Network Driver (see configNet.h) */# define BOOT_DEV_NAME "usb"# undef WDB_COMM_TYPE# define WDB_COMM_TYPE WDB_COMM_NETWORK /* END-style CPM Ethernet driver */#elif defined(INCLUDE_TSFS_BOOT) && (BOOT_DEVICE == TSFS_BOOT)# define BOOT_DEV_NAME "tsfs"# undef WDB_COMM_TYPE# define WDB_COMM_TYPE WDB_COMM_SERIAL# undef WDB_TTY_CHANNEL# define WDB_TTY_CHANNEL 0# undef WDB_TTY_BAUD# define WDB_TTY_BAUD 9600#else# undef INCLUDE_WDB#endif#endif#endif/* Debuging configuration *//* * If the FORCE_DEFAULT_BOOT_LINE is defined then the DEFAULT_BOOT_LINE * parameters are always used regardless of NVRAM values specified at * bootrom time. See target.nr for details. This is usually used to debug * WR downloaded images with out a bootrom present. */#ifdef PRJ_BUILD#undef FORCE_DEFAULT_BOOT_LINE#else#define FORCE_DEFAULT_BOOT_LINE#endif#ifdef INCLUDE_WDB_COMM_VTMD#define FORCE_DEFAULT_BOOT_LINE /* When using TMD this macro should be undefined */#endif /* INCLUDE_WDB_COMM_VTMD *//* visionWARE configuration */#undef INCLUDE_VWARE_LAUNCH/* Stuff to be excluded if FORCE_DEFAULT_BOOT_LINE defined */#ifdef FORCE_DEFAULT_BOOT_LINE#undef INCLUDE_VWARE_LAUNCH#undef NV_RAM_SIZE#define NV_RAM_SIZE NONE#endif /* FORCE_DEFAULT_BOOT_LINE *//* Boot line configuration */#define HOSTNM "mars"#define HOSTPATH "vxWorks"#define TARGETNM "lite5200b"#define HOSTIP "192.168.80.1"#define TARGETIP "192.168.80.5:ffff0000"#define GATEWYIP ""#define USERNAME ""#define PASSWORD ""#define DEFAULT_BOOT_LINE BOOT_DEV_NAME \ "(0,0)" HOSTNM ":" HOSTPATH " " \ "e=" TARGETIP " " \ "h=" HOSTIP " " \ "u=" USERNAME " pw=" PASSWORD " " \ "f=0x80 tn=" TARGETNM/* Include hardware header file */#define INCLUDE_BESTCOMM_INIT/* GPT Timer support */#undef INCLUDE_MPC5200_GPT_TIMER#ifdef INCLUDE_MPC5200_GPT_TIMER#define SYS_USER_CLK_TIMER_NUM 1#define SYS_USER_AUXCLK_TIMER_NUM 2#endif /* INCLUDE_MPC5200_GPT_TIMER *//* Shell */#undef INCLUDE_SHELL#define INCLUDE_TFTP_CLIENT#define INCLUDE_SELF_SHELL#define INCLUDE_WDB#define INCLUDE_ATA#define ATA_MAX_CTRLS 1#define WRONG_CPU_MSG "Unsupported processor type for this board.\n";#define INCLUDE_DOSFS_MAIN /* dosFsLib (2) */#define INCLUDE_DOSFS_FAT /* dosFs FAT12/16/32 FAT handler */#define INCLUDE_CBIO /* CBIO API module *//* And, either one or both of the following components are required: */#define INCLUDE_DOSFS_DIR_VFAT /* Microsoft VFAT direct handler */#define INCLUDE_DOSFS_DIR_FIXED /* Strict 8.3 & VxLongNames directory handler *//* Optional CBIO components are: */#define INCLUDE_DISK_CACHE /* CBIO API disk caching layer */#define INCLUDE_DISK_PART /* disk partition handling code */#define INCLUDE_DISK_UTIL /* ls, cd, mkdir, xcopy, etc */#define INCLUDE_DOSFS_FMT /* dosFs2 file system formatting module */#define INCLUDE_DOSFS_CHKDSK /* file system integrity checking */#define INCLUDE_PART_SHOW #define INCLUDE_LOG_STARTUP#define INCLUDE_NET_SHOW #define INCLUDE_FTP_SERVER#ifdef __cplusplus}#endif#endif /* INCconfigh */#if defined(PRJ_BUILD)#include "prjParams.h"#endif
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -