help wanted encoder plc !!!!

ALIMARY15

Member
Join Date
Jul 2011
Location
italy
Posts
75
good morning,
i am using a dl05 plc to read from a linear encoder. I am trying to debug my software but it wont work! can anyone help?

I am using the PLC in dl05 mode with HSIO quadrature mode as in the datasheet i have connected the A and B signals from the encoder to the Inputs X0 and X1. as soon the encoder goes, the plc shows the signals X0 and X1 as the leds in the panel turns on!

i wrote my software in the plc using a UDC CT76 Counter but the counter seems not to count and not increment into my software! anyone has any idea of why this happening?

I attach here two pics 1 and 2 with my ladder code i am usign to check if the counter working!
can anyone please help me? thanks

1.png 2.png
 
help please

good morning,
i am using a dl05 plc to read from a linear encoder. I am trying to debug my software but it wont work! can anyone help?

I am using the PLC in dl05 mode with HSIO quadrature mode as in the datasheet i have connected the A and B signals from the encoder to the Inputs X0 and X1. as soon the encoder goes, the plc shows the signals X0 and X1 as the leds in the panel turns on!

i wrote my software in the plc using a UDC CT76 Counter but the counter seems not to count and not increment into my software! anyone has any idea of why this happening?

I attach here two pics 1 and 2 with my ladder code i am usign to check if the counter working!
can anyone please help me? thanks

I checked the inputs and its like the plc not reading them! My inputs are from an encoder signal and they are of 12 V signals .( I used a uln2803 integrate with a 600 ohm pullup resistor for making the 5 V signal be adapted to 12 V ).The current its of 5 ma.

Anyone has any idea? when the encoder moves , the input status indicators of the plc start blinking but they are in red color, is this their default color? or should they blink in green?

thank you
 
Alimary15, I dont see your XO and X! inputs in your screen shot looks like C1 will always be true and your counter is not going to wrok . can you post your actual ladder?
 
Alimary15, I dont see your XO and X! inputs in your screen shot looks like C1 will always be true and your counter is not going to wrok . can you post your actual ladder?

this is my actual ladder. i show u the manual of the plc i just did as an example reported on it ! here it saying that when u using the mode 20 for quadrature encoder when C1 is enabled the counter increments every X0 and X1 pulses. In the manual it doesn't seem to use X0 and X1 in the ladder. check this attached.


thank you

Schermata 2011-10-07 a 12.16.10.png
 
Have you tried using co as the enable? and c1 as the cnt input and c2 as the reset?
and setting C0 in rung 1?
 
why did you use set C1 in your first rung instead of C0? if you do it exactaly as the example shows does it work?
 
why did you use set C1 in your first rung instead of C0? if you do it exactaly as the example shows does it work?

I changed as you told me and used the variables as in the example but it doesnt work the same. Its like the counter doesn't recognize the inputs even if the led input indicators are on!

I am wondering? could it be the quadrature signals too fast for the plc? but i dont think this is the problem because in the manual its written we can read up to 5 khz .

any idea?
 
can you post your actual program save it to a file and zip it then post it?

ok here it comes! i have made two trials i send you them both this my basic ladder code where i am trying to increment the counter at the signals x0 and x1 from the encoder.
Let me know, thanks a lot
 
I will have to look later but why is your program not like the example? why are you loading the setup every scan? For now try documenting your rungs and give nicknames to your bits it will help you and others to understand how the ladder is working and is good practice in programing I really hate to see undocumented ladder!
 
I will have to look later but why is your program not like the example? why are you loading the setup every scan? For now try documenting your rungs and give nicknames to your bits it will help you and others to understand how the ladder is working and is good practice in programing I really hate to see undocumented ladder!

Im sorry for not commenting the program i will surely do from nw on!i tried to upload the code also uysing the sp0 first scan but effect was the same!
This little code of software i am using it to check if the couinter really reading the encoder and actually its not . I hope u can help me i feel very stuck right now i dont know what can cause this,becasue all the settings of the plc are right .let me knw if u got any consideration on my software,
Thank you so much

Maria
 
I have a question. Why are you using a timed intrupt?

Once the interrupt period is set and the interrupt is enabled in the program, the CPU will continuously call the interrupt routine based on the time setting in V7647. Most of my high speed operation has been with the ctrio card. I would start by setting up program as written first, test it out then start modifing. Next I would check the input, just because the leds are turning on and off does not mean the plc is seeing it.



Tom
 
Have you addressed the possible reasons for not counting as detailed in the manual? Also, make sure the PLC is in RUN.

Symptom: The counter does not count.
Possible causes:
1. Field sensor and wiring – Verify that the encoder or other field device inputs actually turn on and illuminates the status LEDs for X0 and X1. A standard incremental encoder will visibly, alternately turn on the LEDs for X0 and X1 when rotating slowly (1 RPM). Or, the problem could be due to a sinking-sourcing wiring problem, etc. Remember to check the signal ground connection. Also verify that the pulse on-time, duty cycle, voltage level, and frequency are within the input specifications.
2. Configuration – make sure all of the configuration parameters are correct. V7633 must be set to 20, and V7634 must be set to “0002” to enable the Phase A input, and V7635 must be set to “0000” to enable the Phase B input.
3. Stuck in reset – check the input status of the reset input, X2. If X2 is on, the counter will not count because it is being held in reset.
4. Ladder program – make sure you are using counter CT76 in your program. The top input is the enable signal for the counter. It must be on before the counter will count. The middle input is the dummy input and must be off for the counter to count. The bottom input is the counter reset, and must be off during counting.
 
Last edited:

Similar Topics

Hello, I'm struggling with getting an email to send using an eweb module on a controllogix system. Any chance I could get someone here to help?
Replies
4
Views
1,875
Attention all PLCs.net members!! As Covid-19 has put many of us factory automation folks out of work, let’s work together to help get as many of...
Replies
18
Views
19,614
Good Morning , I had a short meeting with our human resource manager yesterday and realized that the maintenance technician ad's were...
Replies
3
Views
1,575
Not sure if it's OK to post this type of thing, but we have pretty decent jobs available in the West Michigan, Lake Shore area around Grand Haven...
Replies
27
Views
5,627
Every once in a while we get the question "what automation platform should I learn to get the best chance at getting a job". I tell people to...
Replies
6
Views
2,994
Back
Top Bottom