MrPLC Member
  • Content count

  • Joined

  • Last visited

Community Reputation

0 Neutral

About flylikechris

  • Rank

Profile Information

  • Country United States
  1. Logix Designer ReadSocket Message

    Rungs 6 and 7 (from the last image) are poorly implemented. This is embarrassing haha.
  2. Logix Designer ReadSocket Message

    Hi all, I'm having a hard time with this socket service to consistently read all of my data. It seems like there is a race condition where I miss a status of the Message instruction. If you have any insight, it would be much appreciated. Thank you. My application data is greater than 484 bytes, it can be variable up to hundreds of thousands of bytes. I've began to notice that when there is a lot of non-zero data, I start to miss chunks when I read them and put them into my buffer array. So I created a simplified testing application that always reads 484 bytes, and accumulates it. I manually send the plc 133164 bytes, which amounts to 276 times that the message instruction returns data. ((275 reads * 484 bytes) + (1 read * 64 bytes)). Sometimes my program accumulates to 133164 bytes with a count of 276 reads. Often however, it accumulates to 132680 bytes with a count of 275, 132196 bytes with a count of 274, or 131712 bytes with a count of 273. Because it is always off by a multiple of 484 bytes, and generally only once or twice in the stream, it makes me think my program has a race condition somewhere. I couldn't find information in the socket manual about how to signal that data is ready, so I followed the message timing diagram in the help file as best I could. Maybe this is my issue. I'll attach some pictures of my current implementation (they are arranged in order of program flow). I'm planning to access KB 33672, but waiting on a quote from my AB supplier. It might have some helpful information for me.   If you would rather see the project, let me know. I have not attached it because there is a lot of socket maintenance code around it. I thought this would be the best way to show my steps directly. Thank you all in advance,                
  3. Hi all, I have some machines that may fault due to one problem, but because of that fault I get maybe twenty other fault bits as a result. I think it would be nice to mask these nuisance faults and only allow the primary root fault bit to come high. If this were written in a scripted language I might use this structure: while (not "faulted")
  4. Hi guys, I've found the following website: It shows a download link for some reference material regarding Ethernet/IP communication drivers. I've been lucky with Mitsubishi and Siemens supporting TCP/IP, but for some reason this is just now starting to be supported by Rockwell, and many of the budget controllers do not yet support TCP/IP (at least without an interface module, and even then they are only compatible with certain processors). I would love to write my own Ethernet/IP driver for communicating with Rockwell controllers and I/O blocks. This looks like the perfect starting point as Rockwell claims to support it. I've got an email out to the representative listed in the article, and have talked to rockwell engineers over the phone, but do not yet have any leads. I thought I would post here in case anyone has used this, and could provide some information on where to get the reference material. I imagine there are many tinkerers on here who get excited by these things . I did notice this repository that looks close: The library is called "OpENer", and the original expired download link in the rockwell press release is "Opener.Sourceforge", so maybe there is a correlation. Maybe this github library is the latest iteration of the project files released in 2009. (The github library looks very reliable, and professionally supported). Any leads on here would be greatly appreciated. If I can prove this concept to work, I will likely go further with odva certification. But for now this will be fun to reverse engineer and prove. Also, if I get any leads on this I will make sure to post back.
  5. Index Registers in Function Blocks

    I know this is an old thread, but I wanted to say thanks to jorgensen for his input. Right now I am opening a block call, and immediately writing the index register value to a temporary location. Then before exiting the block, I write the initial value back to the index register. This lets me use the index registers freely throughout the block. Thanks!!
  6. Thank you so much for the input! This is exactly what I am doing now. It seems unfortunate to be wasting so many upper bytes of these word registers, but it should work nicely! The good thing is the data I'm after is not too significantly large. Sergei: I really appreciate your input, this is not something that I am comfortable with right at this moment. I will be taking the PLC home tonight and experimenting with the method you've described. Hopefully I can learn something new from this. Many thanks guys-
  7. I could try seperately batch moving the upper and lower 8-bit data to separate buffer areas, and then repackage it afterwords, but that seems like a bit of a hack. The cleaner way would be some sort of FB or Function, if you guys know of one. I've been looking for a while, but haven't come across anything.. Thanks again-
  8. Hi guys, do you know of a way I could accomplish a BMOV of a ZR register with an offset of 8 bits? I am not concerned with the first byte of the starting word. This is a problem I have come across quite a few times while working with Mitsubishi because everything seems to be word based. I have a barcode reader populating an array of words. The first 3 bytes are control characters, while the data I'm after is starting on the fourth byte. You can see where my problem is. The data to be compared is coming from a script in a GT16, which is a bit less flexible. This is why I prefer to accomplish the offset of 8 bits here in the PLC. I have tried ZR1000.8 , ZR1000.b8 with a BMOV but nothing will compile. I have also attempted using SFTB and SFTW, but neither will work properly. SFTB doesn't allow bits in word devices to be manipulated, while SFTW doesn't allow for a 1/2 word transfer. Any input is appreciated, thanks!
  9. Index Registers in Function Blocks

    Thanks for the reply. The more I think about it, the more I realize that this will work just as I need it. I guess I will just have to be careful about how I manage these registers among different block types.
  10. Index Registers in Function Blocks

    Hi guys, I have run into a problem where I am trying to use a device offset in a repeat call function block. My understanding is that I only have a certain amount of these Z/V registers (16 total). Do you guys know of another way I can call a device, with a variable offset? example, load a value of "1002" into Z0, and then call D0Z0, but really be looking at D1002. I am passing a function block a configurable I/O start location (constant). I then load this start I/O location into Z0, and call D0Z0 in my function block. Any help is greatly appreciated. Thanks!!
  11. Commission Q06UDEH CPU

    Hello everyone, I am looking for some documentation regarding the commissioning procedure for a new Q06UDEH CPU. I was unable to find any good documentation on the actual procedure required to safely start my system for the first time. My biggest unknown is with formatting the Mitsubishi memory card. I am using GX Works 2. Many thanks for any links or input you may have! EDIT: I have gotten this far.
  12. GT1000 Compatible RS232 "barcode" readers

    Actually in my search for more information, I've come across this gem. Looks like both a bar-code and mag strip reader is possible.
  13. Hello everyone, I am referencing chapter three of the following manual: Have any of you had experience with running some sort of barcode reader directly to the RS232 port on the GT16? Or even a function board on a GT15? A lot of the modules listed on this manual are outdated, and I'm just wondering if it would be possible to use almost any scanner with the proper configuration to send raw serial data. I am thinking about some sort of serial mag strip reader for a badge swipe if possible, not a barcode reader. I don't think this should be too tough to accomplish, just wanted to check if I would be able to log incoming data with the Barcode extended function OS. Thanks all-
  14. GT Designer 3 - str_printf

    Hi everyone, just wanting to see if something is possible within project scripting. Right now I am using: " [s16:GD0] = str_printf([w:GD3250],20,cmt(121,9)); " The goal is to write GD3250 to the comment. What's happening is I'm writing the comment to GD3250. I've tried every variation of str_printf and str_scanf that I can think of that would let me write a string to a comment. It looks like the only functionality is to write a comment to a string. I can see that being useful for instead of writing a zero to a text display, you can write a default text. (EX:"not configured") I have to believe the functionality to do the opposite lies in here somewhere... There are no syntax errors, and I do have Comment Group 121, Comment 9 created. Any quick thoughts? Thanks-
  15. GOT/GT Designer Superimpose Issue

    Hi, sorry for the long delay. It's funny you mention that. I am not using a PLC assigned device for screen control. The device assigned to window switching (maybe called window management from the project settings, I do not have my laptop with me right now.) is GD600. One of my colleagues working on a separate portion of the project has a system label for this exact purpose. I've assigned the GD600 for testing until we merge. I am doing a lot of script work.. maybe I was not careful in some of my batch moves. Could be that I am cycling something that may overwrite, or cause a hangup in the update of that value. I will try with a PLC address tomorrow and see if that clears the issue up. Thanks for jogging my brain for me! I will let you know what I find.