FrontPanel API 5.3.5
Loading...
Searching...
No Matches
Version-related Macros

Macros

#define OK_API_VERSION_MAJOR   4
 Major version of FrontPanel the application was compiled with.
 
#define OK_API_VERSION_MINOR   5
 Minor version of FrontPanel the application was compiled with.
 
#define OK_API_VERSION_MICRO   7
 Micro version of FrontPanel the application was compiled with.
 
#define OK_API_VERSION_STRING   "4.5.7"
 FrontPanel API version the application was compiled with in string form.
 
#define OK_CHECK_API_VERSION(major, minor, micro)
 Check if FrontPanel version used during compilation is at least the given one.
 

Detailed Description

Macro Definition Documentation

◆ OK_API_VERSION_MAJOR

#define OK_API_VERSION_MAJOR   4

Major version is the first version component, e.g. for FrontPanel 4.5.7 the major version is 4.

Notice that the version actually used during run-time, as returned by OpalKelly::GetAPIVersionMajor(), may be different, e.g. if a newer but compatible version of the library is used.

See also
OK_API_VERSION_MINOR, OK_API_VERSION_MICRO, OK_CHECK_API_VERSION()

◆ OK_API_VERSION_MICRO

#define OK_API_VERSION_MICRO   7

Micro version is the third version component, e.g. for FrontPanel 4.5.7 the major version is 7.

Notice that the version actually used during run-time, as returned by OpalKelly::GetAPIVersionMicro(), may be different, e.g. if a newer but compatible version of the library is used.

See also
OK_API_VERSION_MAJOR, OK_API_VERSION_MINOR, OK_CHECK_API_VERSION()

◆ OK_API_VERSION_MINOR

#define OK_API_VERSION_MINOR   5

Minor version is the second version component, e.g. for FrontPanel 4.5.7 the major version is 5.

Notice that the version actually used during run-time, as returned by OpalKelly::GetAPIVersionMinor(), may be different, e.g. if a newer but compatible version of the library is used.

See also
OK_API_VERSION_MAJOR, OK_API_VERSION_MICRO, OK_CHECK_API_VERSION()

◆ OK_API_VERSION_STRING

#define OK_API_VERSION_STRING   "4.5.7"

This string is composed of dot-separated major, minor and micro version numbers, e.g. "4.5.7" for FrontPanel 4.5.7.

See also
OK_API_VERSION_MAJOR, OK_API_VERSION_MINOR, OK_API_VERSION_MICRO, OpalKelly::GetAPIVersionString()

◆ OK_CHECK_API_VERSION

#define OK_CHECK_API_VERSION ( major,
minor,
micro )

If an application can be compiled with both an older and a newer version of FrontPanel SDK but still wants to use a feature only available in the newer version, it can do something like the following:

#if OK_CHECK_API_VERSION(5, 2, 0)
// If it's possible that the run-time version differs, i.e. if the
// application could be compiled with FrontPanel 5.2 but use 5.1 or
// earlier version at run-time, then also call CheckAPIVersion()
// here.
... use features only available in FrontPanel 5.2 ...
#endif
See also
OK_API_VERSION_MAJOR, OK_API_VERSION_MINOR, OK_API_VERSION_MICRO, OpalKelly::CheckAPIVersion()

Copyright (c) 2005-2024 Opal Kelly Incorporated