advertisement
from the Omron CJ1 connect Computer Web Server department...
Omron PLC with Web Server
PLCs and related questions. topic
Posted by Gordon on 27 April, 2009 - 4:28 pm
I am a newbie at this, and I don't have money to purchase expensive pre-made server. So I decide to try build my own.

Lets say I have a simple desktop computer. I want to make it into a server using Window Server 2000. And I connect my Omron CJ1 to the server with Ethernet cable. I just want to simply let many public users to just monitoring the real time data from the Omron PLC with Internet using browser.

Where can I start look and find more info about this? Which direction should I look into?

I start research about the Apache web server, but I still have no clue.

Thanks very much for help.


Posted by M Griffin on 28 April, 2009 - 2:03 am
You need to start with figuring out what it is you want to do. It sounds as if you just want to display a web page to display current data. You will have the following problems:

1) Omron uses a protocol called "FINS". You will need some sort of driver for this, and the driver will have to be in a form which you can use from a web page.

2) You need to set up a web server and write the web page(s). You are going to have to learn how to do this.

3) You said you want users to be able to monitor the web page in "real time". What does this mean? If you are just creating a conventional static web page, the users will need to press "F5" to refresh the web page so they can see an update. Is that want you want? If you want the page to update continuously automatically, you will need to do some AJAX style Javascript programming in the web page and to support this at the server as well.

4) You are going to need to do some server side programming so that when a web page requests data from the PLC, the PC can send a FINS request to the PLC and incorporate the response into the web page (or AJAX response).

In addition to the above, you said your PC uses "Microsoft Window Server 2000". You don't *have* to use a "server" version of an operating system to run a server. Microsoft sells "server" and "client" versions of MS Windows just so they can charge more money for the server version. You can install a web server on the regular version as well. So if you are paying extra for MS Windows Server, you just wasted some money.

So far as the driver is concerned, that is going to be either the hardest part, or the easiest part, depending on how much you know about writing software. I don't know of any free FINS drivers, and the commercial ones I have seen are all very expensive (you said cost is a problem). The FINS protocol is completely documented by Omron (it's in their manuals), so you can write your own driver if you wish. I would guess that a basic client driver would be several dozen lines of code, if it was written in a language such as Python.

I have a project on SourceForge that does exactly what you said you want, except it only talks Modbus/TCP and not FINS. It is at: "http://sourceforge.net/projects/mblogic/" and is called HMIServer (it is part of the MBTools package). The project web site ("http://mblogic.sourceforge.net/") explains it in more detail.

Basically, it is items 1 to 4 all in one package (except it uses Modbus/TCP instead of FINS). You create a web page (based on the provided samples) and it automatically updates itself via HMIServer. HMIServer is self contained, and you don't need an additional web server (such as Apache).

It is an open source project, so you can write a FINS driver for it, if you wish.


Posted by Gordon on 28 April, 2009 - 10:09 am
Thanks very much for your reply, tomorrow I will have a meeting with the Omron Manager in my company, and I will discuss about this issue with him. I also will record everything and post it here for our conversation.

My main concern is that I want many people (public) could monitor data only on the web page, and the web page update itself with Ajax.

I try research about the WebPort and eWON web server, but they have a limitation of how many users can view the web page at once (like 20). So I couldn't use this devices.

I am kind of interesting on your project now. Thanks very much again for your help. I might ask you more question about your project later.


Posted by M Griffin on 28 April, 2009 - 8:12 pm
Trying to describe all the possible problems and solutions is impossible, so I won't even attempt it. I will just mention a few of the most salient points.

If you really do have a very large number of users (page requests), then the bottleneck in your system is going to be the PLC. You are going to need to cache the data so that most requests are fulfilled from the cache, rather directly from the PLC. If you are going to cache the data that gets displayed, then you might as well cache the entire web page.

Web page caching is a common practice, and you can do this in Apache, or you can add a Squid proxy to do the same thing. What the cache does is it keeps a copy of the web page and puts a time stamp on it. All page requests get stopped at the cache and fed the copy in the cache. When the time stamp expires (you configure this) the request is allowed to pass through all the way through to the server and generates a new page. There are other ways of accomplishing the same end, but they would require a bit more programming.

