You are not registered yet. Please click here to register!


 
 
plc storereviewsdownloads
This board is for PLC Related Q&A ONLY. Please DON'T use it for advertising, etc.
 
Try our online PLC Simulator- FREE.  Click here now to try it.

New Here? Please read this important info!!!


Go Back   PLCS.net - Interactive Q & A > PLCS.net - Interactive Q & A > LIVE PLC Questions And Answers

Reply
 
Thread Tools Display Modes
Old January 24th, 2023, 01:32 PM   #1
DCollis
Member
Canada

DCollis is offline
 
Join Date: Jan 2023
Location: Canada
Posts: 6
Trouble with Modbus slave/Master in BCS Tools/iX developer

Hello,

I am quite new to PLC programming. The master would be a Beijier HMI (iX T12B SC) and the slave a Beijier Nexto (XP340). I have successfully connected the two to my laptop via a westermo switch. I can ping and download programs to both. However I have been unable to actually get the iX graphics to do what I've programmed in BCS tools. For example, when I press a switch to try and turn on a bulb, instead an analog graphic will display a number (either 1 or 256). Or if I enter a number into an analog input, one of the lightbulbs will turn on. If anyone has any ideas it would be much appreciated!!
  Reply With Quote
Old January 25th, 2023, 08:27 AM   #2
parky
Member
United Kingdom

parky is offline
 
parky's Avatar
 
Join Date: Oct 2004
Location: Midlands
Posts: 4,682
I think it's pretty obvious that these are the wrong registers i.e. you have them mixed up, if you are pressing a button & get 256 or 1 then that is bit 8 or bit 0 of the analog word
Same with the other word which should be bits you are putting in a number which for example 11 would be bits 3,1,0.
Modbus you sometimes have to reverse the bytes but if you are using words it would only give wrong numbers/bits not completely swap them around.
  Reply With Quote
Old January 26th, 2023, 01:19 PM   #3
DCollis
Member
Canada

DCollis is offline
 
Join Date: Jan 2023
Location: Canada
Posts: 6
Thank you for your response, I believe I jumped in too fast and tried to do everything at once. I have reverted to simply trying to flip one switch to turn on one lightbulb as well as delving deeper into Modbus basics and how it works. As of now I am still running into issues. Everything seems right but I'm unfamiliar with these programs so it's hard to say.
Attached Images
File Type: jpg SwitchLight.jpg (85.2 KB, 47 views)
  Reply With Quote
Old January 27th, 2023, 08:05 AM   #4
parky
Member
United Kingdom

parky is offline
 
parky's Avatar
 
Join Date: Oct 2004
Location: Midlands
Posts: 4,682
Modbus has been around for a long time but there have been many tweaks, some equipment that has Modbus as a protocol have done dfferent things, byte reversal is common for example If you send "ABCD" then some other equipment will see "BADC" another one is address offset of 0 or 1, so again an example is 4000 can be seen as 4001 I do not use it if I can help it but so many itelligent equipment suppliers support it.
  Reply With Quote
Old January 27th, 2023, 04:20 PM   #5
DCollis
Member
Canada

DCollis is offline
 
Join Date: Jan 2023
Location: Canada
Posts: 6
Fair enough that makes sense, I'll look further into byte swapping for sure! When I flip my switches/enter values into the analog inputs in iX, none of the changes show in my ladder logic in BCS tools that is in run. SO I'm thinking that while there is no controller comm error, all the communication is somehow occurring in iX only and not with my PLC at all. I'll keep at it!
  Reply With Quote
Old January 27th, 2023, 09:30 PM   #6
Levi G
Member
Canada

Levi G is offline
 
Join Date: Sep 2015
Location: Alberta
Posts: 134
What driver are you using for the controller in IX Developer?
  Reply With Quote
Old January 27th, 2023, 10:36 PM   #7
DCollis
Member
Canada

DCollis is offline
 
Join Date: Jan 2023
Location: Canada
Posts: 6
Iím using the Modicon Modbus Master!
  Reply With Quote
Old January 28th, 2023, 01:15 PM   #8
Levi G
Member
Canada

Levi G is offline
 
