Sign in to follow this  
Followers 0
POCKO

Any one interested in an area for open function block development for IEC Dev & GXWorks ?

11 posts in this topic

Hi All, I mainly work with IEC Developer and I'm now toying around with GXWorks. Programming with function blocks in IEC Developer and GXWorks makes your code look a lot neater and you can get a lot more of your I/O on screen at once. It also make your code easier to re-use across projects. Beijer are masters at function block development for the Mitsubishi programming platforms and I use many of their "intelligent function module" blocks which simplify the set up of Analog cards, CC-Link IO and VSD's, PID control to name a few in both their original incarnations and I have also modify theirs to suit myself. I'd be interested to hear people's thoughts about the posting of function blocks here for discussion, learning, review and further testing and development. This would lead to having access to a powerful library on top of the libraries that are built in both IEC Dev & GXWorks (the Standard Lib and the Manufacturer Lib). The aim should be to end up with an arsenal of function blocks that we know are stable and safe to use in a production environment. Suggest a topic (say a star-delta motor starter) and see who can come up with the most functional and cleanest function block solution using the least amount of steps. Do some research on Codesys an OSCAT which is an open source library for Codesys to see what i'm on about. AB have many function blocks available for download at theAB sample code home , and Schneiders Function block home . I come from a petro/chem background and the process control function set of IEC Dev and GXWorks leaves a lot to be desired compared to say AB's RSLogix 5000 and Schneider's Unity. Yes, PX Developer can handle things in this field better but few plants have Mitsubishi's process control processor's so let's not go down this path with this topic! So in short why not come up with our own set? I have many function blocks to handle analog scaling, data type conversion, PID control, flow totalizers, motor control, CC-Link I/O device control, actuated valve control etc that i would be willing to share. Most are just simple day to day ladder logic made in to function blocks. If would be best to stear clear of ST and SFC language and stick to ladder and native FB for this project like this. I understand a lot of people are very protective of their code as you do spend a lot of time and dollars developing reusable function blocks to give you an "edge" on your competitors and whilst we may be in one sense competing against each other for work to a degree, at the same time it's a big word and the chances that you and i are quoting the same job are very unrealistic. Once a function block has been made it's very easy to export that function block as an ASCII.asc file which could be posted as either an .asc file or as text. What do you think? Cheers - Pocko. Edited by POCKO

Share this post


Link to post
Share on other sites
Mitsubishi Electric's European website contains a section full of example function blocks for GX IEC Developer. I would expect over time they will have all the same blocks for GX Works2. But that doesn't mean they can't be placed in the Downloads section which already exists here for Mitsubishi program examples.

Share this post


Link to post
Share on other sites
I should have mentioned Mitsubishi Automation UK's site in the original post as you are correct they do have a partial collection of the Beijer function blocks (but a lot of them out of date!). To get to them you will have to sign up to their site, login in, then go to Downloads and then to Program Examples. The main place to go to though is over at Bejiers support section . The site's not in English so it's a bit awkward to navigate around, but you get the hang of it pretty quickly (they do have an English section, it's just not as comprehensive). As far as I'm concerned this site is by far the best Mitsubishi knowledge base on the web. If you are new to IEC programming this should be the first place you visit. Whilst I'm on the subject of Beijer if you have a problem their tech support there are great to deal with. As a side note if you deal with Mitsubishi PLC's linked to Citect they have some good stuff there in the SCADA section. All the best, Regards - Pocko. Edited by POCKO

Share this post


Link to post
Share on other sites
Hi! I too think that this idea sounds good! As POCKO mentioned, Beijer has more "up-to-date" function blocks, and also a larger library of function blocks than Mitsubishi and you don't have to register on their web-site. BTW: I think they've also got som FBs for GX Dev. (I've seen some in their web-sites)..... My suggestion would be to make a sub-category in the download section where we can put FBs for IEC, and mabye we should make a small note on how to publish the FBs/examples, like the format of the file (.asc/.txt/complete project), the contents, description or comments and so on....!? 1 issue though: I think it would be important not to re-publish any blocks found at Mitsubishi or Beijer - mirroring of code just leads to more problems regarding updates and maintanance. As mentioned in this post, it just leads to frustration when Mitsubishi has outdated FB's in their website while Beijer don't - which site do you check first, and do you have to check both sites? Therefore, mirroring is not a good idea (unless someone wants to spend a lot of time constantly checking for updates in other places/mirrors).

Share this post


Link to post
Share on other sites
one option is to use links

Share this post


Link to post
Share on other sites
VERY very old function block on website.

Share this post


Link to post
Share on other sites
Hi Again, Thanks to those who replied. I like the idea suggested of a sub-category in the download section. I'm not sure how much work this would be for the site admin's - maybe one of them could forward an opinion on this. I don't believe the section should be intended to mirror either Mitsubishi UK or Beijers sites, thus it would kind of eliminate the version control issues between all three sites. The repository should be a place to post whatever function block's you think others would find useful or interesting and for others to comment on them and possibly improve them. With regards to the file format, packed .pcd files of the complete compiled project set up ready for GXSimulator testing would be ideal, but even the smallest ones are still pretty sizable for this sort of project. Exported .asc files of the function block from a library are very small, but then a user would still need to do a fair bit of work to create a project POU to set the FB up for testing. So I'd suggest that the best way would to create a library .sul file with only the FB you want to exhibit inside. In it declare any global variables and DUT's if required for the function block to work and then post that. It would also be wise to include a project POU exported .asc file of the function set up ready to work. So then it would be a case of the user creating a blank project and importing the two very small files, compile it and you're ready to test. Bye for now - Pocko....

Share this post


Link to post
Share on other sites
Hi all, without trying to sound a little slow here, but how do you open the function blocks and write them? Im a self taught programmer, used to asm and C, got into Mitsi programming at work, it would be good to play around with FBs a little, Phil

Share this post


Link to post
Share on other sites
Hi! You're using GX IEC Developer right? I would start by getting a library from Mitsubishi (you can find them on the CD, or download them from the internet). When you get one of the libraries, they will contain a project and a help file, and the helpfile describes how you can import a library (containing function blocks) into an existing project. When you've got this, you will have a project containing a library and/or function blocks. You can open these by "right-click", and select open. Then you can edit the FB's inside the library as you would any other program in GX IEC. You can also create your own function blocks simply by adding a new POU and select FB instead of Program and select your desired language (Ladder, ST, IL...). The header of a FB gives you the possibility to define your variables as inputs/outputs (in addition to local variables or constants) You can also create your own library by "right-click" the "Library Pool" and select "Install/Create user library". Then you just enter a path and a name for the library, and a .sul file is created by GX IEC. You can then add function blocks to the library by cut/paste (Ctrl+C, Ctrl+V) to "move" the function blocks from your regular "POU Pool", to your new Library. Do some testing, and let us know if you're stuck in any of the suggestions above.....

Share this post


Link to post
Share on other sites
Thanks for that!!! I can't find any libaries on the IEC CD or on the Mitsi site Any help here would be great thanks very much Phil

Share this post


Link to post
Share on other sites
Hi. Log into the Mitsubishi Electric Europe site (http://www.mitsubishi-automation.com/). If you don't have a user account, just create one.... Go to the download section (you can find this on the left hand side), and select as in the picture below and click "Search / Overview". Then you'll get a list of many program-examples/function-blocks/libraries which you can download, unzip and install (and as mentioned in the previous post you can check out the help-file). Better?
1 person likes this

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0