Sign in to follow this  
Followers 0
ElecPneuGuy

Linear Transducer Position

3 posts in this topic

Ok, I'm having a brain block here. How can I tell if the position of a linear transducer is increasing or decreasing? I'm using 5000 software. I've been trying to take the position, move it into a buffer, then compare the position with the buffer (GRT or LES), to see if the position is moving left or right. Yet, as the analog signal bounces around , my bits will set/reset which gives me a false indication of movement even at rest.

Share this post


Link to post
Share on other sites
I use the same "last value" comparison method to determine changing values for watchdog purposes, but when the value is from an analog card or is a Floating Point value the small changes "at rest" require some changes to the approach. Try sampling the position value at a definite time period instead of every scan, and using that to compute the speed at which it is moving. Displacement / Time = Velocity Then you can use a positive or negative velocity threshold to determine direction using the same GRT and LES instructions. The Periodic Task or Event Task with an analog input module real-time-sample trigger would be a good way to do this.

Share this post


Link to post
Share on other sites
Yes, I thought about using the Velocity, as my transducer is a dual output unit. (Position & Velocity -- both analog 4-20mA) Before I tried messing with that, I was figuring that I'd have the same problem as the velocity bounces around in those small floating increments. But.....thinking about it now, I do like the idea of a threshold to say that there is a velocity (movement), then I could determine the increasing or decreasing position.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0