📄 library.h
字号:
/**************************************************************************************
*
* Project Name : S3C6400 Validation
*
* Copyright 2006 by Samsung Electronics, Inc.
* All rights reserved.
*
* Project Description :
* This software is only for validating functions of the S3C6400.
* Anybody can use this software without our permission.
*
*--------------------------------------------------------------------------------------
*
* File Name : library.h
*
* File Description : This file defines the register access function
* and declares prototypes of library funcions
*
* Author : Haksoo,Kim
* Dept. : AP Development Team
* Created Date : 2006/11/08
* Version : 0.1
*
* History
* - Created(Haksoo,Kim 2006/11/08)
*
**************************************************************************************/
#ifndef __LIBRARY_H__
#define __LIBRARY_H__
#ifdef __cplusplus
extern "C" {
#endif
#include <stdio.h>
#include "def.h"
#define Assert(a) {if (!(a)) {printf("\n %s(line %d)\n", __FILE__, __LINE__); exit(0);}}
#define Outp32(addr, data) (*(volatile u32 *)(addr) = (data))
#define Outp16(addr, data) (*(volatile u16 *)(addr) = (data))
#define Outp8(addr, data) (*(volatile u8 *)(addr) = (data))
#define Inp32(addr) (*(volatile u32 *)(addr))
#define Inp16(addr) (*(volatile u16 *)(addr))
#define Inp8(addr) (*(volatile u8 *)(addr))
void InitUartPort(u8 ch, bool flowControl);
void InitLED(void);
void DisplayLED(u8 data);
void OpenConsole(void);
s32 GetIntNum(void);
u32 DownloadImageThruUart(u8 *);
void CalibrateDelay(void);
void Delay(u32 uTime);
u32 Pow(u32 x, u32 y);
void Copy(u32 sa, u32 da, u32 words);
bool Compare( u32 a0, u32 a1, u32 words);
void Dump32(u32 addr, u32 words);
#ifdef __cplusplus
}
#endif
#endif /*__LIBRARY_H__*/
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -