MegunoLink’s Property Table visualizer lists name/value pairs in a table. MegunoLink continuously looks at data in the serial stream from your Arduino for specially formatted commands to populate the table. The Property Table visualizer is useful for:

  • Displaying current settings such as a temperature set-point
  • Reporting state, such as battery voltage or motor direction
  • Providing a summary of the last action your program took such as the speed and motor direction a linear stage was moved

Each row of a table lists a name, value and description. MegunoLink identifies each row by its name. So when you want to update the row, you supply the name and a new value and/or description:

Table Visualizer

The table visualizer can be used to display summary information and status updates from your Arduino project.

Creating a Property Table Visualizer

Select Property Table from the visualizer menu or toolbox to add a new property table visualizer window to your MegunoLink project. You can add as many table windows as you like. Use message channels in your Arduino sketch to control the data sent to each visualizer.

Drag the visualizer tab to organize the windows in your MegunoLink project.

Property table controls can also be added to interface panels.

Sending Data from an Arduino

Create a Table variable in your Arduino sketch and use its methods to send data and commands to the property table visualizer:

  1. Add #include "MegunoLink.h" to the top of your Arduino program,
  2. Create a Table variable, then
  3. Call SendData, for example, to send a named value to the table in MegunoLink.The property table Arduino reference as details of all the methods available.

Arduino Library

You’ll need to install our Arduino library to create Table variables.

User Interface

The property table visualizer displays a list of name-value pairs in a table. The contents of the table may be freely edited by clicking in any cell. New values can be added either by serial commands received from your Arduino sketch or by entering a name and value pair in the last row.

The table can be sorted by clicking on a column heading. The order of rows can also be customized using the up and down arrow buttons on the toolbar.

Send the value of properties to the connected device. The Send All button sends all of the property values in the table while Send Selected sends only the property values selected.

Property table user interface
The property table visualizer displays rows of named property values, with an optional description.

Sending Properties to an Arduino Sketch

Send selected, or all, property values in the table to your Arduino sketch using the Send Selected and Send All buttons, respectively, on the visualizer toolbar. MegunoLink sends table property values using the format:
![property-name] [property-value]\r\n.

You will need a serial command handler in your Arduino sketch, such as the command handler in our Arduino library, to receive and process property value messages sent from MegunoLink.

Sending values from a property table

Select rows to send commands to your Arduino sketch with updated property values.

Here’s an example, using our command handler, that:

  1. periodically sends variable values to a table,
  2. updates the variable values in response to values send from the table, and
  3. updates the interval between sending values when a UpdateInterval property is received.

The UpdateInterval property isn’t sent from the Arduino sketch here. Simply manually add a new row with the property name and value in the table.

The Arduino’s serial buffer may overflow if you try to update too many variables at once.

Update 3-4 properties at a time by selecting them and clicking Send Selected.

More Information

Start typing and press Enter to search