I am currently working on a small Project for David at Wine Technologies (vinwizard.us) to replace an older proprietary temperature control PLC. David decided he would like to use a Raspberry Pi due to the fact it is very powerful, low cost and has extensive documentation and support as well as a ready built network and USB stack for communications.
The problem really was would you really want to use a Raspberry Pi in such an industrial application?
The main concerns are the complexity. PLC’s and industrial controllers normally run very simple firmware for very good reasons, that being it is much more testable and therefore very reliable. The RPi to be useful needs to run an operating system such as Linux and while reliable can crash due to numerous reasons. David wanted the system to be at least as reliable as the system he was replacing which meant building a custom motherboard for it with a few additional safeguards. The whole board also had to fit into the existing metal case.
The specification for the motherboard is detailed below:
David has decided it would be good kudos for his company to release the final design and firmware back to the community so the design will be open sourced.
There are a few novel design elements to the motherboard (read it will require more testing than normal) Firstly I am fairly competent on analog design but I am very happy not to re-invent the wheel so I will be using the Microchip AN687 Design Application Note for the core of the design, however as I will need 4 channels I will be multiplexing 4 external channels using MOSFETS which have very low on resistance. We have also added a 5th channel which connects to a precision 100 ohm 0.1% resistor this will be used for calibration and self-test purposes. (What could possibly go wrong!)
As usual I will be using a PIC controller for the dirty work so it will do the control of the relays, analog multiplexer, watchdog timer and I2C slave to the RPi. I chose the PIC16F1782 this time as it has a 12 bit ADC and also has a 8 bit DAC that I will use to programatically alter the Vref into the constant current source.
As usual I have designed and hosted the Project using EasyEDA which makes it easy for you to get a PCB just by forking the project and pressing the Manufacture Button, I have never had any problems with the quality and price at EasyEDA and they deserve all the praise they get.
I don’t envisage very complicated firmware will be required for the PIC all the action apart from I2C communications will take place in a simple loop.
I am still at the stage of building up the PCB I received so more to come