kaare_t

MrPLC Member
  • Content count

    2261
  • Joined

  • Last visited

Everything posted by kaare_t

  1. You have two options: Use UDP instead of TCP for both MC protocols (probably not possible since you maybe don't have control over the "other" equipment?) Setup more connections on the Ethernet port in GX Works2 so that you have dedicated connections for each application connecting into the CPU. In other words, the "other" application can open/close their connection freely and so can you on your other/different connection The problem you are describing have nothing to do with Mitsubishi on its own, it's simply the mechanics of a TCP connection.
  2. Bit to word

    Why use function block when you can use function, or even better -> instruction? If you want the "Schneider-style" function block or function I would recommend you to create a function (FUN), inside it you take 16 bits and use "SET_BIT_OF_INT" to set status to the individual bits in the FUN. THen you can have 16 bit inputs freely selectable and 1 INT output that you can connect to whatever you would like...
  3. Bit to word

    You cannot use "MOVE" on a bit. Use ladder or a suitable instruction if needed to trigger bits. Ladder example below: [STORING_Netfout]--(D401.0) You can also specify in GVL these addresses, e.g. define TestDataBit = D401.0: [STORING_Netfout]--(TestDataBit) If you want to batchmove a lot, use "INT_TO_BITARR" instruction. You'll need to create an array of the bits if you are using labels either in local header, or in GVL.
  4. GX Work2 Comments in Arrays

    For arrays this won't work. However, if you "must" have comments on each one like you describe and you would like to group them, why not create a "Structured Data Type"? Then you can work with an unassigned "collection" of bits combined. use the SDT in Global List and assign a specific variable to the first element in the SDT and it will populate the rest. I've made a simple screenshot containing several windows, I'll explain below: Lower left corner: The SDT/DUT specification (bLabel0_0 and so on - these are "inside" the array or collection) Upper center (all the way): Defined the SDT in Global Labels Right center: Specified M0 as the first device, all others populate automatically. Doable?  
  5. PT1 term

    I haven't tested PID in GX Simulator for GX Works3, but in all previous versions PID didn't work properly in the simulator. My guess is that the simulator won't function properly in GW3 either and you'll need a PLC. Why do you want to simulate the PID regulator?
  6. Communicate with GxWorks3 simulator

    I am pretty sure (not 100% though) that the simulator will not work with SLMP. I think you need the iQ-R PLC for test purposes.
  7. com error in QJ71MT91 modbus module

    @diraemon: For curiosity, what was the solution to your problem? It would be nice to know as others in the forum might read in the future, and if you post your solution they can see that and take correct action based on it.
  8. Labels and Addresses Not Shown / iQ-r R08cpu

    Is it possible to upload the program here on the forum, or "no-go"? It's an odd situation...
  9. PT1 term

    Hi, not sure what you mean by "PT1", could you tell us a bit more about this? I believe running PID loops in the GX Simulator won't work as intended...
  10. FX5U and FX5-ENET/IP

    You are sure you want to communicate with "Ethernet/IP" - the protocol? And not Ethernet or TCP/IP? There's a huge difference in the two, so a precise answer here will clarify a lot. The reason I'm asking is because I googled "Digital IN X1" and at first glance it looks to be a door-entry system. Could you specify the manufacturer and model-number you want to communicate with using the FX5? And just to be sure, it is the protocol Ethernet/IP transferring over Ethernet you want to use?
  11. QJ71E71-100 communication between PLC

    I'm pretty sure it should be able to communicate with the FX3U-ENET-ADP using MC protocol. There should be some function blocks available that supports MC protocol in the Q-series. Basically what was done was to write the protocol in code, and use "No protocol" settings on the Q Ethernet card. That way, all data is sent via the regular MC protocol, which the ADP card supports. I don't have an ENET-ADP card so it's a bit hard for me to test it, but I'll take a look for the FB's needed. I won't guarantee it, but I would believe it's perfectly doable. However, @Paolo_911: You will need to use a project with labels to utilize FBs in your code. As mentioned, I'll look for the FBs.
  12. FX Invertor communication

    You are using a total of 7 IVCK and 1 IVDR. I see that you have noe sequence control over them, I'm not sure if this will work since all of them will be triggered at the "exact same time", but since you are testing it right now it obviously works. I'm not sure how Mitsubishi has implemented the two instructions in the CPU, but since you got it working it seems OK. In Modbus you will have to make a sequence that runs through each telegram one by one, and not all at the same time. But if we look at what you've got working now, I suspect you only send the IVDR once, and the 7 IVCK are sent all the time. You've got 4 inverters in your best case and 7 IVCK per inverter. That's a total of 28 telegrams for a cycle. Now, if we divide 1 second cycle time by 4 inverters we got 250ms per inverter. Then, divide 250 by 7 and you've got 35,71ms per instruction. I would say it's within the normal range. Now, your problem here isn't directly connected to the serial bus speed. It's more the number of transmissions per inverter. Even with Gbit TCP/IP you would have a problem if you sequenced 28 transmissions due to the time it takes to initiate, communicate and break down the link. What I'm saying is that the problem here is Mitsubishi's implementation of the IVCK instruction and that you can only handle one data at a time. Since you want to read out 7 different values, you should look at ModbusRTU and read all those 7 values in one single telegram. Let's say that the seven values are located at 30001, 30010, 30011, 30012, 30017, 30020, 30030. They are spread out, but what you do is to initiate i single read multiple inputs, with starting address 30001 and a count of 30. Then you will receive all the values between 30001 and 30030 and you simply only MOV the values that are interesting. Of course, sometimes we need to use multiple telegrams because the data we want to read are spread across large areas, but the whole point here is to avoid many small telegrams. It's better to transmit one large block of data than many small. IF it's possible to read out the values you need in one ModbusRTU telegram, then I would guess that you can lower the complete cycle time from 1s to about 150ms or so (this is only a guess).
  13. SC11 to USB

    Hi and welcome! A standard USB<->RS232 converter normally works fine. In the latest years I have just purchased these from well-known online suppliers like RS or similar.
  14. IEC Developer Ethernet Peer to Peer Comms

    I haven't downloaded the code you are referring to, but in your screenshots you are moving the possible error code by using Read_Done[0] and Write_Done[0]. I would say that are two good candidates for ACK... So something like: Trigger send signal Wait for e.g. Read_Done[0] -> set a temporary bit high Wait one scan Use the temporary bit to trigger send signal, and then reset temporary bit It will be a small sequence, but this is how I would have done it. Just to ensure that nothing will ever "stop" the Ethernet transmissions, no matter the scantime...
  15. Mitsubishi iQ-R connection

    Hi and welcome! I'm sorry you are facing issues with the Mitsubishi support in your region, I guess it differs where we are located in the world... Anyhow, regarding your specific question, you will need an Ethernet/IP module for doing Ethernet/IP protocol. However, I'm a bit unsure if you're talking about the protocol Ethernet/IP, or if you are talking about Ethernet in general. Would you please specify what it is you need? Ethernet/IP is a specific protocol, and can be compared to ModbusTCP or similar protocols. Ethernet is a defined way of transferring data (or upper layer protocols if you wish). The reason I'm asking is if you need Ethernet/IP you will need the specific Ethernet/IP module for that protocol. However, if you wish to transfer data via Ethernet you may be able to use the CPU Ethernet port (for light load), or alternatively a dedicated Ethernet card.
  16. IEC Developer Ethernet Peer to Peer Comms

    It looks good @Colin Carpenter, however I just wish to add a comment: You are using a timer for triggering the instructions. Note that this isn't always the best choice. A 100ms timer is good, but if you go down on the timer interval you risk that the scantime exceeds the timer value, hence you will not alternate (and trigger) the send/receive instructions and it won't work. I'm just writing in case someone sees this post and tries this with lower timer values. What I normally do is to wait for the receive ACK signal (command executed "OK"), then wait one scan and then execute again. That is basically as fast as possible after receiving the ACK, without any special measures, and what I would normally recommend. That way, the routine for sending/receiving Ethernet data will always work even with high scantimes.
  17. Anyone used an RFID reader on company badges?

    I'm not sure what you mean by "such systems exist", but since you posted this in the Mitsubishi forum I'm just guessing you want to integrate it with a Mitsubishi controller? I've worked with barcode readers and RFID readers, both serial connected and Ethernet connected. It's very straight forward and you just connect the reader (barcode/RFID) to your controller using whatever medium (serial/Ethernet/other). Then you interpret the numbers that are input from the reader. It's just a binary or an ASCII string... What is more challenging is often what to do or how to process the input data: When you have received the string, what should be done? Do you have an internal table in the controller (e.g. input from an HMI)? Alternatively, what I have done some places, is to have a MES module and integrate with a centralized DB. It can be a DB for personnel, products, gates etc. Just make a general query in the MES/DB and use the input string (barcode/RFID) as a parameter. As said, based on your question it's a bit hard to answer more precisely... Feel free to continue the topic if you have more information to add or if anything in my post is unclear.
  18. FX Invertor communication

    Per inverter: How many instructions do you execute in sequence? For example: 3 IVCK and one IVDR per inverter? Or other? What I believe is happening is the following sequence (based on 3/1): IVCK1 (frequency) IVCK2 (current) IVCK3 (voltage) IVDR1 (setfrequency) The problem here is most likely the number of transmissions or transactions. Each of them takes processing time, and many small is worse than one large most often. I would suggest you to consider changing to ModbusRTU which I believe all your units supports by default (alternatively if you're not sure then list all your equipment with full names). By using ModbusRTU you can probably read a complete block of data (e.g. above, you can put all 3 IVCK in one transaction). Can you specify a bit more regarding what your reading (all parameters/values)? You only have one IVDR, what is it for?
  19. I see, well then you have to make some decisions... Good luck with decisions, and let us know if you have questions or concerns and we'll try to give some tips and pointers
  20. PID TUning

    Based on the information you have provided I can give a general note: Tune the P value (without I and D) Tune the I time (without D) Consider if D time is needed, if so then tune it On a general note, PID tuning in general is almost impossible to do via a forum or in messages. You need to tune it on-site, live. The whole point of a PID regulator is to be dynamic and usable in most different processes. Therefore they always need to be tuned according to the specific process. But as a tip you should start with switching off (0) I and D and tune in P so that the process is highly responsive but not over-response. It will never be spot on the setpoint since you're missing I but it will be stable above or below (depending on processvalue direction), and should be stable there. After P is tuned good, then adjust I to a time that makes the process tune spot on the setvalue during an acceptable amount of time. Sometimes D can also be used to more efficiently achieve the setpoint in processes where you have sudden "large" deviations in processvalue.
  21. FX Invertor communication

    Are you sending one telegram for send/receive data, or multiple telegrams for sending/receiving data? Normally the best option is to have one telegram per send/receive for multiple areas even if it means a total of more devices than actually needed if there are gaps in between the data you want to receive or send. To put it simple: If possible, create one telegram for send and one for receive per inverter, nothing more!
  22. IEC Developer Compiler Question

    Great! I know it wasn't a direct answer to your original question, but I hope it's enough. If you still need to remove all other information than error (and possibly warnings), let us know. Maybe there is a way, but I don't have GX IEC on the computer I'm currently on...
  23. IEC Developer Compiler Question

    Just press "F4" (if I recall) when you have errors in the list that you are searching. When the compiler dialog is open and you press F4 (if correct), it will go to the first error if I recall... Let us know if it works
  24. com error in QJ71MT91 modbus module

    @diraemon: Are you connecting the QJ71MT91 directly to your computer (no switch in between)? If so, what Ethernet port does your computer have (100Mbit port, or 1Gbit port)? The reason I'm asking is that the QJ71MT91 has a 100Mbit port, without "auto-pair-switching". This means that if your computer uses a regular 100Mbit Ethernet port (which normally does not have auto-pair-switching), you need a crossed Ethernet cable (not a regular patch cable). Or, the easiest is to connect everything via a switch, so QJ71MT91<->Switch and Computer <-> Switch. If all above is checked and OK, and it still doesn't work, can you list which IP addresses you are using for: QJ71MT91 and Computer? It is pointless to use the Modbus debugger/simulation tool without successful ping operations.
  25. I have never heard of any charts for PLC's, sadly. Processing power per second is not important, what is important is processing power per instruction. In other words, how long time does the CPU use to process a specific instruction. And of course the base scantime of the CPU (but they are kind of linked together). The major brands have their scantimes and processing times in their manuals so I think it's a fairly straight forward task. You can then compare your current PLC brand with other brands. Can you upgrade your current PLC brand to a faster CPU? You know that you can install several CPU's in some rack based PLC's, right? That would offload the main CPU... When you say your current CPU is running 50% of it's runtime, what do you mean? PLC's have a "base-runtime" (empty program) and except from that it all depends on what you put into the CPU... PLC's are cyclic and not event-based, so everything you put in WILL affect scantime/runtime. I have attached a small screenshot from a Mitsubishi iQ-R manual that shows some processing times (in uS). Look at these in any manual from the manufacturer...