lotuseater

MrPLC Member
  • Content count

    11
  • Joined

  • Last visited

Community Reputation

0 Neutral

About lotuseater

  • Rank
    Sparky
  • Birthday 03/23/83

Contact Methods

  • Website URL http://
  • ICQ 0

Profile Information

  • Country United States
  1. We are doing some testing communicating serially with a linear actuator in order to get its current position using an Allen Bradley Compact Logix processor. The information comes back as a string and I am able to extract the part of the string I need using an MID instruction. This string contains a hexadecimal value. The actuator company has demonstrated to me how find the actual position using this value within Microsoft Excel, but I would like some assistance automating this in my PLC. Here is an example of how to find the position using Excel: String Value from device: 'FFFFEC14' Excel HEX2DEC() = 4294962196 Constant Base Position: 'FFFFFFFF' Excel HEX2DEC() = 4294967295 Actual Position = 4294962196 - 4294967295 - 1 = -5100 Actual Position is -51.00 mm This matches up to the actual value when looking at the front end software for the device, but I would like to complete this procedure within my PLC. Does anyone have any tips for converting the string value (HEX) to an appropriate decimal value? Thanks.
  2. Random Number Generator

    Thank You for the Replies. I'll do some more thinking on this when I get some time and see what I can come up with.
  3. Random Number Generator

    I am curious if anyone knows a good way to create a random number between 1 and 13 using Logix 5000. I have seen the example on AB's website found here: http://rockwellautomation.custhelp.com/cgi...171&p_olh=0 I think I may be able to use that example with some additional scaling. But, does anyone have any other options? There is a specific instance I am wanting to use this for, if we need to get into additional details I will. Thanks, Jake
  4. Integer Array Search - Programming Help Needed

    Wow, thank you for the quick responses. Some more information on the system. This conveyor is at the beginning of the process and feeds two different lines. Each station loads the same type of product. As far as the stations are concerned, it does not differentiate between product 1 and product 2. The program will make an equal amount of product 1 and 2 downstream. In order to switch from product 1 to product 2, 21 empty spaces are required. It doesn't make much of a difference, but I am shifting my array 'up' through the positions, rather than down as mentioned. I have attached the logic I am using for shifting the array if you would like to see it. There is a photoeye at the beginning of the conveyor looking at the lugs. There are two arrays involved. The first position on Array_A currently always loads a "111". The loading stations look at Array_B. As you can see, Array_B only has values in it while the photo eye is blocked. This gives an exact positioning for when to load the conveyor. Array positions are as follows: Station 1 - Array_B[0] Station 2 - Array_B[3] Station 3 - Array_B[6] .. Station 13 - Array_B[36] Product Splitting Point - ~Array_B[48] BobLfoot: The program you created has the same basic idea as mine. However, it looks like you are counting empty lugs prior to the station locations. Since this line is at the beginning of the process, the lugs are always empty since station 1 right at the head of the conveyor. Please correct me if I am looking at it wrong. Others: I do have the ability to inhibit stations from loading. When a changeover is needed, one option would be to load 21 spaces with a "112" in Array_A[0]. This would keep the stations from loading on those lugs and the first "112" could be used to start the changeover at the splitting point. However, in a perfect world I would not want to do this if there were already 21 empty spaces on the conveyor. If the 21 empty spaces were not found after a period of time, then at that point I would use the inhibiting method. Initially, I was looking for a way to search the array. It looks like it may be easier to use counters as mentioned. One option would be to count empty lugs on the array at a few points. If a station downstream loaded I could reset the accumulated value appropriately. (i.e.: if a station 6 positions down loaded and .ACC > 6, reset the accumlated value to 6). Using a method similar to this I would always be counting empty spaces. Then when the changeover is needed and enough empty spaces were there, I would FLL them similar to BobLfoot's program. Does this still sound like the best option? ArrayShift.pdf
  5. In a nutshell - I have an array of SINTs that I am shifiting as a Lug Line is running for tracking. Basically, a "111" signifies an empty lug. A "1" through "13" signifies which of thirteen stations that a loaded lug came from. Stations look for a "111" to know that they can load at that postiton at that time. This array is shifted properly as the conveyor is running. Now, I need a way to tell when there is a group of 21 consecutive lugs empty for a line change downstream. I need to know where this group of array elements are in the array and load them with a filler number in those positions in order to keep them empty. I have not been able to create a very clean way of finding a group of 21 consecutive array positions with the number "111" in it. Any Ideas?
  6. 1794-AENT Module Configuration

    After I found this out about my 32-point modules a while back, I was able to exchange them for 1794-IB16XOB16Ps. This is a 32-point module, 16-in and 16-out, that you CAN rack optimize.
  7. Detect COMM loss on PanelView Plus 600 over Ethernet?

    I am creating different runtime files for different "stations" out of the same machine edition project. Each panelview will only have one file on it for the operator to select from.
  8. Detect COMM loss on PanelView Plus 600 over Ethernet?

    The concept is right; it is similar to what I had thought. But, my problem is I do not know where to create the "while running" event? Thank You Again.
  9. Detect COMM loss on PanelView Plus 600 over Ethernet?

    Thank You for your replies. I have been able to attach the 'seconds' value in the Global Connections setup to a tag in the PLC. I currently have a single Machine Edition project with several different Main Screens. A different initial graphic is chosen in the Startup options for each runtime file. Is there a way to attach the "seconds" value to several different PLC tags so that it does not have to be changed to a different tag for each runtime file? Otherwise, I would need to change it for each different Startup configuration.
  10. Comtrol has an Ethernet to Serial converter that you should look into. http://www.comtrol.com/products/specs/spec...product=99011-6 The setup would be control logix -> DeviceMaster UP -> Printer I have used these to read serial barcode scanners into PLCs with great success.
  11. I am wondering what is the best way for a PLC (1769-L32E) to detect comm loss since the communications are initiated by the PanelView Plus 600? I have read that the Panelview Plus does not support the ETHERNET PANELVIEW module in logix5000. Otherwise, that would be a good fix. For instance - If a PanelView has a start/stop control, it would not have the ability to stop if there was a communication loss. I would want the PLC to know if the PanelView had lost communication with the PLC to properly adjust the process. Thank You.