Join Date: Sep 2015
Location: Alberta
Posts: 134
I have not used the Modicon Driver.
I have used the Nexto with an X2, I used the CodesysDriver with Codesys Arti Protocol to communicate using OPC UA.
In BCS Tools you have to add a Symbol Configuration to the Project and then do a Build in Symbol Configuration then select the tags that need to Communicate with. Under the Symbol Configuration Settings select "Select OPC UA Features". Then Download to PLC
In IX under the Codesys Arti Driver and Stations Tab you put the IP of your PLC.
Attached Images
File Type: jpg Codesys Atri 1.jpg (45.0 KB, 2 views)
File Type: jpg Codesys Arti.jpg (14.1 KB, 2 views)
File Type: jpg Codesys Symbol Config OPC UA Support.jpg (8.4 KB, 2 views)
  Reply With Quote
Old January 28th, 2023, 01:36 PM   #9
Levi G
Member
Canada

Levi G is offline
 
Join Date: Sep 2015
Location: Alberta
Posts: 134
Here is a Video that might help
https://www.youtube.com/watch?v=-b4xcoifYRY
  Reply With Quote
Old January 28th, 2023, 07:48 PM   #10
DCollis
Member
Canada

DCollis is offline
 
Join Date: Jan 2023
Location: Canada
Posts: 6
Thank you so much! I did see that video, when I was reading through the manuals for Nexto Xpress I did happen upon a couple things mentioning the Codesys Article protocol. I assumed for this specific scenario I would be required to use the Modicon function in iX. I will attempt to do that as you stated. I appreciate the input! I was wondering if In BCS tools, you had to put the HMI IP anywhere? As the controller is the slave (server) it might not be required as the HMI reaches out to it.
  Reply With Quote
Old January 28th, 2023, 08:23 PM   #11
Levi G
Member
Canada

Levi G is offline
 
Join Date: Sep 2015
Location: Alberta
Posts: 134
Quote:
I was wondering if In BCS tools, you had to put the HMI IP anywhere?
No I did not have to.
  Reply With Quote
Old January 30th, 2023, 03:31 PM   #12
paraffin power
Member
England

paraffin power is offline
 
paraffin power's Avatar
 
Join Date: Aug 2002
Location: Manchester
Posts: 515
Forget Modbus. Add an Arti driver to the hmi and give itt the IP of the Xpress .
Bcs tools can export it published symbols (build->generate code) then import that xml into your ix-dev project.
__________________
Whatever hits the fan will not be evenly distributed.
  Reply With Quote
Old January 31st, 2023, 01:50 PM   #13
DCollis
Member
Canada

DCollis is offline
 
Join Date: Jan 2023
Location: Canada
Posts: 6
Thanks, I was able to get the ARTI working pretty well. I appreciate the advice! I was tasked to attempt figuring out the Modicon way. I have made progress but am struggling a bit with Read coil status addressing. There is full communication and flipping switched in iX shows up in my BCS run. I just cant seem to get the right lights to turn on. Switch 1 - light 5, switch 2 - light 4, etc... I've attatched screenshots. iX settings are Ethernet TCP/IP, little-endian, Decimal addressing, 1-based start address, Byte swap disabled.
Attached Images
File Type: jpg Screenshot (9).jpg (107.5 KB, 3 views)
File Type: jpg Screenshot (11).jpg (103.8 KB, 2 views)
  Reply With Quote
Reply
Jump to Live PLC Question and Answer Forum


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Topics
Thread Thread Starter Forum Replies Last Post
MODBUS RTU Vs MODBUS Remote Anthony96 LIVE PLC Questions And Answers 11 June 20th, 2013 12:24 AM
S7 315-2DP / 341 Modbus Master with Multiple Slaves richyr32gtr LIVE PLC Questions And Answers 1 October 14th, 2009 01:05 AM
Trouble communicating Mitsubishi GOT with Atlas copco controller on modbus RTU nizar_lakhani LIVE PLC Questions And Answers 0 April 6th, 2009 03:48 AM
Mitsubishi Q Series Modbus TCP module QJ71MT91 set up help req'd... Pocko LIVE PLC Questions And Answers 0 July 30th, 2006 04:45 AM
MODBUS dialects. JesperMP LIVE PLC Questions And Answers 10 March 9th, 2005 03:37 AM


All times are GMT -4. The time now is 06:01 PM.


.