Ladder logic of Mitsubishi FX-64MR

NathanS

Member
Join Date
Oct 2019
Location
Worthing
Posts
2
[FONT=Arial, Helvetica, sans-serif][SIZE=-1]Hi guys,[/SIZE][/FONT]
[FONT=Arial, Helvetica, sans-serif][SIZE=-1]
[/SIZE][/FONT]
[FONT=Arial, Helvetica, sans-serif][SIZE=-1]Was wondering if someone could help me with some ladder logic on a Mitsubishi FX-64MR which we are using for running air compressors.[/SIZE][/FONT]
[FONT=Arial, Helvetica, sans-serif][SIZE=-1]
[/SIZE][/FONT]
[FONT=Arial, Helvetica, sans-serif][SIZE=-1]The ladder logic is:[/SIZE][/FONT]
[FONT=Arial, Helvetica, sans-serif][SIZE=-1]
[/SIZE][/FONT]
[FONT=Arial, Helvetica, sans-serif][SIZE=-1] M0
[/SIZE][/FONT]
[FONT=Arial, Helvetica, sans-serif][SIZE=-1]--| | --------------------[PLS M2][/SIZE][/FONT]
[FONT=Arial, Helvetica, sans-serif][SIZE=-1]
[/SIZE][/FONT]
[FONT=Arial, Helvetica, sans-serif][SIZE=-1] M2 T0
[/SIZE][/FONT]
[FONT=Arial, Helvetica, sans-serif][SIZE=-1]--| |-----|-----|/|----|---------------(Y10)[/SIZE][/FONT]
[FONT=Arial, Helvetica, sans-serif][SIZE=-1]--| |-----| |------|/|------(T0 K5)
[/SIZE][/FONT]
[FONT=Arial, Helvetica, sans-serif][SIZE=-1] Y10 M2
[/SIZE][/FONT]

[FONT=Arial, Helvetica, sans-serif][SIZE=-1]Apologies for the formatting above, hope it reads OK.

From what I've learnt, the T0 in this PLC is a non-retentive timer and will go to 1 when the timer is elapsed, and from the manual, K5 is 5 * 100ms so will go to 1 after 0.5s.

The problem I am having is the output coil Y10 never goes to 1 and I can't see what is wrong with the above? M0 is 1, and when taken to 0 and back to 1 still doesn't change Y10.

Do I need to change the K5 to something longer, is the previous application for a compressor which once is on, it stays on until it is told to turn off? The new air compressors aren't as such..

Hope someone can help, and thanks in advanced!

Kind regards,

Nathan
[/SIZE][/FONT]
 
Last edited:
From what I first see, M2 is a OneShot bit that flashes for one scan when MO goes 1.

That would let Y10 go on for 1 scan, which isn't long enough to see while monitoring, and not long enough to actuate a relay or solenoid coil. Also, M2 only flashes TO as it is.

You would have to have M2 hold another Mx bit until T0 times out. Then have the held bit put in place of M2 on the 2 rungs.
 
Thank you very much for your quick reply, really appreciate it!

I’m struggling to see what the difference is with your logic, would that still not turn T0 to 1 and shut off the output to Y10?

My next step was going to increase K from 5 to say 50 and see if the compressor comes on for 5s?
 
In mine M2 (the OneShot) turns on M3.

Then M3 holds itself on until T0 times out, and the next rung M3 holds T0 on until it times out.

The [PLS M2] is a pulse that is only 1 for that scan, so after that scan it no longer holds Y10 or T0 on.

EDIT: Then M0 has to drop to 0 before M2 can be trigger again to run the output for a T0 time again.
 
Assuming the logic is to turn on an output for 500ms then it seems a bit long winded, it could be simplified. When M0 turns on then it pulses M1, this then turns on Y0 and starts Timer 0, The logic is latched by Y0 and resets when timer 0 turns on at end of time value to reset the latch. M0 if left on will not trigger the output or timer again until M0 has gone to false and back to true

FX.png
 
parky,


That is one less bit and rung, but I am in the habit of performing all logic with bits - then using a bit to control the output.



This also is more reliable if a HMI is attached - reading a bit instead of the output directly. Almost every PLC I program has a HMI or SCADA system, so I try to standardize my programs.
 
Nathan, The logic you posted seems like it is not actual logic but you typing it in using standard ASCII chars this is a bad idea, just do a screen shot capture (FN + PRTSCN) then paste it into paint copy the logic & paste it into a new paint doc then upload it. According to your logic it would not work as there is no latch on the output to hold it on for the time period so would only be on for one scan. Aabeck I understand your logic & if using an HMI or Scada somewhat agree it also helps keep coms down as if all tags read/written are in one area. I also tend to keep outputs in one block & use internal bits to drive the outputs, this makes sense as if these are say at the end it makes it easy to debug, by looking at why an output is not on you can see the internal bits that drive it in one segment & work back to the bit you expect to be driving it. I hate code that uses multiple latch/unlatch of outputs throughout the program it can cause all sorts of problems debugging it.
 
parky,

I fully agree with you on avoiding latch/unlatch for operations. The only thing I use them for is to enable options in a program that won't change when powered down.

Getting into some programs to troubleshoot a machine that is written with all latch/unlatch can be a nightmare - especially when one certain condition wasn't thought of that needed to unlatch and reset the operation.
 
Tell me about it, I was called in to support an engineer from Italy on a strapping machine, the company wanted some extra features that were not standard, the engineer from Italy was the original programmer, however I noticed that the code latched outputs on/off all over the program many times, he tried to add the modifications & the machine started to do a dance. 5 days in and it seemed to work with the mods, however I was dubious. It went to the customer & a few days later I was asked to go and support another Italian engineer as the machine was not working properly. The dam thing was still doing it's own thing occasionally. Both the engineer from Italy & myself after a frustrating 2 days decided to re-write it bit by bit but every time we tried to it caused all sorts of problems. I do not blame the second engineer he was as frustrated as me. In the end the machine was taken out of production & the supplier asked me to re-write it and get it right or they would be in financial trouble due to the customer claiming lost income. I re-wrote it working fine. It turned out that other machines in other companies were suffering with similar problems so got the contract to re-write them as well.
 

Similar Topics

Hi everyone, I am a greenhorn in programming. Can anyone help me with a GX Works ladder logic example of programming a real time clock. I want to...
Replies
3
Views
4,010
I got my PanelView Plus 7 working with a Micrologix 1500. How would I connect my laptop to the PanelView to view the ladder logic while operating...
Replies
6
Views
137
Hello, I am trying to replicate a piece of logic on the PLC5 onto an SEL RTAC. I am using ladder on SEL and FBD. I am having issue on the ladder...
Replies
13
Views
232
I have a machine which is undergoing upgradation. As part of the process two SEW drives are being replaced., existing Gen B with new Gen C. The...
Replies
3
Views
202
Good morning crew! Ok my logic works but I am missing something. When the start button is pushed it should like the red light for 4sec then shut...
Replies
13
Views
423
Back
Top Bottom