07-12-2012 07:50 PM
Hi,
I have been using HP8510c for Q factor calculation, the problem is, I require frequency values of all 801 S21 points I am getting the raw data for, to be able to get the loaded Q factor.
I use STIMULUS as 'RAMP' just for your information, which is also the default option.
I couldn't figure out this so what I thought of doing was, get the start and end frequency and interpolate it between 801 points.
Now I am using 'Ouput Active Function' vi which outputs the value of whatever function I have selected. So if I select Start and use this vi, It will output me the 'Start' frequency. But the problem is the I don't get the whole figure.
If on the screen it displays
START=4.46647456635 Ghz
It will output it as
4.46640000000 Ghz
It's not that the GPIB bus truncates any data, I feel the HP8510 firmware is configured to do that. Is that any other way by which we can get the exact frequency value?
The exactness is ideal for exact Q factor measurements.
Solved! Go to Solution.
07-13-2012 01:06 PM
New developments...
I think there is something which you people can help me out with...
So there is a command OUTPACTI; which gives us the exact value in ASCII format.
For some reason, the way the LabView.vi is designed, I don't know, it truncates the last digits.
So I used the 'Query' command in MAX and got this,
5.626466300000000E+08
but when I use my Labview module, which is attached, I only get this
5.6264
I tried attaching the output to a string indicator but still it shows this only!
I don't know why Labview is dealing with this differently.
07-13-2012 01:20 PM
Why don't you just display what you get from the VISA Read? What does that return?
07-13-2012 01:21 PM
LabVIEW does not deal with it differently. Your VI is not close to being correct since you wired the return count from the Write to the byte count input of the Read. There is absolutely no relationship between the number of bytes you write and the number of bytes the instrument is going to return. Set the byte count to some high number and see if it doesn't start to magically work.
07-13-2012 01:43 PM
Yeah, I understood that, and figured that something fishy was going on, so did that.
The funny part is, this was actually a part of the drivers for HP8510c
The reason why I am not using the VISA command is because I want to get it automated in Labview.
There is a big program and this is just a function which I need to use in it.
Now the last question, is there a way I could format the string
1.546345245245E+09 whatever into standard notation ?
like
154634524.5245, the way we use it.
It says the above one is ASCII format but I haven't found a vi or components which I could use to get that into this type of value.
07-13-2012 01:45 PM
In the manual, it says it is the ASCII format it gives back the value in but this is just a string which is in exponential format. Is there a convert for a string of this type in decimal?
I will try looking myself but if you guys already know the solution, kindly let me know
07-13-2012 01:50 PM
You are not being very clear. To change the display format of an indicator, you simply right click and select 'Display Format'. If you are need to format it in some other way, please explain.
07-13-2012 01:51 PM
Here is another problem....
I am getting the full resolution in the string, however the part E+09 etc gets eliminated.
All I did was increase the no. of bytes and attach a string indicator to the output, all the digits are there but the exponential format is not.
07-13-2012 02:01 PM - edited 07-13-2012 02:02 PM
And what number did you set for the byte count? A query with VISA in MAX is going to be the exact same thing as a query with VISA in LabVIEW.
07-13-2012 02:02 PM
Hi Dennis,
I am sorry for any confusion, let me just gather everything and put a clear picture.
OUTPACTI; returns us a string in exponential format which tells us the value.
I used 'Query' through MAX and got 1.73454xxxxE+10
I changed the no. of bytes in the Labview module and attached a String Indicator to the output.
What I want to do is convert this string into normal standard notation.
i.e. 173454xxxxx00
The problem is, when I receive the string in the String Indicator, it displays 1.73454xxx but does not add E+10. That is, it omits the exponential part.
So we lose the information that what this number stands in exponential format. So in fact the numeric indicator shows the same value as string as attached in the pic of the VI