MrPLC Member
  • Content count

  • Joined

  • Last visited

Everything posted by b_carlton

  1. He's using hexadecimal. The '0x' prefix also indicates this.
  2. How to move an Array ? (CompactLogix)

    Create a UDT of all the items in the recipe. Then create an array of that UDT type. Then the copy can be used to move entire recipes as a unit.
  3. Use  DINTDataType.[Index_Value]  Note the '.' between the DINT and the opening bracket Remember to confirm that Index_Value is 0 - 31 to prevent a runtime error. The syntax of DINT[ index] with no period is used if the DINT tag was an array to select the particular array member. And DINT[array_index].[Index_Value] could be used to access a particular bit from one member of an array.
  4. Why no greater than (>) contact in DirectSoft?

    I worked with some microprocessors. A comparison between numbers were often performed by subtracting them and utilizing result flags. For example if we subtracted A from B and then saw that the negative result flag was set I could say that A > B, if it wasn't set then A ≤ B. A zero flag would indicate equality but the state of < would take more operations. I'm just guessing but I think it is similar to this. Many times you can achieve the other comparisons by swapping the arguments but many times a constant can't be on the left hand side. If needed load the constant into a V register.
  5. Analog Output on DirectSoft 6

    I know there are multiple methods of 'remote i/o' in the 405 line. Check if there are any limitations on types of modules in remote racks for the method you are using.
  6. Analog Output on DirectSoft 6

    The manual has multiple examples. The first sequencing example (page 14-18) will probably be the best. Once it is written then you just have to send new analog values to the V registers reserved. The one channel example just permanently selects just the one channel. Just refer to the Y addresses assigned to each of the output modules. You will have two copies of the sequencing code, one for each module, each with it's own V storage addresses, C bits and the Y addresses.
  7. Delay program run

    We had two levels of customization on a machine mainly because of the screen type attached. We detected one or the other based on, much as you have, whether or not the more expensive one reported it's first screen.
  8. Delay program run

    To absolutely prevent anything from running use a physical timer relay. Have it switch power to the DL05. A little cheaper would be to implement a timer in the program enabled at startup. Use it's done bit to condition all other logic.
  9. Analog Output on DirectSoft 6

    It would be easier if you would specify which cpu and analog module. While the manual details the channel scanning you can probably ignore it. Most of the CPUs have the ability to use the parameters set up as shown in the 'special V memory locations' section. Once these are set up the system performs the channel scanning in  the background. The first location is set up to hold the operation details of the module. The second holds the address of the first of multiple V memory locations. You send a value to a specific channel by writing to the specific location. If you need more help please provide the cpu and module information.
  10. SubRoutines in Direct Soft 6

    The subroutines are written after the main code - after the first END instruction. Each subroutine begins with a SBR box in the left rail. It is identified by a constant (eg K1) and that constant is used in the calling GTS in the main part of the program (no nicknames). The subroutine is ended with a no conditioned RT command in the output column. If you need a conditioned return (RTC) that is allowed before the RT rung but the RT rung must exist. No parameters are passed in the JSR or the RT.
  11. ASCII Question

    Getting information from a customer can be like pulling teeth. For the longest time in the QR development that's all we knew, there would be a QR code, nothing about what was in it or where it would be placed on the product. Our contact at the customer's was about 3 or 4 steps away from those who were making the decisions and it took several days to answer each of our questions. It was at about a week before the machine was finished and ready for testing before we got some answers. I was working out the decoding logic on our shop floor as they were trying to test run the machine.
  12. ASCII Question

    I'm glad to have helped. I'm retired from MARQ Packaging in Yakima. I only worked on one QR scanner application using an AutomationDirect DL260 system. The needed information was buried in the returned string at a variable offset because of tab delimited fields. I had to use multiple searches to find the 4th and 5th tabs then string extraction to get the characters between them. Not only that but the customer decided to use different data formats within that extracted string. What fun. I would have loved to get data at an easily predictable point.
  13. ASCII Question

    Modify the copy for BCN_Q as follows: COP   Barcode_Scan_BCN_1.DATA[22]   BCN_Q.DATA[0]   5   (this should copy the 5 characters) and add the following instruction MOV  5  BCN_Q.LEN  (this should set the length properly.) Note - this is pretty much the same as the first two output instructions on the rung which copy the characters then transfers the length.   If satisfied with this you may need to modify the other COPY commands as appropriate. If there are continuing problems can you provide a link to the contents of the 65 character string returned from the scanner?
  14. ASCII Question

    Having verified that the STOR works correctly on a correct string the attention should shift to the method of parsing the data. Can you give more information on that?
  15. ASCII Question

    If  you force 5 into the .LEN does it convert properly? I believe whatever is storing the string is messing up the length. Is 33.07 an expected value? Could it possibly be something like 2833.07? (Interpreting the messed up length code as data. But first 2 would be 'Q' then x1D (possibly string lead in characters?)   Verify the structure of the transmitted string. Is the parsing meant to break out a length value?
  16. SInk plc input module

    I always tried to find the actual (or at least the equivalent) schematic for the PLC modules and the device to be attached to be sure and avoid terminology problems. I did this for input and output circuits.
  17. Moving Blocks of Data in RsLogix500

    Are you saying that the contents of C5:78 are copied into C5:130 but the others (C5:79 - C7:87) are not copied into C5:131  - C5:139? Is your instruction  COP #C5:78 #C5:130 10 ? (Double click at the left hand of the rung to see the mnemonics) Is it possible that something else is overwriting C5:131 - C5:139? Are you perhaps modifying C5:78 - C5:87 just before the Copy? Please post what code you can to help.
  18. The use of copy/paste works with the data files. If you already have the changes in an offline file then open both the offline and the online in two instances of RSLogix. Right click on a data file in the online file and 'copy'. Then go to the same data file in the changed offline file, right click and 'paste'. Continue with other data files as needed.
  19. Thermocouple

    It may have an implied decimal point - 1750 = 175.0 degrees.
  20. DL205 PLC program question

    I think the 00000000 can be used to clear the password but only if you are already logged in. You may have tried this but how about '12345678' as the suggested example shows?
  21. DL205 PLC program question

    As far as I know there is no back door. All Automation Direct can do is totally clear the CPU. Hopefully you have a back up file. Order a new CPU then dump your backed up program into it. Verify that it works then send the password protected CPU to Automation Direct. If you have no backed up program then you are in a bad state. Try to find how who the 'some guys' were.
  22. Logix 5000, Array filling

    I'm not clear why you are using multiple arrays. Only one is needed for the FIFO. I suggest the following modifications: In the first rung remove the MOV command. In the FFL change 'source' to just 'Distance' In the second rung remove the ONS contact. Remove the EQU and insert an XIC of 'control.DN'. In the AVE change the 'Dest' to a single tag. In parallel with the AVE command add a FFU. Use the same control tag as in the FFL. Provide a dummy tag as the destination for the oldest array member, assuming you don't need it. Analysis - the FIFO Unload will remove the oldest reading and bump the rest. 'control.DN' will turn off and will stay that way until the next reading is added in your first rung. Thus your second rung will only fire after the first 5 readings are accumulated then will fire after each new reading comes in.
  23. String clearing

    A string is a defined type composed of a length then an array of SINTs. I believe the CLR only works on atomic types (sint, int, dint etc). Copying an empty tag is my go-to method for more complex types. You may get some effect by just setting the length to zero but when I tried that I would occasionally see problems with new characters followed by the previous characters. I feel it's best to just clear the whole thing by copying an empty string as you are doing. Edit - actually I think CLR can be used successfully with timers and counters so my blanket statement is probably false. It would be good to have a CLR with respect to strings.
  24. Micrologix 1200 clearing controller memory

    Ganpat, pleas start a new thread. Don't start a new topic on a very old thread.   But note that your image doesn't show any problem. It is just a verification of the download action you requested.
  25. Simple Click For Loop

    It seems the only indirect/pointer function is in the Single Copy command.