Jump to content

All Activity

This stream auto-updates     

  1. Today
  2. Thanks Joe I will check that. It is not actual project, I just copied initialization from main to new project.
  3. Replaced it, no problems for now. Thanks Swervo!
  4. I'm looking for code examples to use on the UIS-WCB1_1 high speed counter. I have only found the wiring documentation for the module. And to confirm is the reset edge triggered or reset on True And there a total lack of input specifications. trial and error has me using Inp 1 for counter 1 and Inp 4 for counter 2 The info may be out there but its not jumping out at me
  5. I'm surprised this does anything. You're not calling your subroutine from the Main. It is also a very good idea to keep most of your inits in the Main routine. What you're doing should work- I have initialized sockets on the fly in a similar fashion. I believe you that Modbus IP takes over and won't let go. I would break the init logic into smaller networks, as you really don't need to keep re-banging sockets three and four. I would also assign separate Function in Progress bits to all your Modbus IP config blocks - I think they may be stepping on each other. I've poked on your program a bit and attached it. Let us know if I've led you down the wrong path. Or you could dial up to a V700 and you get 8 sockets. Joe T. 2x_Modbus JT.vlp
  6. Yesterday
  7. As far as I can tell, you cannot change the configuration (as opposed to the protocol) of a socket without a configuration FB. It seems that the socket initialization (or card initialization) should reset the configuration, but it doesn't except by PLC reset. Since there is no PCOM configuration FB that I am aware of, it seems that a PLC reset is your only option. You might want to contact Unitronics support to confirm this, and if confirmed, request they add the feature on a future update to VisiLogic. I'd like to find out that I'm wrong about this as I think it's an oversight by Unitronics.
  8. When I have issues with the SD card I just replace the SD card, not saying that's your issue but a lot of SD cards now are crap out of the box or shortly after.
  9. Is it OK to switch between Modbus TCP and communication with VisiLogic on the same Socket. Code how I do it in attached project. I tested it and it worked, but then after a day I had a problem that communication with barcode readers was not working. Basically what I do when I change between Modbus TCP/VisiLogisc, I run all communication initialization - TCP/IP CARD INIT, SOCKET INIT, Modbus IP CONFIG. What I have found out that when I change from Modbus to VisiLogic, while Socket reinitializes to another port ( I use 20256 for VisiLogic and 20257 for Modbus), protocol stays Modbus (I can see this in info view). So when changing to VisiLogic i do PLC restart with SB300 and then initilalization. Any comments on that ? Have you done something similar ? 2x_Modbus.vlp
  10. Use different power supply possible only when output is "isolated". Fof example V200-18-E3XB has 2 isolated pnp/npn (source/sink) transistor outputs and 4 isolated analog outputs. However, the user must remember that these separate power supplies must be turned on and off at the same time or in the correct sequence. As an option - start powering the panel and then power the output - and turn it off in reverse order. The PLC uses output drivers that are protected against short circuits, overheating and usually undervoltage. Turning off the driver power (in your case + V0) could trigger one of these protections - and accordingly cause the PLC to restart. It's just a theory - I don't have a Jazz panel with transistor outputs to investigate your case. Therefore, a second CONCLUSION should be made - the user cannot use separate power supply for solid-state outputs of the PLC, unless the instructions indicate that they are isolated.
  11. Hi, I am having similar issue. I am using a serial port monitor software to monitor date in my serial port. I found that the current received data of COM Rx is not being moved into the assigned buffer. The assigned buffer is being filled with the data received from previous COM Rx scan. That's why it needs to press button twice to have assigned buffer updated, but with previous received data. Jay
  12. Or do some math ahead of the formula block to ensure any division results with integers are greater than 1 and big enough to provide the needed precision. Then you can sort out the decimal location afterward.
  13. PLCs don't do floating point very well if integer data types (MIs) are part of the considered equation. Your 777/10000 term and your decimals are less than 1 and getting thrown out when the formula block executes. If you want decimal points do everything in MF data types and build your formula out manually. Joe T.
  14. Do NOT call the Set Str Lib function continuously. Create a coil with your equal block and then a transitional contact off of that. It's common for someone new to Unitronics to go overboard using all the flexibility the PLC offers on subroutine calls. Unpredictable results almost always happen because unlike a computer language the Vision doesn't have local variables that are created and destroyed when the subroutine runs. You are always operating on global variables, and when you exit a conditionally called sub the value of those variables freezes. They do NOT reset to 0. You've mentioned in other posts about your subroutine strategy. Flex has already pointed out to use subroutines that are called continuously. I would highly recommend you follow his advice at this point in your programming journey. Create subroutines to organize your code but call them all the time from the Main. You can set a bit that is on when a display is active to put in front of the code you want to run. If you do it this way, the coils you use will reset to off, as you probably expect them to. Trust me, the the PLC is fast enough and the odds are very high that all your code won't even come close to slowing down. Joe T.
  15. Hi everyone, I'm trying to make formula block works, the formula is ( 685 - ( ( 777 / 10000 ) * A ) ) = MI 12, where A is MI. This keeps me giving me 675 as result. Doesn't matter the A value. I tried also to work with "0.0777" and "0,0777", and changed the MI's to ML's but I didn't get the right result. Thanks
  16. Hello There's some way to change the string library with a binary image/switch? I tried with two buttons, each for a language, and worked. But now I would like to change with a binary image/switch. Every touch in the button, will change the country flag and the language, but the screen starts to blink. I created this logic, when the button is touched, incremends MI 19, if MI 19 > 1, then will return to 0. If MI 19 == 0, the languange would change to portuguese, bur if == 1, would change to spanish. This subroutine is called when the screen "configuration" is displayed.
  17. Thanks Kratmel, this was quite enlightening!
  18. Hi, I am using the 7" unistream and i have data samplers running and writing to the SD card. I first noticed that nothing is displayed on my trend and on further investigation I found the data sampler's status (in its own struct) to be "-3" which is listed as a "save file eror". I then tried to save a screen shot and it also failed. Strange thing is, i can still browse the SD card using uniapps. When i remove the sd card and insert it again with the plc running, it works fine. But when the plc is shut down and starts up again, it has the same problem. Does anyone have an idea as to what's going on or what i am doing wrong Thanks
  19. Great topic. I have a question for eminent wizard kratmel. Is it recommended or not to use different power supplies for main power and output power? If both are referenced to ground I guess not, but what if they are floating? I remember a case when I had safety circuit cut +VO line as a bonus security on Jazz unit. This rebooted PLC when activated so I don't use it anymore. Why was this happening? It was the same supply for PLC and outputs.
  20. Last week
  21. This is normal operation. The Preset gets loaded into the Current when the timer start is initiated or if the timer is reset. If you want the timer current to show 00:04 when you go to the screen, do a timer reset at screen load.
  22. Hi, I will try to describe why it works without a connection. 1) There is output board inIside of the Unitronics OPLC controller. 2) Each of the solid state outputs is a part (one channel) of the few chip VN340SP (or something like that on foto). 3) To send signals from the processor to this chip, we must have one common wire and several separate ones for the required number of outputs. This common wire also neded for power the VN340SP. This wire is the OV contact you specified. 4) This OV contact is connected to the main power OV contact of the PLC panel through a small fuse (you can check with a measuring device that the resistance between the 0V and 0V contacts is not equal to 0 Ohm). For example i post foto of little fuse and 0V power connection for SAMBA SM70 board. That is why you output operate with 0V not connected. 5) If you neglect to connect this contact, it may happen that the fuse (or another cirquit) inside PLC blows and all your outputs stop working. Conclusion - always use the connection RECOMMENDED by the manufacturer. This will save your controller from problems and save you money.
  23. Hi Denis, Actually, I don't want the firt timer to continue to run after when I leave the display. What happens with the timer 2, is that, when it ends, and in the display is showing "00:00", right? So when I leave the screen and go back after, still is showing "00:00". But when it starts, it changes to 00:04, 00:03, 00:02.... But if you, or somebody could help me to solve just the problem with the first timer, will be enough. Thanks for your time, already.
  24. Hello, I'm struggling to understand why do I need to connect +VO and 0V to the outputs, how shows the image: I tested here and only with de +VO (24V) worked well.
  1. Load more activity
  • Create New...