The "page" might be just part of the complete page, so you can still do this with the proper sort of AJAX system. Since your system is read-only, you have more options available to you than you would if you had to deal with read-write access.

If your server is going to be on the public Internet, you also need to take security very seriously. That isn't something that can be resolved by a few questions and answers here.

Your other big problem is going to be web browser compatibility. Or rather, your problem is going to be Microsoft IE and all its myriad incompatibilities between different version of itself and with other browsers (all the other major browsers don't have this problem). Also, MS IE is a very archaic browser, so if you have to support it then you are limited to a subset of web features.

To make this work I think you will need to contact an experienced web developer. HMIServer and all the other web based industrial HMI systems that I am aware of are intended for highly interactive use by a small number of simultaneous users on an internal network. That involves a different set of design trade-offs than are involved in a high volume public web site.

So, the critical questions come down to how public is public, and how much traffic will the system see?


Posted by Rob on 3 February, 2010 - 10:07 am
Hello M Griffin.

I have looked at your project MBLogic, and it looks very nice. I have a new Saia PCD2 i want to test it on. Do you know if it's possible to exchange data between this unit and MBLogic?

Best Regards.


Posted by M Griffin on 3 February, 2010 - 5:13 pm
If your PCD2 does S-Bus over Ethernet (Ether S-Bus), then the answer is yes for a new version of HMIServer (the stand alone web based HMI) that isn't officially released yet. The new version is one that I have been working on with another user who also wants Ether S-Bus. He has tested it with his own SAIA hardware and it works correctly. It comes in both client (master) and server (slave) versions and is identical to the Modbus/TCP version of HMIServer except that it supports a different protocol.

It hasn't been released yet because there are some minor details about the protocol which still need to be confirmed with SAIA (the information on the protocol has a few minor contradictions). I can however e-mail a copy to you directly which you can use for testing purposes. If you are still interested, then we can perhaps put a bit more effort into getting some final answers out of SAIA. All that is required to complete this is to finalise those points and to update the documentation. I will contact the other party involved with this and let him know there is additional interest in this protocol.

I am assuming in the above that you are interested in the web based HMI in a stand alone form to use with your PLC. That is HMIServer, which comes in 4 different versions (counting the S-Bus version). The overall MBLogic project contains about a dozen different programs. If you are interested in the MBLogic soft logic system (to replace a PLC altogether), then I haven't integrated S-Bus into that because there has been no demand for it yet. It's feasible to do that, but someone would need a real application before it was worth the amount of effort involved.

If you want to contact me directly I can e-mail the new packages to you. If you don't want to post your e-mail address publicly then you will find a direct contact e-mail address in the source code files that you download from the project site as part of the package. The project also has its own support forums, but you can post questions either there or here, whichever you wish.

I will be doing a new release sometime very soon that mainly concentrates on integrating the new HMI documentation into the help system. It also contains some minor new HMI features. The S-Bus version will (when it's released) have everything the Modbus/TCP version has.


Posted by Bilal Zaki on 28 May, 2012 - 5:20 pm
Dear Sir,

I have a question about mbLogic. Can this be used for remote monitoring also? I am using danfoss controller with modbus but I need to monitor my events remotely to some other location. is it possible with mbLogic?
I await for your reply.

Thanks.
Bilal

Your use of this site is subject to the terms and conditions set forth under Legal Notices and the Privacy Policy. Please read those terms and conditions carefully. Subject to the rights expressly reserved to others under Legal Notices, the content of this site and the compilation thereof is © 1999-2014 Nerds in Control, LLC. All rights reserved.

Users of this site are benefiting from open source technologies, including PHP, MySQL and Apache. Be happy.


Fortune
There are people so addicted to exaggeration that they can't tell the
truth without lying.
Advertise here
Advertisement
our advertisers
Help keep our servers running...
Patronize our advertisers!
Visit our Post Archive