📄 stdafx.h
字号:
// stdafx.h : include file for standard system include files,
// or project specific include files that are used frequently, but
// are changed infrequently
//
#if !defined(AFX_STDAFX_H__D485DEFF_85AB_11D1_B878_A68EB300DD63__INCLUDED_)
#define AFX_STDAFX_H__D485DEFF_85AB_11D1_B878_A68EB300DD63__INCLUDED_
#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
#define VC_EXTRALEAN // Exclude rarely-used stuff from Windows headers
#include <afxwin.h> // MFC core and standard components
#include <afxext.h> // MFC extensions
#include <afxcview.h>
#include <afxdisp.h> // MFC Automation classes
#include <afxdtctl.h> // MFC support for Internet Explorer 4 Common Controls
/////////////////////////////////
// 用户填加部分
#include "PCI2006.h" // 包含驱动程序接口
#include "ADThread.h" //调用线程
// 定义用于控制数据位数及量程的常数
#define LSB_COUNT 16384.0 // LSB码数量
#define LSB_HALF 8192 // 当取偏移码时,其原点位置
#define VOLT_RANGE 10000.0 // 量程(mV)(注意必须带小数)
// 定义其他常量
#define DeviceName "PCI2006"// 定义设备名
#define MAX_FREQUENCE 410000 // 最高频率
#define MAX_CHANNELCOUNT 32
#define MAX_SEGMENT 64
#define NOT_EMPTY_MODE 0x01//非空采集
#define HALF_MODE 0x02//半满采集
#define INT_MODE 0x03//中断采集
#define RANGE_N5000_TO_P5000 0x01//正负5000毫伏 (N:Negative P:Positive)
#define RANGE_N10000_TO_P10000 0x02//正负10000毫伏
#define RANGE_0_TO_P5000 0x03//0到5000毫伏
#define RANGE_0_TO_P2500 0x04//0到2500毫伏
#define PCI_BUS 0x01
#define USB_BUS 0x02
#define ISA_BUS 0x03
typedef struct _FILE_HEADER
{
DWORD BusType; // 1:PCI, 2:USB, 3:ISA, 4:PC104
DWORD DeviceID; // 0x2006
DWORD HeaderSizeBytes; //文件头信息长度
float VoltBottomRange; // 量程下限
float VoltTopRange; // 量程上限
DWORD ADMode; // 连续采集和分组采集方式选择
DWORD ChannelCount; // 通道总数(1-32)
CHANNEL_ARRAY_AD ChannelArray[32]; // 采样阵列(包括通道和增益)
DWORD Frequency; // AD采集频率(Hz)
DWORD GroupInterval; // 分组采样时,相邻组的时间间隔(uS)
DWORD TriggerSource; // 内触发和外触发方式选择
DWORD OutTriggerEdge; // 外触发上升沿和下降沿类型选择
DWORD OutDigitAnalog; // 外触发数字和模拟方式选择
DWORD ClockSource; // 允许使用外部时钟
DWORD FileEndFlag; //文件结束位
} FILE_HEADER, *PFILE_HEADER;
/////////////////////////////////
#ifndef _AFX_NO_AFXCMN_SUPPORT
#include <afxcmn.h> // MFC support for Windows Common Controls
#endif // _AFX_NO_AFXCMN_SUPPORT
//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
#endif // !defined(AFX_STDAFX_H__D485DEFF_85AB_11D1_B878_A68EB300DD63__INCLUDED_)
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -