Tumblelog by Soup.io
Newer posts are loading.
You are at the newest post.
Click here to check if anything new just came in.

February 01 2019

2588 7504 420
scheiß text coding, viva graphical programming

June 12 2018

April 26 2018

April 06 2018

Play fullscreen

"you promised me JSON and sent XML?"

äh, was hat json denn für vorteile? außer dass ich ein weiteres plugin installieren muss...

es scheint Vorteile zu geben, oder der Standard ist inzwischen recht groß.... jedenfalls gibt es in der Base LabView Entwicklungsumgebung bereits fertige Vis

Tags: coding labview

October 22 2017

September 30 2017

September 21 2017

myMozart: A robotic piano player


Turn any old keyboard into a robotic instrument using the myMozart.

Low cost and easy to set up, simply pick a MIDI file and start listening.



I've always loved music and always thought that robots are cool. So I decided to join the two with myMozart and prove that engineering can be fun.



August 06 2017

What is Numeric Array Out following execution of the VI?


NOTE:  Flush Queue returns an array of the elements remaining in the queue into Numeric Array Out.


Lossy enqueue.png

 lossy enqueue drops oldest elements first (if max size is reached)

loop pushes [0,1,2,3,4] then 0 is dropped and 5 enqueued, then 1 is dropped and 6 enqueued --> [2,3,4,5,6]

July 20 2017

Message Bus Architecture - An Intro



It all started when I was browsing across the forums and realised that I wanted an architecture that took all my favorite elements of LabVIEW (User events, Polymorphic VIs, Ease of Use, Flexibility being among them) and put them together all in one architecture...


Let me introduce the idea of a Message Bus. You have subscribers to a message bus that can send or receive messages and perform actions as a result.

Basic topology.png

A subscriber spends most of its time waiting for a message on the bus, and once its received a message, it can choose to discard or process it, and perform any neccessary actions.

So what is a message? Its a user event that contains a Message ID and Message Data (as shown below)

Message format.png

Ok, thats good so far, but what about SubVIs?

Basic tiered topology.png

I propose that SubVIs (By this, I mean major SubVIs, that contain a big portion of your programs functionality like the DAQ handler, or a Comms handler) have their own local message bus and are linked to the top level bus via a Link. This means that all Top Level messages like Stop commands/Control commands are forwarded to the local message bus. This allows you to Stop all the subscribers (and hence the SubVI) from the top level easily, as well as send configuration/start/data messages. Now you have something that conceptually looks like this:

Basic tiered topology with vi scope shown.png

Now I'm thinking- how I report things like error data back to the top level so it can decide whats next in terms of program execution?

Bidirectional concept.png

...with this architecture its easy to send data back up to the Top Level VI too.


What do the VIs look like?


What would a typical subscriber look like?

A subscriber.png

I have written an example VI that shows typical usage of this architecture, including the 'Link and Filter' functionality where a local bus can choose to only listen to certain message IDs, therefore reducing the traffic internally.

If you have any questions, please comment on this and if it highlights a lack of detail in this article, I will append it in.

I have attached 2 versions of the architecture, both in LabVIEW 2009SP1. One uses Strings in the Message ID, and the other uses a Strict Type Def Enum as the Message ID. Both have their advantages and disadvantages (loose coupling vs. tight coupling), and if you are undecided with this, I'd look at the String version first.

Mark B

===If this fixes your problem, mark as solution!===
Tags: labview cld

July 09 2017

%.; will use decimal point

%,: will use decimal comma

%; will use the regional specific decimal character


July 01 2017

3889 1cda 420
Tags: labview runden

June 29 2017

6607 619c 420

video 1

funktionstest matrix ATM, Ausschnitt

June 03 2017

the verbose manual

3.1 Overview This part of the documentation describes connection and configuration of the motor controller within a Modbus network. It is targeted at people who are already familiar with this bus protocol.


May 31 2017

3371 bc0d 420
let's nerd ....

May 18 2017

labview tools for later use 1


Sync utc
                    time The OCC Sync UTC Time program provides a simple interface for synchronizing a Windows computer to the time signal provided by an NTP server.  Both time and date are synchronized to a sub-second accuracy.  Note that this program sets the computer System Time to the UTC time on the NTP server.  The computer time will be further adjusted according to the time zone selected in the OS.
Sync utc time
The list of available NTP servers is determined by the OCC Sync UTC Time.ini file, located in the program directory.  If this file is not present, it is created with a single NIST NTP server listed.  To alter the list of NTP servers, edit the .ini file and add entries of the form
NTP n = xxx.xxx.xxx.xxx
where n is an integer starting with 0 and increasing sequentially andxxx.xxx.xxx.xxx is the IP address of an NTP server.

