blast.h
上传用户:fy98168
上传日期:2015-06-26
资源大小:13771k
文件大小:2k
- /***************************************************************************
- File name : blast.h
- Description : BLAST header file.
- COPYRIGHT (C) 2002 STMicroelectronics
- Date Modification Initials
- ---- ------------ --------
- 04 Sep 03 Created TM
- *****************************************************************************/
- #ifndef __BLAST_H
- #define __BLAST_H
- /* ************************************************************************
- I N C L U D E S
- ************************************************************************ */
- #include "stblast.h"
- #include "stevt.h"
- #include "stcommon.h"
- #include "pio.h"
- /* ************************************************************************
- D E F I N E S
- ************************************************************************ */
- #define NUMBER_BLAST 2
- #define SYMBOL_BUFFER_SIZE 200
- #define BLASTER_TRANSMITTER 0
- #define BLASTER_RECEIVER 1
- extern ST_DeviceName_t PIO_DeviceName[];
- /* ************************************************************************
- C O N S T A N T S
- ************************************************************************ */
- #if defined(ST_5105) || defined(ST_5107)
- #define BLAST_RXD_PIO PIO_DeviceName[2]
- #define BLAST_TXD_PIO PIO_DeviceName[2]
- #define BLAST_RXD_BIT PIO_BIT_4
- #define BLAST_TXD_BIT PIO_BIT_5
- #elif defined (ST_5100)
- #define BLAST_RXD_PIO PIO_DeviceName[3]
- #define BLAST_TXD_PIO PIO_DeviceName[3]
- #define BLAST_RXD_BIT PIO_BIT_6
- #define BLAST_TXD_BIT PIO_BIT_7
- #define BLAST_TXDINV_BIT PIO_BIT_3
- #else
- #error Device not specified!!
- #endif
- /* ************************************************************************
- D A T A T Y P E S
- ************************************************************************ */
- /* ************************************************************************
- G L O B A L S
- ************************************************************************ */
- /* semaphore used by event handler */
- extern semaphore_t BlasterSemaphore;
- /* handle for open API */
- extern STBLAST_Handle_t BlasterHandle[NUMBER_BLAST];
- /* Used by event handler */
- extern ST_ErrorCode_t LastEvent;
- extern ST_ErrorCode_t LastError;
- #endif /* __BLAST_H */
- /* EOF */