Hi for those who work a lot with Truth Table situations I developed a simple class and Excel sheet to help. In Excel you can finde the truth table and generate an include file ready to be incorporated in a simple Arduino sketch.Check this out : http://www.verelec.nl/?page_id=375 for more info and a link to GITHUB.Thanks in advanceNico