06-13-2022 06:18 AM
@pincpanter wrote:
When you set a term char, the VISA Read outputs a timeout error if this char is not there.
As I already suggested, require a large number of characters (e.g. 1000), then check for the error output. If there is no error, you are sure that the term char is there.
I got it..! Thanks for your answer - this works now with the termination char outside the loop.
06-13-2022 06:22 AM
now for 5Hz I get following timestamps:
so the solution are a few points:
- the most impact was the FTDI converter which was set to 16ms. Now I changed it to 1ms. Thanks to @MichaelS78
- use a termination char outside the timestamp loop
- reading more than expected chars and check the error state for the trigger
Those points together gave me the right solution I was looking for. Thanks to all your replies..!!
06-13-2022 07:45 AM
@Norick17 wrote:
@pincpanter wrote:
When you set a term char, the VISA Read outputs a timeout error if this char is not there.
As I already suggested, require a large number of characters (e.g. 1000), then check for the error output. If there is no error, you are sure that the term char is there.
I got it..! Thanks for your answer - this works now with the termination char outside the loop.
Could we see the new vi (or at least a picture) because what you described doesn't seem to match what was suggested.
06-13-2022 09:34 AM
@billko wrote:
@Norick17 wrote:
@pincpanter wrote:
When you set a term char, the VISA Read outputs a timeout error if this char is not there.
As I already suggested, require a large number of characters (e.g. 1000), then check for the error output. If there is no error, you are sure that the term char is there.
I got it..! Thanks for your answer - this works now with the termination char outside the loop.
Could we see the new vi (or at least a picture) because what you described doesn't seem to match what was suggested.
Here is my last updated vi:
06-13-2022 08:52 PM
@Norick17 wrote:
@billko wrote:
@Norick17 wrote:
@pincpanter wrote:
When you set a term char, the VISA Read outputs a timeout error if this char is not there.
As I already suggested, require a large number of characters (e.g. 1000), then check for the error output. If there is no error, you are sure that the term char is there.
I got it..! Thanks for your answer - this works now with the termination char outside the loop.
Could we see the new vi (or at least a picture) because what you described doesn't seem to match what was suggested.
Here is my last updated vi:
Yeah, thumbs up. That should work - at least the comms part of it. 🙂
06-14-2022 01:35 AM
For anyone else looking at this code: to be precise, the first delta t is garbage and will not be considered in the subsequent calculations (that we don't see).