innoaloe

MrPLC Member
  • Content count

    425
  • Joined

  • Last visited

Everything posted by innoaloe

  1. Struct as FB input

    For a user-defined Functions / Function Blocks, you cannot use the elementary STRUCT as the datatype. This functionality is only for Omron's premade libraries. You need to specify a certain Structure name for your FB Inputs/Outputs. Should you export this function block later on for different project, this Struct Datatype information will be carried along in the namespace of the FB.
  2. Error on connecting to plc

    We're you able to connect to the PLC before? Omron RS232 serial connectors have a different pinout layout compared to the usual PC Standard RS232. You need to make sure you wired it up properly. There's already lot's of wiring reference in this site that you can search about it. Also, why are you trying to look into it with CX-Protocol? Is the Serial Comm. Board connected to a certain device with custom protocol? You need to turn DIP Switch Number 8 on the CPU Unit prior to powering it up if you want to connect to the Serial Comm Board via CX-Protocol. For the CPU built-in RS232 Port, try turning DIP Switch Number 5 prior to powering up, so that the RS232 Port will be using it's default communication settings. This will make Auto-Online connection using CX-Programmer easier.
  3. Mask Move in Sysmac Studio

    This was a fun topic that I tried to test it also. A little bit off topic but from the test I just found out that "ANY" datatype is not available as a Custom Function In/Out data type. Kinda weird since some prebuild functions like "AryByteTo" have In/Out variables with ANY datatype, but we cannot access it for custom functions. By the way I checked the NJ firmware, and the ANY datatype definitely exposed there. :D
  4. It wouldn't damage anything per se,  but you will lack the full feature of 1.16 firmware, which I don't exactly remember anyway... It's kinda hard to find firmware update notes these days for some reason (in my search, internet will give you up to 1.14 update notes)
  5. I don't really understand what did you mean by CPU Type Operands, however for CPU Status, it will basically consume a small bytes of the symbol (2 bytes at most IIRC). In case NJ will receive other PLCs status, one way to do it is to create a symbol with data type of BYTE Array, then separate the 2 first index as CPU Status. Another way is to create a STRUCT which contains two members, CPU Status and the Data itself. Of course you need to match the size of each member. In case CJ will receive PLC status from NJ, there is no need to map the status as a symbol in NJ since it will be padded automatically. You just need to separate each byte part in CJ later on to differentiate CPU Status and Data.
  6. Need help with programming instruction

    It will be better if you post some ladder that you've made for it here. Anyway ladder diagrams are just logic gates basically... Simplest logic would be as follows : Say for a set of Lot 1,2,3 (1 AND 2 AND 3), OUT RED (NOT 1 AND NOT 2 AND NOT 3), OUT GREEN (1 AND NOT 2 AND NOT 3), OR (NOT 1 AND 2 AND NOT 3), OR (NOT 1 AND NOT 2 AND 3), OUT ORANGE Now, just translate those AND, OR, NOT, OUT into the Ladder Symbols
  7. Help plz cqm1h cpu 51

     I found this in CQM1H Programming Manual. Make sure to check your DIP Switch settings and DIP Switch no.4 is set to ON before turning On the Power Supply of the PLC. Try to connect to the PLC again, but this time after auto-online or whatever method you choose, click on menu PLC--> Transfer-->From PLC In the menu that will pop up, just check on every PLC related stuff there (if memory serves me right Expansion Instructions checklist should be there as well), then click Transfer/Upload. Whether deleting it gonna make issues or not depends on your program needs, but since the instruction number 88 is there in the first place it should have some use. Your machine may not work correctly if you just delete it and re-download the program
  8. Help plz cqm1h cpu 51

    I think Jay meant to ask you to Upload the program again from the PLC, but this time make sure you check the Expansion Instruction checkbox before pressing Transfer. This is to ensure that whatever instruction is allocation to Expansion Slot 88 is also uploaded to the program. Your screen capture of the Expansion Instruction slots is the default values. The way CQM1H works is that whatever expansion instruction sets to occupy a slot will have a same instruction number, that's why your ladder now contains 7SEG instruction since it is translated to the default sets. Try uploading again.
  9. When you are programming with Sysmac Studio you will need to give Symbol Names to any variable you created anyway. There is no helping that. If you want Absolute Addressing, your best bet is to specify the Absolute Address in the AT variable of each Symbols after you created them. Then, to map the variables by their Absolute Address, use the Network Configurator software (should be included with Sysmac Studio). With this software you can create Tag Names using the Absolute Address, even for NX/NJ PLCs, although in order to do this you must create each Tag manually. The Sysmac Studio actually allows you to Export the tag names created in the program file, however it will use the Symbol Name, eventhough you already add the Absolute Address.
  10. By Tag, I'm assuming you're about to communicate via Ethernet/IP then? If you are using Tag, you don't need Absolute Address. Just use the Symbolic One and the Symbol Name will be the Tag Name. The variables should be Global Variables. In the variable table you also need to set the Publish Status of each variable that you want to read/write through Tag
  11. The symbolic addressing is a must, but then you can specify the absolute addresses for every variables you've generated. In the variables table (Internal or Global doesn't matter) you can look at the "AT" column. It will typically filled automatically if you are mapping a variable to an I/O point. If your variable is just a  memory resides in the CPU, you can give absolute address same with the naming conventions in CX-One PLCs, like %0.00, %D0, %W0, etc.
  12. CIP betwen CJ2M and NS8 HMI

    @jeskudero as some mentioned on the posts above, go look into W342 manual. You will find it on FINS command section NVM... saw you have edited your post above
  13. CP1L-M40DR-A PLC does not boot from my logic

    Didn't get what you've meant by "Logic" here. The CIO and WR area will always be reset on power ON. Your best bet to keep the last state of your program is to use either DM or HR memory area, but even with those you need to have a battery installed to the PLC, so it can retain the last data set in the DM / HR.  
  14. subtracting the real value

    This is just my assumption, but if you are reading data of the weighing module to, let's say memory D0, you must save the calibration/subtraction result on other memory, for example D10, then use that as your calibrated reading result. If you use the same memory (D0) to save the calibration result, it will get overwritten time by time by the actual reading of the weighing module
  15. CIP betwen CJ2M and NS8 HMI

    Awesome! Then back to your Wireshark capture, you can try to look at the CIP Requests which sends out 372 bytes. On the very last part there is CIP Class Generic/Command Specific Data. Those are the FINS Commands, although I must say it's kinda differ from it's usual format that is commonly used based on the W342 manual. It doesn't implement MRC/SRC part anywhere... just memory address that it wants to capture See the Txt file here on some notes that I put. You can compare it later with manual W342 FINSData.txt  
  16. CIP betwen CJ2M and NS8 HMI

    It's the other way around actually. The FINS Protocol is encapsulated by the Ethernet/IP Protocol. Actually NS also can be configured to talk with the PLC via FINS only without the Ethernet/IP function.   I took another reading at the CIP_OMRON file you attached in the first post, and I think what you are seeing is not packet data between NS and the CJ2M PLC. Instead, it is a packet between your PC with CX-Programmer with your PLC via Ethernet/IP. If you are using a Network Switch, Wireshark will not be able to read the transmissions between NS and CJ since a switch won't broadcast the data packets to all connected device, only to the targeted one. You may have a better luck if you are using Network Hub instead which just throws away packets everywhere, or if you have a Managed Switch it's usually possible to forward packets to another port or even broadcast it. Since you are learning it (and I'm in a good mood during Chineese new year :D), I just put another note to let you know what's happening actually if you are connecting NS to CJ PLC via Ethernet/IP. You might able to observe this activity if you have a Hub or Managed Switch as I mentioned above. Basically all of this happens using Explicit Messaging. NS doesn't use Implicit Messaging as you've mentioned above. You can compare the jargons here with EtherNet/IP Manual Book. When the connection is started (Ethernet cable connected for the first time, or power on for the first time) NS throw "List Services" Request using UCMM Should the PLC supports Ethernet/IP Explicit Message, it will reply with "Communications" Response. NS then will send RegisterSession Request using UCMM PLC will reply with a lot of things, but SessionHandle is the most important one since it must be used by NS in the all following communications NS will then send a "Large Forward Open" Request using Class3. This is where NS and PLC establishes a memory mapping between them PLC will return quite a lot of things such but the most important is Originator-->Target NetworkID which is basically a memory map identifier to be used by the NS in the next operations From this point on, NS an CJ can communicate cyclically by the interval sets on the RPI parameter (this is to be set during Large Forward Open request. Basically a data refresh rate) Cyclically NS will throw "SendUnitData" Request to the PLC to either Read or Write data on PLC Memory. This is where the FINS Command is encapsulated. You will also not able to decode it via Wireshark since the Service Code and ClassID used are Vendor-specific value to Omron. But if you managed to sniff the packet, you can see the FINS Command at the very end of the line. Also, if you managed to get SysmacGateway software, you can use it as a PLC Memory Emulator in your PC, which also support Ethernet/IP. This way, you can connect NS HMI to your PC instead of actual PLC and sniff the data via Wireshark easily.  
  17. CIP betwen CJ2M and NS8 HMI

    I am assuming your PLC is CJ2M-CPU3[] something? Try to click on Browse (Examinar in your case) before connecting. At times you'll be asked to select the Network Adapter first. Maybe it is set default to your Wireless. The CP1L Node Online basically connects to CX-Programmer via FINS protocol. Not Ethernet/IP
  18. CIP betwen CJ2M and NS8 HMI

    All Omron PLC that supports EIP also supports FINS protocol (Omron dedicated protocol, which @gtsuport mentioned about the manual above). Looking at your Wireshark capture, it is definitely FINS. No CIP protocol being used at all. If you want to see how CX-Programmer communicates through CIP, don't use the Auto Online button when connecting to the PLC. Instead, use the Ethernet/IP Node Online button. It is to the second button to the right of the Auto Online button. Alternatively you can right-click on the PLC Name, click Change, then set the Network type to Ethernet/IP. If anything, instead of using CIP, I will encourage you to use FINS instead since it is easier to be implemented. There are also lots of available examples of FINS Implementation using DotNet or other language in the Downloads section on this forum, mine for instance : http://forums.mrplc.com/index.php?/files/file/1034-omron-simple-hmi_finsudp/
  19. Sysmac download

    The Sysmac Studio itself will only supports NA HMI, although the installation file of Sysmac Studio will give you a CX-Designer also to program NS HMI. NB is to be programmed using other application which is NB-Designer.
  20. Wow, that's good to know! Thank you for coming back and telling us about it. Still it felt weird that Omron does not even mention this in their manuals . That, or maybe I am looking at the wrong place
  21. CIP betwen CJ2M and NS8 HMI

    Your best bet is with Manual number W465-E1 which is manual for Omron CS/CJ Ethernet/IP Master Units. It should be available in most Omron websites as long as you have a user account (which is free, try the industrial.omron.eu since you're in Spain). From this manual go to Section 9 then 9-2-1 where you can find list of PLC Object Services. This basically lists all CIP Service Code that you can use to read/write memory of a certain type. The manual itself covers about how you would interpret the message using PLC Program, but you can use it as a base to generate your own CIP Package. My suggestion is to use Molex CIP Tool first using the UCCM type communication to test these Service Codes
  22. cp1h-y20dt-d Pulse/Dir Pulse Wiring to Servo Contoller

    Keep in mind also that CP1H-Y is rated for 5VDC pulse output, so make sure not to wire it to your Servo Photocoupler 24VDC Input
  23. CQM1

    In Omron's case, you can copy a Mnemonic version of Mitsubishi's program and paste it into CX-Programmer to automatically converts Mitsubishi's ladder diagram to Omron's. Of course some adjustments need to be made later on. However I don't know whether Mitsubishi has this feature or not in GX-Developer
  24. If we refer to the Manual, then no other way to view PDF documents in NA5 except by pre-load it first to the Resource (basically making a copy of the PDF file inside NA memory). Up until the latest version of Sysmac Studio (1.20 afaik) there is only one command to load PDF file, which is ShowDocument that can only refer to the Resource ID instead of a directory (like USB / SDCard). Oddly enough, if you check on OpenMovieFile command, you can load an "External" Movie files from external storage like an SDCard, but they won't give you this feature for documents Soo.... I will suggest you to try using the ShowDocument command, but change the ResourceID argument with an absolute path, like "\SDCard\MyDoc.pdf" or USBMemory or even FTP if that's fits you better. Haven't tried this yet personally
  25. CQM1

    In regards to Mr. Anthony, yes PLC still does give outputs in Monitor mode. There is no real difference between Run and Monitor mode aside from the fact that you can read and write the memory of the PLC through CX-Programmer only in Monitor Mode while the program is running.