loader.h
来自「WinCE 3.0 BSP, 包含Inter SA1110, Intel_815」· C头文件 代码 · 共 166 行
H
166 行
/*++
THIS CODE AND INFORMATION IS PROVIDED "AS IS" WITHOUT WARRANTY OF
ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO
THE IMPLIED WARRANTIES OF MERCHANTABILITY AND/OR FITNESS FOR A
PARTICULAR PURPOSE.
Copyright (c) 1998 Hitachi,Ltd.
Module Name: loader.h
Abstract:
This file defines equates for the Windows CE bootloader
Functions:
Notes:
--*/
#ifndef _LOADER_H_
#define _LOADER_H_ 1
#include <fwentry.h>
#ifdef NULL
#undef NULL
#endif
#ifdef FALSE
#undef FALSE
#endif
#ifdef TRUE
#undef TRUE
#endif
#define FALSE 0
#define TRUE 1
#define NULL (void *)0
#define FLAG_AUTO_LAUNCH 1
#define FLAG_INIT_BREAK 2
#define SRECNV_OK 1
#define SRECNV_XMT 2
#define SRECNV_CHECKSUM 3
#define SRECNV_INVALID_RECORD 4
void
StartMonitor(
void
);
void
RestoreAndGo(
unsigned int vAddr
);
int
DownloadImage(
const unsigned char * pPathName,
unsigned int * pVaddr,
int fLaunch
);
void
OutputFormatString(
const unsigned char *sz, ...
);
unsigned int
FormatString(
unsigned char *pBuf, const unsigned char *sz, ...
);
void
OutputString(
const unsigned char *s
);
int
ConvertSreRecord(
const unsigned char *pBuf,
unsigned int *pFlags,
unsigned int *pVaddr
);
unsigned char
AsciiToUnsignedChar(
const unsigned char * pbuf
);
unsigned int
AsciiToUnsignedint (
const unsigned char * pBuf
);
unsigned int
BigEndianAsciiToUnsignedint (
const unsigned char * pBuf
);
int
atox(
const unsigned char *pbuf,
unsigned int *value
);
unsigned char
toascii(
unsigned char c
);
void
CacheInit(
void
);
void
FlushDCache(
void
);
void
FlushICache(
void
);
void
Launch(
unsigned int uAddr
);
#define MachineSpin() while(1){}
//#define CALL_FUNC(x) ((PFUNC_V_V)x)()
#define RESET_FLAG(flag, field) do {flag &= ~field;} while(0)
#define SET_FLAG(flag, field) do {flag |= field;} while(0)
#define TEST_FLAG(flag, field) (flag & field)
#define LAUNCH_ON_SRE 0
#define FORCE_LAUNCH 1
#define FORCE_BREAK 2
#ifdef MIPS
#define BOOT_TYPE -2
#elif i386
#define BOOT_TYPE -4
#else
#define BOOT_TYPE -1
#endif
#if ((SH_PLATFORM != PLATFORM_ASPEN)&&(SH_PLATFORM != PLATFORM_BIGSUR))
#define FLASH_START 0x8d000000 // starting address of flash memory
#define FLASH_END 0x8d800000 // ending address of flash memory
#define FLASH_BUFF 0x8c080000 // RAM buffer to load flash image
#endif ((SH_PLATFORM != PLATFORM_ASPEN)&&(SH_PLATFORM != PLATFORM_BIGSUR))
#ifdef MIPS
#define OS_ENTRY 0xad000004 // ROM/FLASH OS entry point
#else
#define OS_ENTRY 0xb8000004 // ROM/FLASH OS entry point
#endif
#endif
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?