Adding check that port is open

Adding a check so the program autom atically opens the port if it is not
open. Warning, I haven't tested this with the cube and it can hang if
useing the wrong com port.

Author: lhunker