Jump to content

Flex727

MVP 2023
  • Posts

    3,325
  • Joined

  • Last visited

  • Days Won

    241

Posts posted by Flex727

  1. I don't have time to got through your logic in detail, but here are a few suggestions as to best programming practices:

    1) Do not rename the Main Routine. Use it for Power-Ups, configurations blocks, and subroutine calls only.

    2) Do not place multiple logic threads in a single ladder rung, as you have done in Rung 4 of Relay Control.

    3) It is usually best to keep the logic simple and use more ladder rungs. You will not run out of rungs.

    4) Rung 1 of Relay Control should probably be simplified (break it up into multiple rungs) and I think it's odd that you are using a direct contact activating an Increment function. You will be incrementing that register on every scan until the HMI button is released. Use a Positive Transition contact unless you are trying to count how many scans go by during a button press for some unfathomable reason.

    That said, most of your code looks pretty good and your HMI screens are terrific.

  2. 2 hours ago, safchow said:

    i need the solenoid to open when a button is pressed for 2 seconds

    This is ambiguous. Do you want the output to turn on for 2 seconds after the button is pressed (this is what you have), or do you want the output to turn on after the button has been held down for 2 seconds?

    Also, you appear to have the Power-Up for O0 as SET. This will turn on the output as soon as the PLC boots up. Is this what you intended?

  3. On 4/8/2019 at 4:25 PM, benS said:

    I know its a software issue because there's a border that surrounds the touchable area when the button is pressed and it only covers about 60% of the button. when the button is pressed in the center, it does not register. 

    I do see the issue of the border not surrounding the entire button (it's closer to 80%), and I'd like to see Unitronics address that, but have never had a problem with a keypress being difficult.

  4. I watched the attempted moon landing today with great anticipation. Sadly, there was a failure just seconds before the landing which prevented the mission from being a total success, however, I would like to congratulate the Israel Space Agency, Israel, and all the Israeli people for what they did accomplish. This was a private initiative that attempted to do something that only 3 other nations have accomplished in the history of man (and something that none of them are still able to accomplish). What they did successfully accomplish was to place a spacecraft into a stable orbit around the moon, which also has only been performed by three other nations. This was an inspiration to us all and I am certain the next attempt will be 100% successful.

    • Like 2
    • Upvote 1
  5. Seems like there should be an easy answer to this, but I don't see it. I'd like to flash text on a web page (i.e. flashing warning message). Using Frequency.Frequency 1 (s) to turn a visibility bit off & on doesn't work, presumably because the web page is not refreshing often enough. I know there are HTML tags to allow text to flash, but how to make UniLogic do that?

  6. 12 hours ago, hEllberg said:

    I used a HMI pushbutton that I pressed on my VirtualPLC software.

    As Joe said, this isn't Unitronics software. While it may be useful as a learning tool, I would never use it in a production environment. The PLCs themselves are relatively inexpensive - buy one to use for development if you are doing serious programming. It is the only way to ensure you are getting the results that will work in a actual production environment. I say this as an independent contractor - I have no relationship with Unitronics except for the assistance I provide on this user forum.

  7. 56 minutes ago, hEllberg said:

    I want the motors to be default in stop every time I restart the PLC.

    Then you just need to select RESET as the Power-up parameter NONE is the default selection):

    image.png.8dce03f9e6ef264a6c113503dd416a07.png

    All of the PLC memory is retained through power cycle by default (if the battery is good). This includes the state of Outputs. This isn't an issue with Direct Coils, but if you use Set & Reset Coils, then you need to pay attention to this detail.

    1 hour ago, hEllberg said:

    I don't understand why my reset bits gets turned on when I start one of the motors.

    Your Reset Coil has the logic property of Reset, but when in online mode, the red is just indicating the state of the bit, on or off. Any type of coil will indicate the state in the same way. It is different when the bit is a contact. Contacts will show power flow and thus an inverted contact will be red when the bit is off.

  8. Just a few observations:

    1) Do not place multiple logic networks in a single ladder rung.

    2) What did you use to start Motor 2 while Motor 1 was running? HMI pushbutton, or what? I agree that if MB 3 is on, then turning on MB 6 should not turn on MB 7.

    3) You misunderstand what the red lines mean. If a bit is red, then that means it is on (or True). The type of coil is irrelevant to the fact that it is on.

  9. 11 hours ago, Isakovic said:

    I just checked, there is an actual Flip-Flop function block in VisiLogic.

    I learn something new every day I'm on this forum.

    6 hours ago, hEllberg said:

    Is it possible to use the SR flip flop and connect inputs in parallel on the reset input? Or do I have to use set and reset coils?

    You can always use an intermediary:

    image.png.3c3592c7ebdc66ed0f4de08bbfba7de7.png

    MB 5 would then be used on your reset input. The PLC isn't going to care about the extra line of code.

  10. @Heitor, I moved this to a new topic since it did not belong in  the thread you replied to.

    The answer to your question is that you can't change which screen is the Start-Up screen. You can create a new HMI screen and copy the elements from your Start-up screen to it. Then you can edit the actual Start-Up Display to be what you want. It is recommended that you do NOT change the name of the Start-Up Display, as that does not change the Start-Up property. But if you do, you  can always tell which is the actual Start-Up Display by looking for the orange highlight.

×
×
  • Create New...

Important Information

This site uses cookies. By clicking I accept, you agree to their use.