 
    
hil_get_version
Returns the version of the Quanser HIL API that is installed.
Description
The hil_get_version function returns a t_version structure containing information about the currently installed version of the Quanser HIL API. The t_version structure is defined as:
    typedef struct tag_version
    {
        t_uint32 size;    /* initialize to the size in bytes of the version structure */
        t_uint16 major;   /* major version number */
        t_uint16 minor;   /* minor version number */
        t_uint16 release; /* release number */
        t_uint16 build;   /* build number */
    } t_version;
                The size field must be initialized to the size of the t_version structure before invoking the hil_get_version function.
Prototype
t_error 
hil_get_version(t_version * version);
    
    Parameters
t_version * version
A pointer to a t_version structure. The size field must be initialized to the size of the t_version structure.
Return value
            The return value is 0 if the version is retrieved successfully. Otherwise a
            negative error code is returned. Error codes are
            defined in quanser_errors.h. A suitable error message may be retrieved using 
            msg_get_error_message.
        
Error codes
QERR_VERSION_ARGUMENT_IS_NULL
The version argument is NULL.
QERR_INVALID_VERSION_ARGUMENT
The size field has not been initialized to a valid size for the t_version structure or the pointer is invalid.
Requirements
| Include Files | Libraries | 
|---|---|
| hil.h | hil.lib;quanser_runtime.lib;quanser_common.lib | 
Examples
t_version version_info; version_info.size = sizeof(version_info); hil_get_version(&version_info); _tprintf(_T("Quanser HIL API version %d.%d.\n"), version_info.major, version_info.minor);
         
    
Copyright ©2025 Quanser Inc. This page was generated 2025-06-17. "
                Submit feedback to Quanser about this page.
Link to this page.