Academic Company Events NI Developer Zone Support Solutions Products & Services Contact NI MyNI
This Document is not yet Rated  Rate this Document

Can I Programmatically Read the VXI User Window Size?

Primary Software: Utility Software>>Measurement & Automation Explorer
Primary Software Version: 3.1
Primary Software Fixed Version: N/A
Secondary Software: N/A

Problem: I am creating a test program for my VXI system. If the VXI user window size has not been set to a suitable value, my test program will hang. As such, I would like to look at this value right at the beginning. If it is too low, I want to inform the user appropriately. How can I do this?

Solution: The VXI User Window size is a property that is set directly in Measurement & Automation Explorer (MAX) or VXIedit. It is required to be large enough to accommodate the size requested in any viMapAddress (VISA API) or MapVXIAddress (VXI API).

There is no way for you to directly read what this value is, however, you can access information indirectly. The VXI user window size is set in powers of 2. Lets assume that you require a VXI user window size to be 256 k. You can do the following:
  1. At the beginning of your test program, do a mapping of size GREATER than 128 k (using viMapAddress in VISA or MapVXIAddress in the NI-VXI API).
  2. If the command runs successfully, then immediately unmap the window. This means that you must have the VXI user window size set to at least 256 k.
  3. If the mapping fails then you can prompt the user appropriately.
Note: For this example, it is recommended that you map less than 256 k because there is some space set aside for overhead.

Related Links: KB 2LUD3IUK: Can You Change the VXI User Window Size Programmatically?
NI-VISA Programmer Reference Manual
NI-VXI Programmer Reference Manual

Attachments:





Report Date: 11/06/2003
Last Updated: 11/19/2004
Document ID: 3359LCOK

Your Feedback! poor Poor  |  Excellent excellent   Yes No
 Document Quality? 
 Answered Your Question? 
  1 2 3 4 5
Please Contact NI for all product and support inquiries.submit