Since there where a lot of questions for examples on how to use the olinuxino as PLC or HMI, I started to write a tool and used some projects from the internet as case. For now the tool will communicate between the MODBUS protocol and I2C chips (including the MODIO). In the near future there will be a tool to communicate between MODBUS and the GPIO's of the olinuxino.
All the projects are based on the MODBUS protocol. This is an industrial protocol used for distributed I/O. This means that the discribed examples can also be used to readout existing PLC's or HMI interfaces (if they of course supports the MODBUS through tcp/ip protocol).
I'll have to mention that the PLC were going to create could best not be used for life-threatening operations. You'll have to keep in mind that the current system used on the olinuxino isn't a realtime one and thus therefore the PLC will not run as you would expect from a plc (timers will have glitches and IO isn't read out in a stable time base). Also there's no certification of the used software by it is written by a few enthousiasts.
Because I'm going to describe howto compile the software on your own, you will need the desired tools to do so. I'm using the debian system for the olinuxino so if you'd like to use this software on the arch distribution you'll need other commands.
OK, let's get started ...
Interresting and used links: