Author Topic: Rencoder encoder RHS21D P1  (Read 20630 times)

artkraft

  • Newbie
  • Posts: 22
  • I'm a llama!
    • View Profile
Rencoder encoder RHS21D P1
« on: June 01, 2014, 09:47:50 AM »
This is a dual channel encoder. Question is .
Do I connect
Phase #1 = T100md input #3
Phase #2 =Input #4
Phase #1 not= #5
Phase #2 not =#6
If not what would be the correct connections?

support

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 3174
    • View Profile
    • Internet Programmable PLCs
Re:Rencoder encoder RHS21D P1
« Reply #1 on: June 01, 2014, 06:42:41 PM »
Do you mean the single encoder has two channels of ouputs? Does it handle more than one shaft and therefore each shaft has one output channel?

Usually each encoder will have two outputs which are 90 degree out of phase. Such encoder can be connected to input #3 & #4 (which form a single channel).  A second encoder will be connected to inputs #5 & #6 which forms a second channel.


Email: support@triplc.com
Tel: 1-877-TRI-PLCS

artkraft

  • Newbie
  • Posts: 22
  • I'm a llama!
    • View Profile
Re:Rencoder encoder RHS21D P1
« Reply #2 on: June 02, 2014, 05:30:21 AM »
single encoder dual channel output
A
A not
B
B not

artkraft

  • Newbie
  • Posts: 22
  • I'm a llama!
    • View Profile
Re:Rencoder encoder RHS21D P1
« Reply #3 on: June 02, 2014, 05:48:18 AM »
try again

support

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 3174
    • View Profile
    • Internet Programmable PLCs
Re:Rencoder encoder RHS21D P1
« Reply #4 on: June 02, 2014, 11:10:08 AM »
You can try to connect /A and /B to 0V of the PLC's power supply.

Then connect A to input #3, B to input #4 and define HSCDEF 1, xx,yy

Rotate the shaft and see if the HSCPV[1] increment and decrement (when rotate in opposite direction).
Email: support@triplc.com
Tel: 1-877-TRI-PLCS

garysdickinson

  • Hero Member
  • Posts: 502
  • Old PLC Coder
    • View Profile
Re:Rencoder encoder RHS21D P1
« Reply #5 on: June 02, 2014, 08:07:45 PM »
I would be very careful about connecting the Renco rotary encoder directly to the PLC inputs.  The best I can figure out is that the encoder outputs are either:

1.  TTL compatable. Actually open collector with a pullup.  0..5 volts.  "VC" version.  The A and /A outputs are complimentary.  You would use one or the other.  You would not connect these outputs to ground 0V.
2.  Differential.  Same spec as modern RS-485 transceiver.  "LD" version.  The A and /A outputs are the differential pair for the A timing signal. You would use both signals.

If you have the TTL version you will need to convert the TTL outputs to 0..24VDC.  ULN2003 is a good option.  There are examples in the TriLog manuals on how to do this.

If you have the differential output version you'll need a differential receiver and then level convert this to 0..24V via a uln2003.

However, if you have connected the encoder to the PLC inputs directly, you may have not need to worry about debugging the PLC firmware.  The inputs on the PLC have a pull up resistor to 24V and this voltage could damage the encoder's outputs. In this case you may need a new encoder.

This is a link to a related Renco encoder.  This is about all I could find in the way of documentation.  Renco is out of business and this encoder hasn't been made for a number of years.

http://www.renco.com/fileadmin/files/Productinfo/00546600.pdf

Good luck,

Gary d
« Last Edit: June 02, 2014, 08:16:25 PM by garysdickinson »

artkraft

  • Newbie
  • Posts: 22
  • I'm a llama!
    • View Profile
Re:Rencoder encoder RHS21D P1
« Reply #6 on: June 03, 2014, 04:04:58 PM »
I'm connecting to the plc through an opto 22 Quad. It is converting the 5v from the encoder to 24v for the plc. I need increment and de increment counting for a stepper motor. All 4 leads will trigger the opto. Now the question is if I can only use 2 of them which 2.

garysdickinson

  • Hero Member
  • Posts: 502
  • Old PLC Coder
    • View Profile
Re:Rencoder encoder RHS21D P1
« Reply #7 on: June 03, 2014, 04:35:28 PM »
Good work on the interfacing.

