04-24-2012 12:48 AM
Hey everyone,
Coming up on the due date for a project through my university. Making some final tweaks to the Vi we've developed and adding additional features...
The idea:
As of right now, part of our Vi displays a temperature reading from a sensing node. As it stands, it currently reads the temperature in degrees Celsius and plots the data on a waveform. We'd like to implement the feature to have a button to press that would convert the output to Fahrenheit...
I'm thinking of using a Boolean button that will be the input to the selector of a case structure. One case (True) will perform the conversion from C to F. The other case (False) will do nothing and leave the data as is in Celsius. Pretty simple concept...
Part I'm stumped on:
As I mentioned, we're also plotting this data on a chart in addition to displaying the numerical reading. If we implement this button, it would also have to modify our waveform chart to appropriately display the data. Our current waveform ranges from 0 degrees to 60 degrees Celsius. Converting to Fahrenheit would more than likely put the value out of this range...
Is there a way to make the waveform axes change according to the button press as well?
I was also thinking of possibly having two graphs - both stacked on top of one another. Once the button was pressed, the Celsius graph would become hidden, exposing the freighting graph located behind it. Not sure how to add this feature though...
I wrote this up fairly quick and I'm rather sleep deprived from cramming for the end of the semester crunch here. I'll check back tomorrow morning if I need to clarify anything.
Any advice or ideas are greatly appreciated!
Thanks in advance!
Solved! Go to Solution.
04-24-2012 01:43 AM
Hmm, well check this attaced pic - it's kinda gonna help maybe.
Regards!
04-24-2012 05:28 AM
Ah, and a "false" case:
04-24-2012 07:05 PM
Hi there,
The above poster has got it exactly -- you need to use the property node for the Waveform Chart (the property node is what is inside the case structure). To get a property node, right click the Waveform Chart block andselect Create > Property Node > Y Scale > Range > Minimum. (Do the same for Maximum.)
Best,
04-25-2012 01:31 AM
Thanks for the replies guys!
Jungleboy, i did something similar.
Ryan, thanks for the explanation, probably would've had a hard time finding the necessary tools without it!
Really appreciate it guys.
04-25-2012 03:06 AM
Hi all,
instead of constantly switching the Y scale limits and to do some math on the waveform itself I would suggest to simply change the Y scale multiplier/offset to adapt for degC and degF. That way LabVIEW will handle all those code inside the chart itself!