Jump to content

Recommended Posts

Posted

Hello , I dont have much experience in PLC coding but need to remove an old Fx1N with a QCPU . The program has several STL statements as State relays and dont know how to convert them for the new QCPU . I did export the old program as cvs and then imported it to a new project but I got many yellow code ( Errors  I assume ).  So far I managed to find the corresponding  Special registers needed M8002 to SM402 and for   [ ZRST M3 M200 ] used the [FMOV K0 K1M3 K200] but I am stuck at [ZRST S0 S100] asit gives me error plus it gives me yellow on each line there is a S device plus there are many STL that I dont know the equivalent of in QCPU .

Help and guidance is needed,

Thank you in advance 

Arthur

PS. Please forgive me for my bad English as is not my first language .

Attached is the full program in GXWorks2 1.91V

me commente_greasepump_91_X15.gxw


Posted

You are not going to be able to convert the stl to a Q

Or in fact many instructions.

 

Stl in the fx is a set of conditional steps where only the active step is scanned.

 

You would be better with an fx3 or fx5....Or it's a rewrite.

  • Like 1
Posted
Just now, Ron_S said:

You are not going to be able to convert the stl to a Q

Or in fact many instructions.

 

Stl in the fx is a set of conditional steps where only the active step is scanned.

 

You would be better with an fx3 or fx5....Or it's a rewrite.

Thank you Ron 

So how are "sets of conditional steps where only the active step is scanned"  expressed in Q ?

Posted

In short, they aren't.

The Q doesn't have that function.

In the fx, individual steps are defined by a line -----------------[ STL S20] etc

(program for s20 here)

STL S30 and so on

If stl s30 is active, none of the other steps are scanned

 

  • Like 1
Posted

So the only way is to rewrite it based on SFC , If I understand correctly . I find the manual for SFC programming https://dl.mitsubishielectric.com/dl/fa/document/manual/plc/sh080041/sh080041x.pdf very intimidating for a noob like myself .  Can someone help/guide me thru this process of converting the program to Q , and maybe some tutorials about mitsubishi SFC .

Thank you in advance,

Arthur

Posted

Just read your FX code and make write down the SFC chart on paper.

Than recreate it in SFC. For all the transitions use ----(TRAN) as an output. 

 

  • Like 1
Posted (edited)

What should I use as input for the (TRAN) 

the FX code is just some initial conditions and a section of manual use for the outputs then 5 STL statements and some Error routines on the end . for as I understand it .

Edited by arthurb4x
Posted (edited)

That would be the part in front it the ----[SET Sxxx]  in your FX code.

You can also recreate the STL yourself with SET RST instructions i suppose. 

 

Edited by Gambit
  • Like 1
Posted

What should I do about the [ ZRST S0 S30 ] that cant be converted . It gives me error when I try ..( The Sxx are the STL statements ).I have already started the SFC prog 

Posted

Is that a Reset of the whole SFC ?

If it programmed at the beginning you wouldn't need that. If it is part of the SFC than you can make a R block and use 999 to reset all SFC's

or just define the ones needed to be deactivated 

 

  • Like 1
Posted (edited)

yes.

so M12 and X11 should be your condition before TRAN 

You can find this example in the FX programming manual

Capture1.JPG

Edited by Gambit
  • Like 1
Posted

You can remove the S4 as you are already in S4.

You are using the SFC so all the -[Set S...]-  and  -| |- S..  at the beginning are no longer needed.

  • Like 1

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...