Since you are interested in shaft position, the the CH A and CH B inputs are all you need.  

The CH A- and CH B- outputs provide the same information, but these outputs are logically inverted from the A and B pair.

The electrical interface that was shown on the Renco documents included a low pass filter.  I'm guessing this was done to ensure that any very short glitches on the encoder outputs are not "seen".  

If you run into problems with the PLC getting out of sync with the physical hardware, glitches are a possible cause.  The PLC's inputs, when used for quadrature decoding can and will respond to impossibly short transitions on the input pins.

The encoder also generates a output called INDEX.  This signal goes active once per revolution.  This is a useful signal to verify that neither your steper nor the PLC's counters have gotten out of sync.

Gary d.






artkraft

  • Newbie
  • Posts: 22
  • I'm a llama!
    • View Profile
Re:Rencoder encoder RHS21D P1
« Reply #8 on: June 03, 2014, 08:54:23 PM »
Thanks Gary.  The index could become important as I was concerned about losing steps . If I sync the index when I set up the cutters and set that as home I can reset the counter every cycle using the index. Then I can create a watch dog using a timer and if I don't reach the preset counts in a given time (say 400 Ms) it returns to the index. I was wondering how I would do that.

artkraft

  • Newbie
  • Posts: 22
  • I'm a llama!
    • View Profile
Re:Rencoder encoder RHS21D P1
« Reply #9 on: June 05, 2014, 08:24:02 PM »
I'm using a "western reserve control 1781 OB5Q" It will activate a coil on a solenoid but will not trigger the  "HSC input" or any input on the plc. is it the wrong type. Won't drop to 0v. PNP vs NPN
 
http://www.wrcakron.com/16_quad_dc_output.html
I have a ULN2003a to use instead.

garysdickinson

  • Hero Member
  • Posts: 502
  • Old PLC Coder
    • View Profile
Re:Rencoder encoder RHS21D P1
« Reply #10 on: June 05, 2014, 11:54:11 PM »
I assume that you are NOT using the 1781 to interface the Renco encoder to the PLC.  I assume that you are interfacing some other device to the PLC.

The 1781 appears to be a simple optical coupler that uses an LED coupled to a photo-transistor.

As far as you NPN vs PNP question, the outputs of the 1781 are documented as NPN type, however the outputs are wired so that when they are "ON" they will pull the output up to the DC+ (+24V) level and source current into the load.  This is NOT what the PLC inputs expect.  This is NOT what is typically (in the land of PLCs) what is meant by "NPN".

If your "relay" is connected between one of the 1781 OUTPUTS and GND (0v) and works, then this demonstrates that the OUTPUTS of the 1781 are sourcing current into the load (relay).  in this case the 1781 documentation is correct.  If this is the case, then the 1781 will NOT work with the PLC INPUTs without modification.

It may be possible to get the 1781 to work with the PLC, but this will require you to add a pull down resistor from the the PLC INPUT to GND to turn the PLC INPUT "ON".  The 1781 will then be able to turn the PLC INPUT "OFF" by sourcing current into the PLC input and the newly added pull down resistor.  This will invert the sense of the PLC INPUT and you will need to take this into consideration when programming the PLC.

I'm not certain of what the correct value of a pull down resistor should be, but I'd guess about 470 Ohms would be a good start.  But this will result in about 1.25 Watts of power dissipated in this pull down resistor in a 24V system.  I'd suggest that you purchase resistors that are rated for 3 to 5 Watts to ensure that they don't become a source of flames.  If you do the pull down stunt make certain that nothing that can melt or catch fire is near the resistors, be certain that your power supply can support the 1.25W per pull down and that you have adequate cooling.

The ULN2003 might get the job done with a bit less drama.

Do you need the optical isolation provided by the 1781?
What are you actually trying to connect to the PLC?

Gary D.

This is the schematic for the 1781 0B5Q module to illustrate the unusual wiring of the output transistors.
« Last Edit: June 06, 2014, 01:17:30 AM by garysdickinson »

artkraft

  • Newbie
  • Posts: 22
  • I'm a llama!
    • View Profile
Re:Rencoder encoder RHS21D P1
« Reply #11 on: June 11, 2014, 09:42:19 AM »
The 1781 definitely will not work. Moving on to the ULN2003.
Thanks for all the help