Medalarm arduino script and diagrams