flylikechris Posted October 30, 2012 Report Posted October 30, 2012 Hi guys, I am a trained and practicing Siemens programmer starting to learn the world of Mitsubishi. A little bit of background on my application. Our PC based software package gives plants the flexibility to rebalance their entire assembly lines by simply adding a tool, and configuring it in our software. What we do is then send the symbolic user defined information (Task type, station name, station comment, etc) and send it to the HMI via a text file. From there I've written vbscript to parse the text file, exract the strings, and store them in their respective address. What's nice is that Siemens HMIs allow you to do all of this internally. I can write directly to a "tag" with the data type of "string". It never has to see the PLC. Here with Mitsubishi, it looks like I am gioing to have to write a block to facilitate the writing/reading/ and switching. This is no problem, but the issue is I can't seem to get my strings to move. I can't even get my string value to exceed 32 characters. This tells me I should probably create an array, but then I get the error that my structured data type is not allowed in ladder. Do you guys have any thoughts on the best way to go about doing this string moving? My max string length would be 76 characters. Attached is a screen shot so you can see my problem. Also, for some reason the GX Simulator2 does not allow me to monitor more than two characters of the string move. I am using a Q06UDHCPU PLC. Any info is much appreciated! Thanks~ Quote
kaare_t Posted October 30, 2012 Report Posted October 30, 2012 First of all: The 32-chars length you're talking about is a limitation in the monitor function, so your string will be transferred correctly within your program, it's just that it won't show in the monitor window. Try to read the variable addresses in the Device/Buffer Memory Batch Monitor and get all the characters in the list (number of chars / 2) and you will see that everything gets moved. Your second issue: The two characters you can see when using string move is also a limitation of the monitor function, it simply monitors the first device of a sequence of devices. Since you are using Ladder mode, and not structured ladder mode, you cannot tell the monitor window that you are actually monitoring a string, hence you will see the first available device (1 word is 2 characters) in your sequence of devices. If you sometime in the future switch to structured ladder programming you can define labels/variables both globally (applies to all programs - subroutines) and/or only to one or several sub-programs (subroutines). You can define any standard datatype that you want, and the monitor will indeed see your characters. In addition, you can also extend the number of characters to show in monitor mode (however in any case, the max monitoring size is still limited to 50 chars). All in all, your program will work as expected and you can verify this by using the Device/Buffer Memory Batch monitor. This monitor is, in my opinion, a bit "strange" to use compared to my other experiences but you'll soon get used to it. Just specify your start address and look at scroll down to see each device and the contents. 1 Quote
flylikechris Posted November 2, 2012 Author Report Posted November 2, 2012 Thanks for the reply!! This is exactly the news I wanted to hear, I appreciate the help. I plan on diving deeper into the structured ladder programming over the weekend. Thanks again!! Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.