Mitsubishi Q Series Node Red Help

Hello, trying to get some basic tags/data out of Mitsi Q series PLC. Im used to Siemens/Rockwell and have good success with Node Red and those nodes. Now trying to use node-red-contrib-mcprotocol. Theres maybe another way but I like the look of this and being able to get the data and log it without going the whole Kepware route.
Any good examples out there on how to proceed? I have access to the code and have the tags I want e.g D710. I have IP address and port (5007 seem OK?)
I'm injecting msg.connect = true into the read node.
Unsure of what the connection settings should be. Just trying defaults. Also what triggers the read node to actually read the data?
Any help appreciated.


Defaults will get you so far (MC Protocol can be difficult to get going)

Firstly, use UDP and 4E mode (if your device supports it, 3E if not)
Also, TCP should be your last choice (Mitsi TCP connections have proven to be unreliable for me and my colleagues - often needing a PLC power cycle to get going once they lock up)

Some questions - has the PLC / Ethernet card been setup to permit connections on port 5007?

What type of Ethernet card are you connecting to? On-board? Add in card?

What is the actual PLC model?

Can you share a screenshot of the PLC Ethernet configuration?

EDIT...
Disclamer: I am the author of this node-red node and i / we use it to great success in production.

1 Like

Thank you so much for prompt reply! Sounds like Im talking to the right man. Hope your day going well. Will try and answer best I can and happy to do so.

Network Card - OnBoard CPU
Model - Q04UDEHCPU
Will try and get screenshot, PLC locked at min and need to find programmer.
I found the port by scanning the PLC so Ill see what can find out.

Again, Thank you.

Screen shot of ethernet params. This screen new to me. (IP is correct and same in Node Red)


Here is a working example...

Note the UDP MC Protocol + Port Number...

NOTE: As with many things mitsubishi, you might need to power off/on the PLC for the settings change to take effect.

Lastly, regarding reading data from mc protocol...

We tend to arrange ladder to put all items of interest in one contiguous data block (e.g. D1000~D1199) then read all 200 WORDS in one go

Then I use another node called buffer-parser to convert all the WORD values into nice data.

Reading all required data in one hit has the following advantages...

  1. Much faster reading 1x200 items than reading 200x1 item
  2. Consistent data (e.g. all data is read on the same PLC scan & are consistent to one another)
  3. Converting the WORD values to nice types in one go in a nice easy editor

e.g...
image
image

EDIT...
Dont forget to read the built in help - especially the details about the format of the PLC address...

Brill reply. Thank you. Have the settings all ready to go but will have to wait a bit. Cant restart PLC. Someone would get angry :slight_smile: and a factory would stop. Will let you know how I get on. Will go back to the office and try simulate it. Have you tried on simulated PLC?

Good tip about using one word and parsing it out. Again,

Thank you and will keep you posted.

No, but I would be very interested to hear if you get that going.

Perhaps you would be equally helpful and post some screenshots & a basic how to? (I tend to just use real devices as I found the mitsi simulator (and most of their software) to be, urm, poilite, pure crap. Nothing is properly proof read, most of it is buggy and just down right awkward to use!)

Will do some screen shots for it for sure if I can get going. Trying to get the PLC to keep the port settings. Also is your polling node just a timestamp?

It can be whatever you want. It could even be a string with the PLC Address (then set the MC Read to get its address from msg.payload) - this is how you might automate the requests for data using 1 MC Read.

Ok, will have to look a bit more. Still not seeing data unfortunately.



Are your PLC and node-red on the same subnet?

Can you add a subnet mask?

Have you power cycled the PLC?

Can you "pull" the parameters out of the PLC to ensure they "stuck"?

Can you check the Ethernet Diagnostics...

Hello,
thanks again for your reply. I am away from the factory for a day or 2 but am setting up PLC beside me to try and replicate.
Yes in the factory node red and PLC on same subnet. PLC power cycled and parameters seemed to stay put.
When I get a PLC going beside me Ill have another attempt at least Ill be able to mess with and not take out the plant.
The message in node-red was that it connected then when I sent in polling message it just said timeout. Ill keep the thread posted.

Quick Update. Got Node talking to an RQ1CPU back in the office. Had to use GX3 on that one. However need to get back to the plant to see if can get the Q-series going. The only thing I can think of at the minute is the subnet mask being blank. Will have to see.

1 Like

Good news, Appear to have got it working for 1 PLC!! My issue was the Port - even though in the settings was set to DEC, when we went to diagnostics page was in HEX. Set port to converted HEX value and voila. Now the work begins.

Thank you so much for your help. No doubt will chat in the future.
Will write up what I've done and share with you if it helps the project. If theres anything else I can test for you all let me know.

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.