07-26-2025 07:29 AM
Hello, I spent hours browsing QA and examples but could not find answer. I prepare VI to measure voltage signal from two AI channels by NI USB 6210 card. Signals shoud be scaled to viscosity and temperature units then (I have choosen a Map Ranges mode) and finally the scaled signal is to be used in further calculations. All that I want to do programmatically to be able to easy control parameters. I do not have USB-6210 at site so I work on simulated signals. I used Voltage - Continuous Input.vi downoloaded fronm NI website as template, then after modifications I connected a DAQmx Create Scale.vi using instructions from https://knowledge.ni.com/KnowledgeArticleDetails?id=kA03q000000YILFCA4&l=pl-PL. All seems Ok, but when I run my vi, it seems that neither Waveform chart nor Viscosity and Temperature indicators read scaled signals. they only present pre-scaled voltage signals. For my further processing I need to have scaled signals. Surprisingly, when I checked recorded TDMS file it contains informationabout scaled signals (channel name, units) but the values are not scaled neither. I noticed, that some user ad property node DAQmx channel to indicate Custom scale name, I tried but it changed nothing. In some discussions I found that the custom scale and/or nie channel DAQs are in a for loop, but I do not understand why.
May I ask to check my VI for errors and guide me how to have my VI working? I upload my VI and screenshot with my front panel settings and a recorded TDMS file too.
Solved! Go to Solution.
07-26-2025 12:02 PM
You are running LabVIEW 2025, so your code (Viscosity test.vi) can only be examined by those of us who have installed LabVIEW 2025 on their computers (and probably >75% of them are students just learning LabVIEW).
To reach we "old timers" who have been using LabVIEW for years, and probably have at least LabVIEW 2019 or LabVIEW 2021 installed, cannot open your code. Please open it yourself, go to the File menu, and "Save for Previous Version", specifying LabVIEW 2019 or 2021, and we'll take a look. I, for one, have successfully used a Custom Scale to get the output of a tri-axial accelerometer chip (which outputs from 0 to 5 V, as I recall) to give me the output in units of "g" (Earth gravity). Show me your code, I'll show you mine ...
Bob Schor
07-26-2025 03:43 PM
Many thanks for your advise and interesting in my topic. I upload my code in two versions 2019 and 2017, just in case. if other versions would be required just let me know.
07-28-2025 12:53 AM
Hi Pikey,
@Pikey wrote:
All that I want to do programmatically to be able to easy control parameters. I do not have USB-6210 at site so I work on simulated signals.
Did you test your VI with real DAQ hardware?
Simulated devices are just simulated - with several limitations. Apparently applying custom scales is on their list of short-comings!
Next time please set reasonable values as default in all the controls of your VI. I had to change several of them (including the channels) to be able to run your VI…
07-28-2025 03:53 PM
I just tested it on a connected device, and everything seems to be working. I'll double-check, but it seems to be working. Thank you very much. I wasted three days of work searching for an error that wasn't there. And since you brought up the topic, could you tell me how to save default values in controllers? It's also annoying that I have to reset them every time, but I don't know how to save these values as defaults. Thank you very much for helping me solve the main problem.
07-29-2025 01:35 AM
Hi Pikey,
@Pikey wrote:
And since you brought up the topic, could you tell me how to save default values in controllers?
07-30-2025 04:12 PM
Thank you one more time, it is easy to find once you know where. Best regards, Pikey