Jump to content

Incremental encoder with UniLogic


Merle

Recommended Posts

Hello,

 

I've recently purchased a US5-B10-TA30  PLC+HMI.  I'm just getting started with UniLogic - created some ladder and played with the PLC a bit (yes very new).  What I now need to do is integrate an incremental encoder (IFM RVP510).  I understand that I can use the I10/I11 high speed inputs configured as quadrature inputs to track the A/B transitions.  However, when I configure the HS0 inputs, the tags that I see defined are for HS0.Counting_Direction and HS0.Counter_Reset.  Does that mean I just need to define the regular I10/I11 inputs as the A/B signals from the encoder?

Is there a predefined Counter in UniLogic that can be used for the signal counting/tracking?  Or do you have to define/build your own?

If there are any examples around that someone could point me towards that would be greatly appreciated.

Thanks.

Link to comment
Share on other sites

  • MVP 2023

This is not obvious.  I had to call support to ask where the HSC config switch was.

First off, HSO is high speed output.  That's not what you're looking for.

The properties of the on-board IO are cleverly hidden in the Uni-IO & Uni-COM item of the hardware tree.

Selecting

image.png.5038196406bda34729610add37d54c4e.png

Gives the Properties window

image.png.5482d8e726b5fe9f235f36c47f6736cf.png

 

Now you can define the HS Inputs.  If you choose Quadrature the additional IO tags are added

image.png.ff3214387489747bf16999c5e6723771.png

 

HSC-0 Counter Value being one of them.

 

Joe T.

 

Link to comment
Share on other sites

Sorry, I think a typo in my post may have mislead you.  I was using HS0(zero), not HSO(output).  I forgot the 'C' which made it confusing.  It should have been HSC-0 and not HS0 like I typed.

I did manage to find and configure everything you outline above.  Where I got confused is when I tried to add an IO to a Direct Contact, I was only seeing the HSC-0 reset and counter direction IO.  This makes sense now since they are the only BITS added so the only parameters that can be assign to a contact.  And when I went to the IO list, I wasn't seeing the HSC-0 Counter Value and Status parameters until I sorted the IO by Name.  I'm not sure why those two parameters were separated.  It must have been sorted by type or something. 

So thanks for that!

Are there any tutorials or documents on using the HSC parameters in ladder?  Specifically for integrating an encoder?  I sort of know in theory how this should be done, but not in practice.

Thanks again.

Link to comment
Share on other sites

After defining PLC model, click on "Uni-I/O & Uni-COM" in "Solution Explorer":

image.png

In "Properties Window->HS Input 0" click on 3 dots at right side:

image.png"

Configuration window pop-ups:

image.png

Click on "Interface" and select "Quadrature (A/B)":

image.png

Choise required parameters, load project to PLC, connect encoder and test.

In "On board I/O" you can find required tags:

image.png

Enjoy!

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...