Transitioning from M340 to M580 Schneider Environment: Adjusting Address Values by -1

Question:

I apologize for my lack of proficiency in English, but I discovered this website through a Google search while seeking guidance on transitioning a program from the M340 to M580 environment, both from Schneider. According to my father, the M340 environment starts addresses with 1 due to its older version, while the M580 starts with 0. He is currently attempting to transfer a program from M340 to M580, but encounters an issue with the starting address values. He mentioned that to use the existing program on M580, the address values need to be offset by -1. Schneider recommended using system words %SW138 and %SW141, but I am unsure how to implement them. I tried adding %SW138 and %SW141 in the data editor, but saw no changes. Can anyone provide guidance on how to adjust the program's address values by -1?

Top Replies

The ongoing issues with Modbus offsets have long troubled the protocol, sparking negative sentiments among some users on this platform. One key challenge pertains to aligning addresses for data types like REALs that span multiple registers. While older Quantum processors allowed for placing REALs at both odd and even %MW addresses, newer ARM-based processors such as the M340 and M580 require them to be positioned at even-numbered %MW addresses. This disparity can necessitate significant adjustments when translating programs from older to newer processors. However, this issue is less likely to arise in a direct M340 to M580 conversion due to their shared reliance on newer CPUs. Potential compatibility concerns may instead surface in relation to HMIs or communication with other devices, particularly when transitioning from a Quantum to a modern CPU. The discrepancy lies in how a register identified as '400100' in legacy interfaces corresponds to processor mapping, with variations between models leading to differing %MW assignments. Most HMI software, including ours, offers the flexibility to configure read and write commands to accommodate such discrepancies and ensure seamless integration with the processor's addressing scheme. Schneider Electric has also provided system registers as a workaround for maintaining HMI functionality, allowing users to adjust settings at the HMI level while retaining default values for system registers. It is advisable to avoid using %MW0 for HMI data to prevent potential conflicts. If facing challenges during an M340 to M580 conversion, it may be necessary to review and potentially adjust variable addresses to align with the new processor. Clarifying your specific concerns with Schneider's support team could help address any uncertainties and facilitate a smoother migration process. Share more details to receive tailored assistance from the community. Welcome to the forum.

The system is functioning properly, but an issue has arisen with the display (GP-Pro). The user is trying to restore the previous display settings, but encountered a discrepancy where the address value was increased by 1 and the data value was unexpectedly shifted backward.

When it comes to Modbus integration, developers may face challenges depending on how they approach programming their protocol. Typically, the address is set at either 0 or +1. If encountering issues, consider dissecting the code and reconstructing it for improved functionality and stability. This process can help provide a more meaningful and dependable solution for Modbus compatibility.

If you do not have peer-to-peer communications with other PLCs, the focus should be on the HMI. Access the program and add some MOVE blocks to each of the %SW system words. Experiment with values like 0, +1, and -1 on the left side of the block to observe changes on the HMI. It may be necessary to power cycle after each adjustment. Personally, I have not utilized these blocks as we typically make adjustments directly on the HMI.

Sure, happy to help. The issue your father is facing is indeed a common hurdle when transitioning from M340 to M580 due to the address offset. Adding %SW138 and %SW141 directly to the data editor won't work because these system words are used by the PLC to manage the translation. Instead, I'd suggest you to create a logic in a specific section of your program where it reads the original values from M340 (starting from address 1), subtracts 1 from these values to adjust to M580 (starting address 0), and then write these adjusted values to the correct M580 addresses. You'll want to ensure the logic is executed once at the start of the application. Alternatively, this could be achieved using scripting software to automate the change in your offline files before you download to the M580 PLC. Remember, though, backup everything before making changes!

Hi there, no need to apologize for your English, your query is clear enough! Making a transition from M340 to M580 environment does indeed involve specific address modifications as your father pointed out. From my understanding, the system words you're referring to - %SW138 and %SW141 - are used to handle addressing offsets. Your issue likely lies in how these system words are being implemented. Instead of directly adding them into the data editor, what you have to do is use these words in your PLC logic to modify your address references as these words respectively contain the values of the offset in compact and extended addressing modes. Their values can be set or read by the application program. Try this and let us know if it helps resolve your issue, or if further assistance is needed.

More Replies →

Streamline Your Asset Management
See How Oxmaint Works!!

✅   Work Order Management

✅   Asset Tracking

✅   Preventive Maintenance

✅   Inspection Report

We have received your information. We will share Schedule Demo details on your Mail Id.

To add a comment, please sign in or register if you haven't already..   

Frequently Asked Questions (FAQ)

FAQ: 1. Why do M340 and M580 Schneider environments have different starting address values?

Answer: - The M340 environment starts addresses with 1 due to its older version, while the M580 starts with 0.

FAQ: 2. How can I adjust address values by -1 when transitioning a program from M340 to M580 environment?

Answer: - To adjust the program's address values by -1 when transitioning from M340 to M580, Schneider recommends using system words %SW138 and %SW141.

FAQ: 3. I tried adding %SW138 and %SW141 in the data editor but saw no changes. What should I do?

Answer: - If you are unsure how to implement %SW138 and %SW141 to adjust address values by -1, you may need guidance on the specific steps to correctly apply these system words in the program.

Ready to Simplify Maintenance?

Join hundreds of satisfied customers who have transformed their maintenance processes.
Sign up today and start optimizing your workflow.

Request Demo  â†’