07-09-2014 11:59 PM
I am using USB 6210 I/O and want to count the pulses in my digital signal generated by gear tooth sensor. I have integrated the whie loop within the case structure. Firstly case structure identifies the "1" value in digital signal and starts incrementing the local variable. The While loop I used is to increment once only when single pulse comes. if i remove the while loop then it increments the local variable continously till next zero comes(in a single pulse).
But even after having while loop within the case structure and changing the while loop stop condition to "stop if true", the program stuck in the while loop.
Can anybody tell me how to do this ?
07-10-2014 12:02 AM
Can you show us the code that you have developed. It must be a simple logic to count when you use the shift register.
07-10-2014 01:13 AM - edited 07-10-2014 01:13 AM
Check this VI.
I took 1000 sample n after that calculated for Each Signal "1"s. If Yes add +1 else No.
07-10-2014 01:52 AM
Hi,
Please find attached zip file, it should help you. its developed in LabVIEW 2010.
Miraz....
Kudos is better option to thank somebody on this forum.
07-10-2014 06:44 AM - edited 07-10-2014 06:44 AM
The Boolean Crossing PtByPt is perfect for this
07-10-2014 11:52 AM
@Indiano wrote:
I am using USB 6210 I/O and want to count the pulses in my digital signal generated by gear tooth sensor...
You should really just use one of the hardware counters for this.
Best Regards,
07-11-2014 03:36 AM
Hi,
Thanks. But i had applied some digital logic in my code and it is working for me nicely.
With Regards,
Indiano
07-11-2014 03:40 AM
You are right, but fortunetly i have applied some digital logic with shift registers.
Anyway, Thanks.
07-11-2014 08:56 AM
@Indiano wrote:
Thanks. But i had applied some digital logic in my code and it is working for me nicely.
If anyone in this thread helped you, feel free to give some kudos. It looks like several good developers came up with some helpful ideas and they deserve some thanks.
Unofficial Forum Rules and Guidelines
Get going with G! - LabVIEW Wiki.
17 Part Blog on Automotive CAN bus. - Hooovahh - LabVIEW Overlord
07-11-2014 11:02 AM
@Indiano wrote:
You are right, but fortunetly i have applied some digital logic with shift registers.
Anyway, Thanks.
Fair enough, but doing it this way will ultimately limit how fast of a signal you can measure (might not be an issue for you).
Best Regards,