I've been anxiously waiting for someone to respond do this because is sounds interesting. But...
oghovstad said:
The aim of the project is mainly datalogging from PLC to a database, but I dont want the server to collect data from the PLC.
The main reason is this:
Imagine several sites with diferent setup, diferent variables. Then the databaseserver needs to know the setup of each plc to be able to collect all variables.
By letting the plc post its own data into a standarized database, then one site can post 5 variables, other sites migth post 25 variables.
I've been around/using PLCs for a long time but I'm a newbe to programming them. I wasn't aware that a plc could be scheduled to write to a database on its own. All of the ones we've used in the oil field are polled from an external program. Usually FIX or Wonderware. At my current workplace we use FIX32 connected to AB, Siemens, and a custom Modbus RTU for our gas pipeline. Fix had to be setup to know everything it was talking to, but not the plc confituration. It just polls for register values.
oghovstad said:
Another reason to do it this way i security. In this way the webserver vil be on the outside the plc nettwork segment, and all communication trough the local firewall can be limited to be outbound.
And in the end I think it will be more robust. If a site is down then ther vil be no change to the server, and inserting a new site wil also require minimal configuration of the server.
It's definately a good idea to keep all mission critical systems behind the firewall.
Since no one else has chimed in with their usual great ideas, it sounds like you may have to "roll your own" here. With the free databases available like PostgreSQL or MySQL on a database server and a php script to write to the web server it should be doable.
I'm curious. How is the data collected from the PLCs now ?
Since you are looking for a way to write information to a database, I'm picturing people taking readings on a clipboard and hand logging the data.
This could be the sticky part if programming libraries aren't available for your plc. This would be a good question for the manufacturer. Of course this would also require you to write your own code for the data collection.
oghovstad said:
I would realy like input on the consept.
Personally I like the idea. I like to see people take on a challenge to solve a problem and make operations more efficient.
Good luck.