element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • About Us
  • Community Hub
    Community Hub
    • What's New on element14
    • Feedback and Support
    • Benefits of Membership
    • Personal Blogs
    • Members Area
    • Achievement Levels
  • Learn
    Learn
    • Ask an Expert
    • eBooks
    • element14 presents
    • Learning Center
    • Tech Spotlight
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents Projects
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Avnet Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • Store
    Store
    • Visit Your Store
    • Choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
  • Settings
Test & Tools
  • Technologies
  • More
Test & Tools
Blog LabVIEW: passing multiple signals as a Dynamic Signal to a submodule (also: log measurements to Excel)
  • Blog
  • Forum
  • Documents
  • Files
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
Join Test & Tools to participate - click to join for free!
  • Share
  • More
  • Cancel
Group Actions
  • Group RSS
  • More
  • Cancel
Engagement
  • Author Author: Jan Cumps
  • Date Created: 15 Apr 2018 5:29 PM Date Created
  • Views 3009 views
  • Likes 4 likes
  • Comments 1 comment
  • labview
Related
Recommended

LabVIEW: passing multiple signals as a Dynamic Signal to a submodule (also: log measurements to Excel)

Jan Cumps
Jan Cumps
15 Apr 2018

How to pass many signals to a submodule as a single dynamic signal.

And how to log measurements to a spreadsheet.

image

This blog is born out of need. My "write to Excel" blocks were taking way too much real estate of my Labview main flow. This blog explains how I

 

Why combine signals?

 

Many reasons. Here's mine:

Some LabVIEW blocks can take in a number of signals. One example is the scope-like display and other graphs. You can give it multiple channels and it will draw them.

The same for the Write to File block. You can send it a dynamic signal containing multiple measurements. It will write them as columns to a spreadsheet.

What the block doesn't do is give meaningful names to these columns, because it doesn't have a clue what it's logging.

LabVIEW has a Set Dynamic Data Attributes block that allows you to tell what (among other things) the column name for a signal is.

You'll need a block for each of your signals. In my case I'm sending seven signals, so my flow will have seven blocks on the flow diagram.

And these seven blocks take significant horizontal space of the workflow, without giving the user much insight of what's happening.

 

image

 

I prefer to only show in the main flow what's necessary to understand what's going on and why a process is branching left or right.

For the reader, it is enough to see that the data is logged to a spreadsheet. The Set Dynamic Data Attributes blocks don't add any visual insight.

 

I wanted to move the details of the data logging to a separate block, so that the main flow only showed a Write To Excel block. That's enough info for the main flow.

But it wasn't easy. I didn't find a solution on the web (my specialty image ). I had to do loads of trial, error and guesswork before I got it right.

That's why I'm writing this article - in case I have to do this again later.

 

Passing a dynamic flow as Parameter

 

I knew how to club multiple measurements in a dynamic signal, with a Merge Signals block.

 

image

 

The difficulties came up when I wanted to move the result to a separate flow. Surfing and reading didn't really help and I couldn't find an example that did the same.

So I moved to trial and error. Use any block that I knew was related to dynamic data and try it. I had one day of frustration, and then success.

Here's how to do it:

 

On the submodule, define an array. That will be your input parameter. Drop a numeric control on it so that it becomes a numeric array.

image

Then link that block with the first Set Dynamic Data Attributes block.

 

image

This will automatically insert a Convert to Dynamic Data block.

But then there's something you have to change: right-click on that converter, and select properties.

Then select 1D array of scalars - multiple channels.

 

image

 

That's it. On the Front Panel, link the array with an input parameter.

You can now link your merged signals with your submodule:

 

image

LabVIEW will again automatically insert a block: Convert from Dynamic Data. You don't need to change that block.

That's it actually. You can now link your merged signals to your submodule.

 

Before:

image

After:

image

  • Sign in to reply

Top Comments

  • genebren
    genebren over 7 years ago +1
    Jan, Another interesting LabVIEW blog. Dynamic Data linking is such a useful tool. I had once dynamically linked data from my debugger to excel to form a pseudo oscilloscope to debug a data collection…
  • genebren
    genebren over 7 years ago

    Jan,

    Another interesting LabVIEW blog.  Dynamic Data linking is such a useful tool.  I had once dynamically linked data from my debugger to excel to form a pseudo oscilloscope to debug a data collection functions within a electro-mechanical device.  This setup save many hours, while allowing me to 'see' realtime data fro within the microprocessor.

    Thanks,

    Gene

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • More
    • Cancel
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2025 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube