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

📄 zkbconfig.h

📁 基于Jennic公司Zigbee芯片JN5139做的无线键盘项目源码
💻 H
字号:
/*****************************************************************************
 *
 * MODULE:              Wireless Keyboard Configuration
 *
 * COMPONENT:           $RCSfile$
 *
 * VERSION:             $Name$
 *
 * REVISION:            $Revision$
 *
 * DATED:               $Date$
 *
 * STATUS:              $State$
 *
 * AUTHOR:              APVW
 *
 * DESCRIPTION:
 * Configuration settings for wireless keyboard.
 *
 * LAST MODIFIED BY:    $Author: cjg $
 *                      $Modtime: $
 *
 ****************************************************************************
 *
 * This software is owned by Jennic and/or its supplier and is protected
 * under applicable copyright laws. All rights are reserved. We grant You,
 * and any third parties, a license to use this software solely and
 * exclusively on Jennic products. You, and any third parties must reproduce
 * the copyright and warranty notice and any other legend of ownership on each
 * copy or partial copy of the software.
 *
 * THIS SOFTWARE IS PROVIDED "AS IS". JENNIC MAKES NO WARRANTIES, WHETHER
 * EXPRESS, IMPLIED OR STATUTORY, INCLUDING, BUT NOT LIMITED TO, IMPLIED
 * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE,
 * ACCURACY OR LACK OF NEGLIGENCE. JENNIC SHALL NOT, IN ANY CIRCUMSTANCES,
 * BE LIABLE FOR ANY DAMAGES, INCLUDING, BUT NOT LIMITED TO, SPECIAL,
 * INCIDENTAL OR CONSEQUENTIAL DAMAGES FOR ANY REASON WHATSOEVER.
 *
 * Copyright Jennic Ltd 2005, 2006. All rights reserved
 *
 ****************************************************************************/

#ifndef  KEYB_CONFIG_INCLUDED
#define  KEYB_CONFIG_INCLUDED

#if defined __cplusplus
extern "C" {
#endif

/****************************************************************************/
/***        Include Files                                                 ***/
/****************************************************************************/

/****************************************************************************/
/***        Macro Definitions                                             ***/
/****************************************************************************/

/* Include this define if you want to use keyboard demo mode. 	*/
/* In demo mode, PS2 key codes are convert from MAKE/BREAK		*/
/* sequences into single ASCII printing codes.					*/

/* ZigBee pre-configured network constants */
#define	WKB_PAN_ID				0x1aab
#define	WKB_FIXED_CHANNEL		0x0e

/* ZigBee Profile Identifiers */
/* Currently, no wireless keyboard profile exists,  */
/* so create an example profile identifier.			*/
#define WKB_PROFILE_ID          0x123
#define	WKB_CLUSTER_ID			0x12

/* Atrributes within the endpoint's clusters */
#define	WKB_PS2_SOCKET			0x01
#define WKB_PS2_DISPLAY			0x02

/* Endpoint identifiers for sensor's PS2 port and coordinator's LCD */
#define	WKB_ENDPOINT_PS2		0x30
#define	WKB_ENDPOINT_LCD		0x40

/* Coordinator board LED usage */
#define	LED_COORD_CAPS			0		/* Caps Lock status indicator */
#define	LED_COORD_UNUSED_1		1
#define	LED_COORD_UNUSED_2		2
#define	LED_COORD_UNUSED_3		3

/* Sensor board LED usage */
#define	LED_SENSOR_ACK_PENDING	0		/* LED identifier, for ACK pending period   */
#define	LED_SENSOR_UNUSED_1		1		/* LED identifier, unused.					*/

/* PS2 bus interface, clock and data line allocation */

/* External triger DIO18 - for debug scope 	*/
/* Clock:	       DIO19					*/
/* Data:	       DIO20					*/

#define	DEBUG_EXT_TRIG			((uint32) (1 << 18))
#define	PS2_DIO_CLOCK			((uint32) (1 << 19))
#define	PS2_DIO_DATA			((uint32) (1 << 20))

#define	PS2_DATA_WIDTH			8

/* Timers: using macro overloading, so that timer choice can easily be changed */
#define	KEYB_APPL_TIMER			E_AHI_TIMER_0
#define	PS2_SOCKET_TIMER		E_AHI_TIMER_1

/****************************************************************************/
/***        Type Definitions                                              ***/
/****************************************************************************/

/****************************************************************************/
/***        Exported Functions                                            ***/
/****************************************************************************/

/* System wide access to the wake-timer calibration offset.  				*/
/* Required because the wake-timer is driven by a 32kHz RC oscillator       */
/* which has a wide manufacturing tolerance (ie not a crystal oscillator).	*/

PUBLIC uint32 u32GetCalibOffset(void);


/****************************************************************************/
/***        Exported Variables                                            ***/
/****************************************************************************/

#if defined __cplusplus
}
#endif

#endif  /* KEYB_CONFIG_INCLUDED */

/****************************************************************************/
/***        END OF FILE                                                   ***/
/****************************************************************************/

⌨️ 快捷键说明

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