Get I/O fully working

Logic now required