RI Title
RI logo

It may be useful to reference a Symbol that contains an Array to use for Frequency or Power sweeps or other reasons. The Edit Symbol Table includes a Value > Add Array action, but the standard way to edit those values is to double click the values until there is just one value to edit (See Figure 2). This can be tedious for creating or editing large arrays, so an alternative method is available.

To Save an Array Using Edit Symbol Table:
    1. While editing a Testplan with Cassini application, choose Options > Edit Symbol Table to open the Symbol Table Editor window.
    2. In the left pane, select an existing Symbol Name or choose Name > Add.
    3. In the right pane, type the characters between the quotes RiRealD fromString:' (ends in a single quote) followed by the elements of the array and a ' (another single quote).
      For example, a 4 element array is RiRealD fromString:'3.2,4.3,5.0,6.8'. (See Figure 1)
    4. Select a different symbol or close the Edit Symbol Table window to evaluate the expression, an Unsaved Changes prompt appears. Choose Yes to Save, or No or Cancel to continue editing.
    5. When you view the Symbol Table, it will appear as an RiRealD ( ## ## ## ## ). (See Figure 2)
    6. Double Clicking on the Symbol Name will open an Edit dialog that displays each element of the array. Double Clicking on the single element will allow you to Edit the value directly. (See Figure 3)
    7. Close the Edit Symbol Table window and choose Options > Save Symbol Table to make the changes permanent (ri.sys.ObjClass = RiTestplanSymbols).

To Use the Symbol Array in a List State Button:
    1. Change any Instrument State button to a List by choosing List from the right mouse button menu and entering a value of 1 for the Number of Values? prompt.
    2. Choose Symbol or Pin List from the button's right mouse button menu.
    3. Type the Symbol Name in the Enter the Symbol Name or [pin list] prompt. (See Figure 4 and Figure 5)
      (Note: The button may not repaint, so to see the change, switch to a different panel and return to that same panel.)
    4. Compile and view the Worksheet to confirm the Symbol's Array data is evaluated correctly.

Figure 1: Edit Symbol Table > Array, Typing New Expression

Figure 2: Array when Viewed

Figure 3: Example Double Click to Edit Element 1 to Edit Array Value

Figure 4: Symbol or Pin List

Figure 5: Enter Symbol name

PrintEmail Link
©2022-2024 Roos Instruments, Inc. All rights reserved.