Jump to content

Flex727

MVP 2023
  • Posts

    3,259
  • Joined

  • Last visited

  • Days Won

    236

Everything posted by Flex727

  1. Then I would say it's a driver problem, or you didn't select the correct COM Port in VisiLogic. Your USB-to-Serial device likely uses a different driver and COM Port than the one installed by VisiLogic for the direct USB cable.
  2. There are also example projects that came with your VisiLogic installation that will help you.
  3. Why are you wanting to use REAL in this application? You can have multiple decimal places of precision using integers. For example, if you want two decimal places of precision in your project, linearize from -4500 to +4500. This will give you an implied two decimal places. You can then display it with the two decimal places on screen and use the number in calculations and other manipulations, remembering that the value is 100 times the actual value.
  4. Hmm, just tried it and see no issue. Maybe something specific to your graphics card or driver?
  5. I agree this would be nice. I always place a bit of text in a particular location for all my projects, but I have to remember to update it every time I update the project.
  6. Yes, you have 4 sockets available for Ethernet communication. Initialize the 4 sockets and configure for MODBUS IP using the IP address and port numbers for the 4 slaves. Connect to each one and use MODBUS read commands to obtain the data you want. There are example projects that came with your VisiLogic installation that will demonstrate one way to accomplish all this.
  7. All of your time and date values can be found in SI 30 - SI 38. They're clearly defined and you can use them just like any 16-bit integer register for comparison purposes.
  8. D# is just a constant value, such as 10 or 20. You can compare a memory integer to another memory integer, or just a constant value. Joe numbers by 10 because he's an old school guy who is smart enough to realize it's much easier to insert steps if you have some available numbers between the current steps. Personally, I prefer to number them sequentially by 1 instead of 10 so that makes it easier to do the List of Texts thing on the HMI. Of course, if you do that, make sure you don't leave anything out or you'll be renumbering everything and that can be a major pain. You could also number by ten then divide by ten later, but you'll be screwed up on the list of texts thing if you did end up inserting a step (e.g. 15 between 10 & 20). Edit: I see Joe was talking about List of Texts by Range. I normally do List of Texts by Pointer, as it's easier to wrap my simple mind around.
  9. First of all, are you certain the valve is controlled by an analog signal rather than a digital signal? If so, is it 0-10V, 0-20mA, or 4-20mA? Set your PLC jumpers accordingly. You can get the information you need on this from the Unitronics website (unitronicsplc.com). In the software, you will need to go to the Hardware configuration and configure your analog output per the above and assign a Memory Integer (MI) to the output. The V130 has 12-bit resolution, so that means you need to store a value between 0 & 4095 (819 & 4095 for 4-20mA) in the MI you've assigned. 0 (or 819) will be fully closed and 4095 will be fully open. In your ladder you will have a positive transition of the System Bit for F1 (SB 58) store 4095 to the MI and a positive transition for F2 (SB 59) store zero (or Reset Numeric) to the MI. Easier than pie.
  10. This is not a Unitronics issue or problem - it's a networking issue. There are many ways to do this, but there are complex security issues involved. You need a networking professional to handle it or advise you. The simple (and least secure) method is to set up port forwarding with the router that the PLC is connected to if that router has access to the internet with a static IP address assigned.
  11. I don't understand your question. The problem was that the error DIDN'T occur when it should have. Anytime you open a project that was created with an older version of VisiLogic, the software will notify you of that. That is what it's supposed to do. You can either proceed opening the file in the newer version or you can use Version Swapper to downgrade your VisiLogic to the older version and edit the project with that version.
  12. After looking at Joe's answer, I now would DEFINITELY use a lookup table.
  13. Ausman is providing good information, but I want to add just one thing - it's not just how often the input turns on, but also the length of time the input remains on for each count. If it is too short then you could miss a count even if the frequency of counts is much less than your PLC scan time.
  14. Hover your mouse over the letters "A", "B", "C", & "D" for tool tips.
  15. To expand on Ausman's comment: there are plenty of vector operations that allow indirect addressing that are available to help solve your problem. I'm pretty sure VisiLogic has all the tools you need to handle this problem solution easily once you figure out the logic.
  16. @cirocastro, check above under "Pages"/"Webinars" to see some great tutorials. Also, browse the Help file - you will learn a lot. @Cara Bereck Levy and others have put a lot of effort into the Help file and it is a great resource. There are also a lot of example programs that came with your VisiLogic installation. Review those to see how to do specific tasks. But most importantly, get a cheap PLC and start experimenting. There is no better way to learn than hands on trial and error.
  17. Yes! SET & RESET can appear as many times as needed, but keep it to a minimum in order to be able to efficiently troubleshoot later. Use direct coils whenever possible. SET & RESET are typically used for latch circuits, but there can be other occasions when they're needed.
  18. No, no, no! Ladder logic is not like other high level computer languages. In ladder logic, your code should be constructed such that every single ladder rung is executed (once!) on each PLC scan. Instead of thinking that pushing the button will execute a specific subroutine, think in terms of outputs. What do you want to have happen when the button is pressed? Write code for each of the things you want to have happen, taking care to have each Direct Coil only appear once in the program. When the input toggles, your subroutine stops being called. Without the subroutine being called, the timer never sees the input toggle. Sometimes, yes. Mostly it's to break the code up into logical chunks that are easier to read and troubleshoot.
  19. Do NOT do conditional subroutine calls. It is poor programming practice and often causes unexpected results.
  20. Here is the way I do it. I'm logging the date and time to a data table, but you can do whatever you want with the MI vectors MI 2000 & MI 2005, such as copy the vectors to another location that won't be overwritten in the next ladder rung.
×
×
  • Create New...