62 lines
1013 B
C
62 lines
1013 B
C
|
|
#ifndef MYWIN_SWD_H__
|
|||
|
|
#define MYWIN_SWD_H__
|
|||
|
|
|
|||
|
|
|
|||
|
|
|
|||
|
|
|
|||
|
|
//定义可以保存的计时组数
|
|||
|
|
#define SPECTRUM_WAVESAVE_MAX 64
|
|||
|
|
|
|||
|
|
|
|||
|
|
|
|||
|
|
|
|||
|
|
typedef struct
|
|||
|
|
{
|
|||
|
|
WIN_WindowStruct win;
|
|||
|
|
char *title;
|
|||
|
|
u8 *icon; //图标
|
|||
|
|
u32 selectTxtColor;
|
|||
|
|
u32 txtColor;
|
|||
|
|
u32 selectRectColor;
|
|||
|
|
u32 rectColor;
|
|||
|
|
WIN_WorkFunStruct *work; //工作结构体
|
|||
|
|
int work_ret; //工作函数的返回值
|
|||
|
|
int timerId;
|
|||
|
|
char msg[100];
|
|||
|
|
u8 *sram_icp;
|
|||
|
|
u32 sram_icpSize;
|
|||
|
|
u8 *swd_buff;
|
|||
|
|
u32 swd_buffSize;
|
|||
|
|
u32 swd_sended;
|
|||
|
|
u32 swd_allSize;
|
|||
|
|
u32 idcode;
|
|||
|
|
u8 swd_err;
|
|||
|
|
}WIN_SwdStruct;
|
|||
|
|
|
|||
|
|
|
|||
|
|
|
|||
|
|
|
|||
|
|
WIN_SwdStruct *WIN_CreatSwd (WIN_WindowStruct *base,
|
|||
|
|
void (*msgLoop)(struct _WIN_WindowStruct *win,WIN_MsgStruct *msg),
|
|||
|
|
int x,int y,int x_size,int y_size);
|
|||
|
|
|
|||
|
|
|
|||
|
|
void WIN_DeleteSwd (WIN_SwdStruct *stopwatch );
|
|||
|
|
|
|||
|
|
|
|||
|
|
|
|||
|
|
//连接,成功返回0
|
|||
|
|
int SWD_Connect (WIN_SwdStruct *swd );
|
|||
|
|
|
|||
|
|
|
|||
|
|
|
|||
|
|
//消息框的消息处理函数
|
|||
|
|
void SWD_defaultMsgLoop (WIN_SwdStruct *stopwatch,WIN_MsgStruct *msg);
|
|||
|
|
|
|||
|
|
WIN_SwdStruct *SWD_EnterProgram (WIN_WindowStruct *base);
|
|||
|
|
|
|||
|
|
|
|||
|
|
#endif
|
|||
|
|
|
|||
|
|
|