07-17-2019 01:07 AM
Hi,
i am facing an issue while logging data to measurement file/tdms.
i am sending a pattern of data from fpga hardware(fpga-ft232h-labview). i am getting same pattern but its is shifting.
as after every frame(512bytes) labview adding 2-4 bytes.
please suggest how to avoid this case/issue.
please see the snapshot attached. suggest me where i have to make correction.
07-17-2019 01:22 AM
Hi saikiran,
please see the snapshot attached. suggest me where i have to make correction.
As you only show some images we cannot suggest how to prevent that problem.
It seems the "unwanted" data is already in the string you get from VISARead: check the data at the data source!
i am sending a pattern of data from fpga hardware(fpga-ft232h-labview).
Maybe the problem is here: are you sure your "fpga hardware" is really sending just the data you expect?
07-17-2019 01:54 AM
yes.
fpga part i have verified using logic analyzer. its sending correct data only.
<<It seems the "unwanted" data is already in the string you get from VISARead: check the data at the data source!>>
data in string !?! as my last bytes are 0's but its giving highest value "118" of my pattern data after every 512.
can we refresh string after every 512 ? so i can get only sent data.
is there any alternative ?
07-17-2019 02:13 AM
Hi saikiran,
data in string !?!
Yes, in the string you get from VISARead:
as my last bytes are 0's but its giving highest value "118" of my pattern data after every 512.
Do you get any errors or warnings from VISARead? That would explain why you get "0's" as last bytes…
07-17-2019 02:37 AM
please see pattern .. according to that i will get "0" as my last byte not 118.
can we refresh/reset string ? .
iam not getting any errors nor warnings.
07-17-2019 02:53 AM
Hi saikiran,
please see pattern .. according to that i will get "0" as my last byte not 118.
To plot this "0" in your chart it has to be part of the string data you receive from VISARead. The chart does not "magically" add zeros to your plots: they come from your data source!
So you need to examine where that zero is coming from - this process is called "debugging"…
Again: which data do you receive? Does that string already contain those zeros? Did you even try to debug your VI?
can we refresh/reset string ? .
The string is refreshed with every VISARead call - THINK DATAFLOW!
iam not getting any errors nor warnings.
I didn't ask for the error list of your VI in edit mode.
I asked for the errors in the error wire coming out of VISARead: you need to implement some error handling in your code to even recognize errors/warnings from VISARead! (This also is part of good coding style and debugging!)