Jump to content

Isakovic

Privileged Member
  • Posts

    181
  • Joined

  • Last visited

  • Days Won

    12

Everything posted by Isakovic

  1. Never had such a request, so I did it as an exercise. As suggested in topic @kratmel posted when dealing with time intervals it's best to use RTC to UTC functions, so you manipulate only with one DW variable. That's also my experience. Sedmica.vlp
  2. Did you use MI3 and MI26 anywhere else in the program? Could it be that values are overwritten somewhere in your application?
  3. I'll tell you configuration that works well with stepper, from my experience and similar application. V430-J-TR34 with configured outputs as "High Speed Output (Step Control)", with ramping done via linearization block. Input to LIN block is distance from encoder, ouput frequency. In your case input could be acceleration/deceleration time if there is no distance measurement. EDIT: I see now that you are using V130, I personally never worked with that model, but maybe this can give you an idea.
  4. Yes, that's how I would do it. Wait for graph to reach some round number, take screenshot, then read "duration" time from "Online" box and calculate ratio.
  5. Sorry for derailing topic. I tried playing with it. When monitoring 1 unit is 1 minute and 2-3 seconds. When running autotune 1 unit is about 30ms. It doesn't seem consistent, it is the same if you change sample time. Maybe it depends on communication with controller. If you need time values to analyze your system I suggest calculating it manually by dividing your total online time with displayed units under the graph. Maybe someone who knows better can chime in, but I don't see any more settings for time axis.
  6. You did not speak favorably about sacred cult of PID, I have to react >.< Jokes aside, I used modified method from VisiLogic example program "PID motorized valve" to control 3-point and analogue actuators on systems running 24/7 and valve actuators last a long time. I did use relatively simple method before PID and it worked well, just little less stable.
  7. That is right. N3 is solved. It is used in compressor control to sort working hours. On that project I learned you'll need to use loops when doing optimization problems, I avoided them before. Whole program is a heap of loops. Code like this written in ladder gets hard to follow even for simple stuff, bunch of indirect addressing. This program was written some time ago, if I needed to do it now I would try with UniLogic and C scripts, never used UL C functions to run actual machine, only for testing.
  8. Number 3 Vague reference - this controller controls other machines
  9. If you need bit for one scan every second you should use transition contact in Gabriel's example, Felx's example will also work with normal contact. I don't know why this function was omitted from system bits in UniLogic, it is present in VisiLogic and I believe it is often used. Now I have a question here which method is best practice. In documentation for VisiLogic it is suggested to reduce the number of transition contacts, so I personally use one timer like Flex posted but with normal contact wherever it is needed in program. Is this still an issue in UniLogic or we can simply use frequency bit with transition contact?
  10. In similar project I had some time ago I used HSO in Step Control mode (not PWM), and frequencies for acceleration and deceleration are calculated in linearization block and copied to register for frequency, effectively the same thing you did. I remember having those issues that output would start with high frequency and motor couldn't speed up but can't say for sure what the solution was. When stopping are you ramping the frequency down or just set it to 0? Maybe put a delay after setting run bit if this is allowed. I'm not sure what you mean by another source.
  11. People are shocked when they find out what a terrible electrician I am.
  12. Maybe try using an auxiliary data table as a buffer for reading/writing instead of modbusing directly tables PLC uses for logic. That way you can verify if data is valid, if not repeat synchonization. This may slow down your process if mistakes are frequent.
  13. I guess it should work, I never tested it with my own PC. In the ladder before MB2 you can place condition DW0>3000000 so it won't update unrealistic time. I think you also need to account daylight savings time and your time zone (this comes down to adding Nx3600 to DW0).
  14. If I understand manual correctly this Master Clock can work as an NTP server. There is a function in VisiLogic called RFC-1305 for time synchronization with NTP server, there is also an example. It works fine, but if something goes wrong and server returns 0 it will reset PLC clock to midnight 1.1.2001. Just make sure to have some logic preventing this. Or if wiring allows it use digital input as Ausman says, that will take less programming time and be pretty accurate for this case.
  15. Oh I see it now! If the PLC and Hama are powered from the same supply both CH1 and GND on the PLC module will effectively be on the ground potential. Now I suspect AI08O also has GND and negative power terminal connected, so switching terminal places would not work. But will it work if separate power supply is used only to power Hama (not referenced to the ground), and other supply is used for current loop and PLC?
  16. I'll jump into this discussion because I am little confused here. More so after reading other quoted forum posts. Why wouldn't HI 98143-20 work? From the technical description I would wire it like this: Like any other two-wire 4-20mA transmitter. Is something not right here?
  17. You can search this on the internet for detailed explanation. It means that Integral component has maxed out over time and is contributing 100% to PID output. Maybe integral time is too slow or system cannot reach setpoint fast enough. If this makes oscillations or any other problems you can force Integral component to take some other value, there is a function block for that in PID menu.
  18. If there is a possibility of cylinders colliding might I suggest using position sensors or limit switches as conditions in your program. It shouldn't be a big investment, but it will be safer than only timers.
  19. The way that Sargani explained in post number 2 should work. Yes you can (and should in this case) read several registers in a row. If in "Modbus Master" setup you define tag as an array of 16 bit integers, let's say of length 10, PLC will read 10 consecutive registers from Modbus Slave. Can you post part of the program with code for making 32 bit float from 16 bit ints, with setup for Modbus so we can help you find the problem?
  20. Hello, I need to add two columns to an existing Data Table, in VisiLogic this can be done without losing values, I'm not sure how it works in UniLogic, I remember once editing it and all values went to 0. Can I add a member to Data Table struct and retaining values in old columns? I would back up old table, but problem is that I can't read the values in online mode and back them up, I get this error: Connection to plc was over Ethernet, ladder works normally in online mode so I wouldn't say it's a connection issue. If new columns cannot be added without losing values, my second question would be: Is it possible to read values via UniApps and save DT to USB stick?
  21. I like your style. It's more efficient, I have separate bit for every Modbus command. Will give this method a try.
  22. I'll explain the problem I had, maybe it helps somebody. I have several controllers that need to have synchronized RTC, and there was a problem that time update didn't work properly. After some troubleshooting I found that "Status" variables need to be defined in order for function blocks to work. This does not work (usually): This does work: Both cases compile the same without error or warning. UniLogic version 1.28.34 PLC USP-070-B08
×
×
  • Create New...