⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 e_event.h

📁 凌阳32位单片机开发的小游戏
💻 H
字号:
/******************************************************************************
 *
 *     The information contained herein is the exclusive property of
 *   Sunplus Technology Co. And shall not be distributed, reproduced,
 *   or disclosed in whole in part without prior written permission.
 *
 *         (C) COPYRIGHT 2005   SUNPLUS TECHNOLOGY CO.
 *                        ALL RIGHTS RESERVED
 *
 * The entire notice above must be reproduced on all authorized copies.
 *
 *****************************************************************************/

/******************************************************************************
 *  Filename:   	E_Event.h
 *  Author:     	Robin.xjliu  (eMail: xjliu@sunplus.com)
 *  Tel:        	00885-028-87848688-5884
 *  Date:       	2005-11-22
 *  Description:	some function deal with texture,like scroll screen
 *  Reference:
 *  Version history:
 *-----------------------------------------------------------------------------
 *	Version   YYYY-MM-DD-INDEX   Modified By         Description
 *	1.0.0     2005-11-22           xjliu               Create
 *
 *****************************************************************************/
#ifndef _E_EVENT_H
#define _E_EVENT_H

#include "../SysLib_Basic/Include/Sys_Global.h"
#include "../SysLib_Basic/Include/GPIO_Joystick.h"

/**
 * virtual input key value define
 */
typedef enum
{
	VK_START = 0,
	VK_MODE,
	VK_A,
	VK_B,
	VK_UP,
	VK_DOWN,
	VK_LEFT,
	VK_RIGHT,
	VK_LEFTUP,	
	VK_RIGHTUP,	
	VK_LEFTDOWN,
	VK_RIGHTDOWN,
	VK_MAX_NUM,
}VIRTUAL_KEY;

/**
 * event type define
 */
typedef enum
{
	EV_JOYSTICK,
	EV_SENSOR,
	EV_TOUCHPANEL,
}EVENT_TYPE;

/**
 * event define
 */
typedef struct 
{
	EVENT_TYPE	Ev_Type;
	VIRTUAL_KEY	Ev_Key;
	U32			Ev_X;
	U32			Ev_Y;
	U32			Reserved;
}EVENT;

/**
 * command define
 */
typedef struct 
{
	S16		StepX;		//movement step in horizontal direction; + to right, - to left
	S16		StepY;		//movement step in vertial direction; + to down, - to up
	U16		Button;		//keyup: 0; keydown: 1;
						//bit0 - start
						//bit1 - mode
						//bit2 - A
						//bit3 - B
}CMD;

extern EVENT g_stEvent;

void E_InputService(EVENT_TYPE msg);



#endif	//_E_EVENT_H


⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -