Mitsubishi A3UCPU Question

Killercal

Member
Join Date
Aug 2006
Location
Ontario
Posts
150
Hey, how do I set n7:1 to 14 decimal..... Just kidding....

My real question is, I'm putting some code in a A-series PLC and the Main Progam had too many steps in it, so we had to create a SUB1 program. I have placed my code in this SUB1 program and figured out that I need to use a [CHG] Instruction. The only problem is that I have never used one before...

I read the manual IB_NA_66250-H and put the example code in.

MAIN PROGRAM

M9036
---| |---------------------(M9050)---

M9036 M9051 M9057
---|/|-----|/|-----|/|------[CHG]----

----------------------------[FEND]---

SUB1 PROGRAM

M9036
---| |---------------------(M9050)---

M9036 M9051 M9056
---|/|-----|/|-----|/|------[CHG]----

----------------------------[FEND]---

Now because M9036 is "Always on" this would prevent the code from ever being triggered. I switched the XIO (M9036) to be XIC and when I was online I saw that it was switching back and forth between the two programs, but not executing any of my code in the SUB1 Program.

can anyone help me with this? If you need me to elaborate any more, let me know.

Thanks,
Scott.
 
I have never used the CHG comand, but it is my understanding that the PLC has 1 merory block and the main and sub programs share this space.
CHG only executes on leading edge of its rung, you will have to set an M?? before your run then reset it straight after to get it to run every scan
M9036
---| |------------[set m1]-
M1
---| |------------[CHG]----
M9036
---| |------------[rst m1]-

this might work. But you should not need to do this

I have run across a full PLC memory on an A series before though, switch to the Instruction list view and check that its not filled up with NOP's, the one I had was filled with loads of them. I think they are the result of Online changes.

So you could -

Remove the NOP's if present
Change your memory settings to expand the space for the main program. You should have room for 30 ksteps this is a pretty big program.

Redownload your program, I think this also removes the NOP's, I have noticed a reduction in scan time doing this after ON-line changes.

Good luck
 
Carples,

Thanks for your input, I did actually notice a lot of NOP's in the program, but my new logic will still be too big after I delete the NOP's so I still need the subprogram.

I will try your logic and let you know if it works. BTW, the original program is not mine, I'm just adding a whole wack load of logic that really should have it's own CPU, but hey you can't force the customer to do the right thing, just warn them about the possible problems.

Thanks,
 

Similar Topics

how to communicate FactoryTalk Optix and Mitsubishi Q Series. I want to know the details of that
Replies
0
Views
28
I'm at a new job as the sole control engineer and trying to piece together where my predecessor left off. One machine I'm trying to get online...
Replies
2
Views
82
I'm looking to get some spare keys for this PLC. Does anyone know a source or have a part number? My searches are turning up nothing at the moment.
Replies
1
Views
66
I'm struggling to get an FR-E800SCE to work on CC-Link IE TSN. I'm sure the issue is with the drive, when I plug in the network cable I get no...
Replies
1
Views
103
Back
Top Bottom