03-07-2023 10:57 AM
Hello,
I cannot seem to figure out a way to keep my signal in a range of 0-359°. I am using an encoder to gather angle. My VI works great at 0-359°. once it goes great than or equal to 360° or - degrees, my VI no longer knows what to do with the signal. I am looking for a way if the angle is greater than 359°, subtract 360° (360°=0°, 720°=0°, 410°=50°, 1230°=150°, etc). I do not need to keep tract of #rotations.
Thank you for any and all help.
03-07-2023 10:58 AM
03-07-2023 11:12 AM - edited 03-07-2023 11:21 AM
For the description, it seems your angle is an integer. If it is floating point, you would also need to consider e.g. an angle of 359.999, for example.
Yes, in both cases quotient&remainder would work fine. (For example an angle of -5 would turn into 355, 400 would turn into 40, and 360 would turn into 0)
03-07-2023 01:29 PM
Thanks! This worked great! so much to learn on LabVIEW!