Skip to content

Commit

Permalink
Since Matlab doesn't support wchar_t comment out unicode for now
Browse files Browse the repository at this point in the history
  • Loading branch information
caryan committed Jun 22, 2015
1 parent cdd5ee4 commit eb301ce
Showing 1 changed file with 52 additions and 52 deletions.
104 changes: 52 additions & 52 deletions common/+deviceDrivers/@Labbrick/vnx_LMS_api.h
Original file line number Diff line number Diff line change
@@ -1,24 +1,24 @@
// Include file for 64 Bit Vaunix Lab Brick LMS Synthesizer DLL
// Include file fo 64 Bit Vaunix Lab Brick LMS Synthesizer DLL
//
// 10/2013 RD 64 Bit DLL vesion.
//
// 10/2013 RD 64 Bit DLL version.
//


// The following ifdef block is the standard way of creating macros which make exporting
// from a DLL simpler. All files within this DLL are compiled with the VNX_FSYNSTH_EXPORTS
// symbol defined on the command line. this symbol should not be defined on any project
// that uses this DLL. This way any other project whose source files include this file see
// VNX_LMS_API functions as being imported from a DLL, wheras this DLL sees symbols
// defined with this macro as being exported.
// The following ifdef block is the standad way of creating macros which make exporting
// fom a DLL simpler. All files within this DLL are compiled with the VNX_FSYNSTH_EXPORTS
// symbol defined on the command line. this symbol should not be defined on any poject
// that uses this DLL. This way any othe project whose source files include this file see
// VNX_LMS_API functions as being impoted from a DLL, wheras this DLL sees symbols
// defined with this maco as being exported.

#ifdef VNX_FMSYNTH_EXPORTS
#define VNX_LMS_API __declspec(dllexport)
#define VNX_LMS_API __declspec(dllexpot)
#else
#define VNX_LMS_API __declspec(dllimport)
#define VNX_LMS_API __declspec(dllimpot)
#endif