This software is freeware licensed under the Creative Commons Attribution-No Derivative Works 3.0 License (http://creativecommons.org/). It may be freely distributed and used as long as no derivative products are developed and the attribution to the original author remains intact.
   OCC Sync UTC Time ver for Windows (55MB) (This installs a built executable program with the LabVIEW Run-Time Engine and can be run on any Windows 2000 or XP system without additional software.)
   OCC Sync UTC Time LabVIEW 8.2.1 source code version (543KB) (This zip file includes the LabVIEW source code for the program, the dll that it calls, and all the project files required for building an executable and installer.)

Mass calculator
                  program front panel
            spectroscopy peak identifier  The Mass Spectroscopy Peak Identifiier program (LV 6.1, 330 KB) is a tool I developed for helping to identify mass peaks in time-of-flight mass spectra.  This program assumes that the atomic masses are integers.  It uses a text file which defines which atoms to include in the calculations and then presents the user with an interactive screen which allows various parameters to be set.  The program then uses the atomic definitions file and the parameters to calculate all the atomic combinations that add up to a given mass.  Valences are accounted for, though combinations that do not have the appropriate valence are also shown.  Results for each mass that is calculated can be stored to a file.  One atomic definitions text file is included with the download.  This file is called Sea Salt.pks and includes the elements most commonly observed in mass spectra of sea salt particles. 
   The Mass Calculator described below is included as a pop-up window.  Ken Aiken of the NOAA Aeronomy Lab helped develop this program.

May 09 2017

Practical Nonlinear Fitting



Fitting of experimental data to a nonlinear model is a very common task in science. It allows the parameterization of potentially huge amounts of data based on a given mathematical model.

A simple example would be an exponentially decaying curve: We start out with thousands of potentially meaningless points and end up with an (1) amplitude, (2) decay constant, (3) offset (and an estimate of the noise in the data). These three parameters can fully describe the data in terms of a few physically meaningful numbers if the model is correct.

It is obvious that a successful fit requires a proper choice of a model. If we would try to fit the same exponential data to a Gaussian line shape or a high order polynomial, we might get an equally good fit, but the resulting parameters would be completely meaningless.

With LabVIEW 8.0, nonlinear least square fitting has become flexible, simple and powerful. (Pre-8.0, you typically needed to roll your own, because the stock LabVIEW fitting tools were basically unusable). With the current design (model reference, "Data" variant input, etc.) anything (anything!!!) is now possible and I have posted numerous specific examples in the LabVIEW forum over the years dealing with 1D and 2D data. An example of what can be done is my fitting program for multicomponent EPR spectra. Here the model contains up to ~150 parameters and any subset can be selected to be fit, with the remaining parameters held fixed based on prior knowledge.

The example attached below will serve as guidelines for beginners on how to implement several useful basic techniques that will make nonlinear fitting flexible and scalable. For the first round I will introduce a simple example showing a way to:

  1. Make the model scalable for a variable number of components so we don't need to rewrite it every time the number of components changes.
  2. Allow a run time selection of a subset of parameters to be fit. This way we need to write the model only once, and not a seperate version for each combination of parameters.
  3. ...

In later rounds, I might expand to 2D data, global fitting, ways to handle parameter names, allow real-time monitoring and interruption of the fitting, show how to calculate, format and interpret the correlation matrix, estimate parameter errors, and other useful techniques that anybody in this field should be familiar with.

Over the years, I have posted countless nonlinear fitting examples of various complexity in the LabVIEW forum. My contribution here will be new, general, scalable, and of common interest.


This collection of VIs introduce the concept of nonliner fitting

Example 1:

This is the most basic example distillied to the essentials for simplicity.

It fits a simple exponential decay with three parameters

1. offset

2. amplitude

3. decay constant

Y(t)=Amplitude * exp(-t/decay constant) + offset

Example 2:

Once you understand the simple fit, we add two features to make the code more useful:

scaleable, so it automatically adapts to a multiexponential fit

flexible, so we can select a subset of parameters to be fitted while holding some constant

Y(t) = offset + a1 * exp(-t/DC1) + a2 * exp(-t/DC2) + a3 * exp(-t/DC3) + ...

with the number of terms automatically adjusting based on the number of parameters. 

Example 3:

In example 2, we made the model scalable. Now we utilize that feature to fit a double-exponential decay.

Y(t) = offset + a1 * exp(-t/DC1) + a2 * exp(-t/DC2)

Now that the model is a bit more complicated, we might run into issues with correlated parameters. In such a case a change in one parameter can be more or less compensated by a change in another parameter. For example if DC1 and DC2 are very similar, an increase in a1 can be nearly compensated by an opposite change in a2. To identify correlations, we can calculate the correlation matrix from the covariance matrix. Values near 1 or -1 indicate strong correlation. To obtain a meaningful fit, only one of the correlated parameters should be used for fitting, while the others should be held constant and a reasonable value.

Exercise: See how the correlation changes. (1) using the default parameters, (2) making both TCs the same, (3) making TCs very long (e.g. 1 and 2). If the TCs are long compared to the sampled time, the curve is nearly linear and everything becomes correlated. THe situation improves for example if we know the offset and keep it fixed.

Steps to execute code:

  1. Open the project.
  2. Open the simple fit
  3. Study the code and the model. It is intentionally simple (no event structure, and other constructs)
  4. run it according to the instruction on the front panel
  5. Once you understand the code ...
  6. Open the Advance Fit
  7. Study the code and the model. Compare the additional code to increase functionality


Main Front Panel:


This is the advanced panel. The amplitude was excluded from fitting, thus the poor quality.

VI Snippet:

No snippet, just images. A snippet cannot duplicate the strictly typed connector pattern needed for the fitting routines.

Simple model


Advanced model


An image of the code that convert the covariance matrix to the formatted correlation matrix.


VI attached below

Main version is in LabVIEW 2010

(A LabVIEW 8.2 version is also attached).

April 27 2017

Welche Sensorarten gibt es. Damit sich ein Roboter in seiner Umgebung bewegen kann, ohne an Hindernisse anzustoßen,

Older posts are this way If this message doesn't go away, click anywhere on the page to continue loading posts.
Could not load more posts
Maybe Soup is currently being updated? I'll try again automatically in a few seconds...
Just a second, loading more posts...
You've reached the end.

Don't be the product, buy the product!