03-15-2018
04:26 AM
- last edited on
03-14-2019
02:18 PM
by
NIadmin
Hello,
I would like to use the dashboard builder for displaying information of my cRIOs but I am still not completely sure on how to proceed.
I looked at the manual for systemlink and I also asked for examples and I was provided an example from JoshuaP on this post forum post. But the example would not run so I still feel I need a little more guidance.
My goal is to have a LED change between 3 colors say red, yellow or green depending on a variable which I get from a tag.
The variable would be the status of the application (ex: running, pause, charging, failure, etc)
and depending on the status, a different color would be displayed on the Led.
So my main question is, how do I implement logic on the dashboard?
something like this:
if (tag1 <=2): LED1 = green else if (tag1 ==3) LED1 = yellow else LED1 = red
Solved! Go to Solution.
03-21-2018 07:04 AM
Hi,
Thank you for posting this question. I would like to check up on this post since no one in the community has gotten back to you yet.
Do you still have this problem? I have looked for documentation on how to achieve this functionality, but I have not found anything yet. Maybe you could reach out to Joshua P to see if he can provide any pointers?
Best regards,
Sara N H
Applications Engineer
National Instruments
03-21-2018 07:39 AM
You can bind input and output attributes to tags. There is an attribute for the color of an LED when it is turned on that you can bind to a tag. To me, the simplest way to achieve the effect you desire would be to read from the tag that you want determining the color of the LED in LabVIEW, and then based on its value, write to a separate string tag that would be bound to the LED's 'On Color' attribute.
When writing to that attribute, it expects a string with the format of "rgb(X, Y, Z)" where X, Y, and Z are positive values from 0 to 255.
03-23-2018 07:37 AM
Hi,
I have a database and I need to visualise a few data in the Dashboard. Will there be APIs to query data from database and show it in dashboard in the upcoming versions?
Thanks,
Nikitha
03-23-2018 09:08 AM
Instead of having SystemLink query your database for data, instead you should use LabVIEW or some other programming language to get the data from the database and then post that data to tags. If you are using a language that is not LabVIEW, you can use the Skyline Web Service API to send that data to your SystemLink server. The documentation for that API is in the link I included above.