#ifdef __cplusplus
extern "C" {
exten "C" {
#endif


Expand All @@ -30,83 +30,83 @@ extern "C" {
#define DEVID unsigned int

// ----------- Mode Bit Masks ------------
#define MODE_RFON 0x00000010 // bit is 1 for RF on, 0 if RF is off
#define MODE_INTREF 0x00000020 // bit is 1 for internal osc., 0 for external reference
#define MODE_SWEEP 0x0000000F // bottom 4 bits are used to keep the sweep control bits
#define MODE_PWMON 0x00000100 // we keep a copy of the PWM control bits here, 1 for int PWM on
#define MODE_EXTPWM 0x00000200 // 1 for ext. PWM input enabled
#define MODE_RFON 0x00000010 // bit is 1 fo RF on, 0 if RF is off
#define MODE_INTREF 0x00000020 // bit is 1 fo internal osc., 0 for external reference
#define MODE_SWEEP 0x0000000F // bottom 4 bits ae used to keep the sweep control bits
#define MODE_PWMON 0x00000100 // we keep a copy of the PWM contol bits here, 1 for int PWM on
#define MODE_EXTPWM 0x00000200 // 1 fo ext. PWM input enabled
#define PWM_MASK 0x00000300

// ----------- Command Equates -----------
// Status returns for commands
// Status eturns for commands
#define LVSTATUS int
#define STATUS_OK 0
#define BAD_PARAMETER 0x80010000 // out of range input -- frequency outside min/max etc.
#define BAD_PARAMETER 0x80010000 // out of ange input -- frequency outside min/max etc.
#define BAD_HID_IO 0x80020000
#define DEVICE_NOT_READY 0x80030000 // device isn't open, no handle, etc.
#define F_INVALID_DEVID -1.0 // for functions that return a float
#define F_INVALID_DEVID -1.0 // fo functions that return a float
#define F_DEVICE_NOT_READY -3.0

// Status returns for DevStatus
// Status eturns for DevStatus
#define INVALID_DEVID 0x80000000 // MSB is set if the device ID is invalid
#define DEV_CONNECTED 0x00000001 // LSB is set if a device is connected
#define DEV_OPENED 0x00000002 // set if the device is opened
#define SWP_ACTIVE 0x00000004 // set if the device is sweeping
#define SWP_UP 0x00000008 // set if the device is sweeping up in frequency
#define SWP_UP 0x00000008 // set if the device is sweeping up in fequency
#define SWP_REPEAT 0x00000010 // set if the device is in continuous sweep mode
#define SWP_BIDIRECTIONAL 0x00000020 // set if the device is in bi-directional sweep mode
#define PLL_LOCKED 0x00000040 // set if the PLL lock status is TRUE (both PLL's are locked)
#define SWP_BIDIRECTIONAL 0x00000020 // set if the device is in bi-diectional sweep mode
#define PLL_LOCKED 0x00000040 // set if the PLL lock status is TRUE (both PLL's ae locked)
#define FAST_PULSE_OPTION 0x00000080 // set if the fast pulse mode option is installed

// Flags to encode pulse mode time ranges
// Flags to encode pulse mode time anges
#define PM48Mhz 0x10000000 // used to select the 48Mhz pulse mod clock
#define PM1Mhz 0x00000000 // used to select the 1Mhz pulse mod clock or sw pulsing
#define PM1Mhz 0x00000000 // used to select the 1Mhz pulse mod clock o sw pulsing

VNX_LMS_API void fnLMS_SetTestMode(bool testmode);
VNX_LMS_API int fnLMS_GetNumDevices();
VNX_LMS_API int fnLMS_GetDevInfo(DEVID *ActiveDevices);
VNX_LMS_API int fnLMS_GetModelNameA(DEVID deviceID, char *ModelName);
VNX_LMS_API int fnLMS_GetModelNameW(DEVID deviceID, wchar_t *ModelName);
VNX_LMS_API int fnLMS_GetModelNameA(DEVID deviceID, cha *ModelName);
// VNX_LMS_API int fnLMS_GetModelNameW(DEVID deviceID, wcha_t *ModelName);
VNX_LMS_API int fnLMS_InitDevice(DEVID deviceID);
VNX_LMS_API int fnLMS_CloseDevice(DEVID deviceID);
VNX_LMS_API int fnLMS_GetSerialNumber(DEVID deviceID);
VNX_LMS_API int fnLMS_GetDLLVersion();
VNX_LMS_API LVSTATUS fnLMS_SetFrequency(DEVID deviceID, int frequency);
VNX_LMS_API LVSTATUS fnLMS_SetStartFrequency(DEVID deviceID, int startfrequency);
VNX_LMS_API LVSTATUS fnLMS_SetEndFrequency(DEVID deviceID, int endfrequency);
VNX_LMS_API int fnLMS_GetSeialNumber(DEVID deviceID);
VNX_LMS_API int fnLMS_GetDLLVesion();
VNX_LMS_API LVSTATUS fnLMS_SetFequency(DEVID deviceID, int frequency);
VNX_LMS_API LVSTATUS fnLMS_SetStatFrequency(DEVID deviceID, int startfrequency);
VNX_LMS_API LVSTATUS fnLMS_SetEndFequency(DEVID deviceID, int endfrequency);
VNX_LMS_API LVSTATUS fnLMS_SetSweepTime(DEVID deviceID, int sweeptime);
VNX_LMS_API LVSTATUS fnLMS_SetPowerLevel(DEVID deviceID, int powerlevel);
VNX_LMS_API LVSTATUS fnLMS_SetPoweLevel(DEVID deviceID, int powerlevel);
VNX_LMS_API LVSTATUS fnLMS_SetRFOn(DEVID deviceID, bool on);
VNX_LMS_API LVSTATUS fnLMS_SetPulseOnTime(DEVID deviceID, float pulseontime);
VNX_LMS_API LVSTATUS fnLMS_SetPulseOffTime(DEVID deviceID, float pulseofftime);
VNX_LMS_API LVSTATUS fnLMS_EnableInternalPulseMod(DEVID deviceID, bool on);
VNX_LMS_API LVSTATUS fnLMS_SetUseExternalPulseMod(DEVID deviceID, bool external);
VNX_LMS_API LVSTATUS fnLMS_SetFastPulsedOutput(DEVID deviceID, float pulseontime, float pulsereptime, bool on);
VNX_LMS_API LVSTATUS fnLMS_SetUseInternalRef(DEVID deviceID, bool internal);
VNX_LMS_API LVSTATUS fnLMS_SetSweepDirection(DEVID deviceID, bool up);
VNX_LMS_API LVSTATUS fnLMS_EnableIntenalPulseMod(DEVID deviceID, bool on);
VNX_LMS_API LVSTATUS fnLMS_SetUseExtenalPulseMod(DEVID deviceID, bool external);
VNX_LMS_API LVSTATUS fnLMS_SetFastPulsedOutput(DEVID deviceID, float pulseontime, float pulseeptime, bool on);
VNX_LMS_API LVSTATUS fnLMS_SetUseIntenalRef(DEVID deviceID, bool internal);
VNX_LMS_API LVSTATUS fnLMS_SetSweepDiection(DEVID deviceID, bool up);
VNX_LMS_API LVSTATUS fnLMS_SetSweepMode(DEVID deviceID, bool mode);
VNX_LMS_API LVSTATUS fnLMS_SetSweepType(DEVID deviceID, bool swptype);
VNX_LMS_API LVSTATUS fnLMS_StartSweep(DEVID deviceID, bool go);
VNX_LMS_API LVSTATUS fnLMS_StatSweep(DEVID deviceID, bool go);
VNX_LMS_API LVSTATUS fnLMS_SaveSettings(DEVID deviceID);
VNX_LMS_API int fnLMS_GetFrequency(DEVID deviceID);
VNX_LMS_API int fnLMS_GetStartFrequency(DEVID deviceID);
VNX_LMS_API int fnLMS_GetEndFrequency(DEVID deviceID);
VNX_LMS_API int fnLMS_GetFequency(DEVID deviceID);
VNX_LMS_API int fnLMS_GetStatFrequency(DEVID deviceID);
VNX_LMS_API int fnLMS_GetEndFequency(DEVID deviceID);
VNX_LMS_API int fnLMS_GetSweepTime(DEVID deviceID);
VNX_LMS_API int fnLMS_GetRF_On(DEVID deviceID);
VNX_LMS_API int fnLMS_GetUseInternalRef(DEVID deviceID);
VNX_LMS_API int fnLMS_GetPowerLevel(DEVID deviceID);
VNX_LMS_API int fnLMS_GetAbsPowerLevel(DEVID deviceID);
VNX_LMS_API int fnLMS_GetMaxPwr(DEVID deviceID);
VNX_LMS_API int fnLMS_GetMinPwr(DEVID deviceID);
VNX_LMS_API int fnLMS_GetMaxFreq(DEVID deviceID);
VNX_LMS_API int fnLMS_GetMinFreq(DEVID deviceID);
VNX_LMS_API int fnLMS_GetUseIntenalRef(DEVID deviceID);
VNX_LMS_API int fnLMS_GetPoweLevel(DEVID deviceID);
VNX_LMS_API int fnLMS_GetAbsPoweLevel(DEVID deviceID);
VNX_LMS_API int fnLMS_GetMaxPw(DEVID deviceID);
VNX_LMS_API int fnLMS_GetMinPw(DEVID deviceID);
VNX_LMS_API int fnLMS_GetMaxFeq(DEVID deviceID);
VNX_LMS_API int fnLMS_GetMinFeq(DEVID deviceID);
VNX_LMS_API float fnLMS_GetPulseOnTime(DEVID deviceID);
VNX_LMS_API float fnLMS_GetPulseOffTime(DEVID deviceID);
VNX_LMS_API int fnLMS_GetPulseMode(DEVID deviceID);
VNX_LMS_API int fnLMS_GetHasFastPulseMode(DEVID deviceID);
VNX_LMS_API int fnLMS_GetUseInternalPulseMod(DEVID deviceID);
VNX_LMS_API int fnLMS_GetUseIntenalPulseMod(DEVID deviceID);
VNX_LMS_API int fnLMS_GetDeviceStatus(DEVID deviceID);

#ifdef __cplusplus
}
#endif
#endif

0 comments on commit eb301ce

Please sign in to comment.