BotronikS - Final code for all types of Arduino and PC users: -- HOME -- email: botronik@gmail.com
What you need to install or have installed before on your PC: see HERE

PCC-4out: Up to 4 outputs controlled by TEXT commands (from PC, PLC...)

Note: Out1-Out4= max30mA for each one
Download the HEX codes below, unpack, and upload to the proper Arduino board (Use a free net tool for example XLoader)
1. ATmega328-16MHz (MINI,NANO,UNO...): HexCode-m328
2. AtMega2560 (Mega(ATMEGA2560)......): HexCode-m2560
Based on the offered TEXT commands, you can develop your own PC, PLC ... communication code, and applications...

Available ASCII TEXT commands (Baud=9600): Test uploaded code using some free serial software such as Termite.TextCommamd format: TextCommand + ENTER
AT - attention command (return OK) - example: AT
OxH - set OUTx (x=01-04) at Hi(5V) level - example: O01H
OxL - set OUTx (x=01-04) at Lo(0V) level - example: O04L

Try and Test with BScada-SScada:
BScada: soon