Fix: bugs with wrong length being calculated
Added gettime and reboot commands